Skip to content
Snippets Groups Projects
Commit 57172a0d authored by Maxime Graulich's avatar Maxime Graulich
Browse files

iOS: edit xml files & fix checkbox

parent 9a303b6e
No related branches found
No related tags found
No related merge requests found
...@@ -213,7 +213,7 @@ ...@@ -213,7 +213,7 @@
[label setText:[NSString stringWithCString:number.getShortName().c_str() encoding:[NSString defaultCStringEncoding]]]; [label setText:[NSString stringWithCString:number.getShortName().c_str() encoding:[NSString defaultCStringEncoding]]];
name = [NSString stringWithCString:number.getName().c_str() encoding:[NSString defaultCStringEncoding]]; name = [NSString stringWithCString:number.getName().c_str() encoding:[NSString defaultCStringEncoding]];
checkbox = [[UISwitch alloc] init]; checkbox = [[UISwitch alloc] init];
[checkbox setSelected:(number.getValue() == 1)]; [checkbox setOn:(number.getValue() == 1)];
[checkbox addTarget:self action:@selector(valueChange:) forControlEvents:UIControlEventValueChanged]; [checkbox addTarget:self action:@selector(valueChange:) forControlEvents:UIControlEventValueChanged];
} }
return self; return self;
......
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="utf-8"?>
<info>
<name>Magnet</name> <models>
<description>Simple magnet example</description> <model>
<info> <title>Magnet</title>
\ No newline at end of file <summary>Simple magnet example.</summary>
<file type="pro">magnet.pro</file>
</model>
</models>
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="utf-8"?>
<info>
<name>Eight-pole permanent magnet synchronous machine</name> <models>
<info> <model>
\ No newline at end of file <title>Eight-pole permanent magnet synchronous machine</title>
<summary></summary>
<file type="geo">pmsm.geo</file>
<preview type="png">screenshot1_512.png</preview>
<url>http://onelab.info/wiki/Electric_Machines</url>
</model>
</models>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment