Skip to content

Commit 48a6f47

Browse files
committed
Some of impl for #825
1 parent 91ab3f4 commit 48a6f47

File tree

2 files changed

+34
-30
lines changed

2 files changed

+34
-30
lines changed

src/Core/Command/GlobalCommandBuilderFromCommandLine.cc

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -73,21 +73,25 @@ using namespace SCIRun::Core::Commands;
7373

7474
if (!params->inputFiles().empty())
7575
{
76-
for (int i = 0; i < params->inputFiles().size(); ++i)
76+
const int last = 1;
77+
//TODO: support multiple files loaded--need to be able to execute and wait for each before loading next. See #825
78+
// last = params->inputFiles().size()
79+
for (int i = 0; i < last; ++i)
7780
{
7881
q->enqueue(cmdFactory_->create(LoadNetworkFile, i));
82+
83+
if (params->executeNetwork())
84+
q->enqueue(cmdFactory_->create(ExecuteCurrentNetwork));
85+
else if (params->executeNetworkAndQuit())
86+
{
87+
if (i == last - 1)
88+
q->enqueue(cmdFactory_->create(SetupQuitAfterExecute));
89+
q->enqueue(cmdFactory_->create(ExecuteCurrentNetwork));
90+
}
7991
}
8092
}
8193
else if (params->pythonScriptFile())
8294
q->enqueue(cmdFactory_->create(RunPythonScript));
8395

84-
if (params->executeNetwork())
85-
q->enqueue(cmdFactory_->create(ExecuteCurrentNetwork));
86-
else if (params->executeNetworkAndQuit())
87-
{
88-
q->enqueue(cmdFactory_->create(SetupQuitAfterExecute));
89-
q->enqueue(cmdFactory_->create(ExecuteCurrentNetwork));
90-
}
91-
9296
return q;
9397
}

src/ExampleNets/regression/showColorMap.srn5

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
22
<!DOCTYPE boost_serialization>
3-
<boost_serialization signature="serialization::archive" version="10">
3+
<boost_serialization signature="serialization::archive" version="11">
44
<networkFile class_id="0" tracking_level="0" version="2">
55
<networkInfo class_id="1" tracking_level="0" version="0">
66
<modules class_id="2" tracking_level="0" version="0">
@@ -50,7 +50,7 @@
5050
<name>PadPercent</name>
5151
<value>
5252
<which>1</which>
53-
<value>0</value>
53+
<value>0.00000000000000000e+000</value>
5454
</value>
5555
</second>
5656
</item>
@@ -114,7 +114,7 @@
114114
<name>ColorMapName</name>
115115
<value>
116116
<which>2</which>
117-
<value>Gray</value>
117+
<value>Rainbow</value>
118118
</value>
119119
</second>
120120
</item>
@@ -266,7 +266,7 @@
266266
<name>CylinderRadius</name>
267267
<value>
268268
<which>1</which>
269-
<value>0.050000000000000003</value>
269+
<value>5.00000000000000030e-002</value>
270270
</value>
271271
</second>
272272
</item>
@@ -278,7 +278,7 @@
278278
<name>CylinderResolution</name>
279279
<value>
280280
<which>0</which>
281-
<value>8</value>
281+
<value>5</value>
282282
</value>
283283
</second>
284284
</item>
@@ -314,7 +314,7 @@
314314
<name>EdgeTransparencyValue</name>
315315
<value>
316316
<which>1</which>
317-
<value>0.64999997615814209</value>
317+
<value>6.49999976158142090e-001</value>
318318
</value>
319319
</second>
320320
</item>
@@ -350,7 +350,7 @@
350350
<name>FaceTransparencyValue</name>
351351
<value>
352352
<which>1</which>
353-
<value>0.64999997615814209</value>
353+
<value>6.49999976158142090e-001</value>
354354
</value>
355355
</second>
356356
</item>
@@ -422,7 +422,7 @@
422422
<name>SphereScaleValue</name>
423423
<value>
424424
<which>1</which>
425-
<value>1</value>
425+
<value>1.00000000000000000e+000</value>
426426
</value>
427427
</second>
428428
</item>
@@ -506,36 +506,36 @@
506506
<item class_id="16" tracking_level="0" version="0">
507507
<first>CreateLatVol:0</first>
508508
<second class_id="17" tracking_level="0" version="0">
509-
<first>-1672</first>
510-
<second>-1292</second>
509+
<first>-1.67200000000000000e+003</first>
510+
<second>-1.29200000000000000e+003</second>
511511
</second>
512512
</item>
513513
<item>
514514
<first>CreateStandardColorMap:0</first>
515515
<second>
516-
<first>-1520</first>
517-
<second>-608</second>
516+
<first>-1.52000000000000000e+003</first>
517+
<second>-6.08000000000000000e+002</second>
518518
</second>
519519
</item>
520520
<item>
521521
<first>ShowColorMap:0</first>
522522
<second>
523-
<first>-1520</first>
524-
<second>-912</second>
523+
<first>-1.52000000000000000e+003</first>
524+
<second>-9.12000000000000000e+002</second>
525525
</second>
526526
</item>
527527
<item>
528528
<first>ShowField:1</first>
529529
<second>
530-
<first>-1672</first>
531-
<second>-1140</second>
530+
<first>-1.67200000000000000e+003</first>
531+
<second>-1.14000000000000000e+003</second>
532532
</second>
533533
</item>
534534
<item>
535535
<first>ViewScene:1</first>
536536
<second>
537-
<first>-1824</first>
538-
<second>-988</second>
537+
<first>-1.82400000000000000e+003</first>
538+
<second>-9.88000000000000000e+002</second>
539539
</second>
540540
</item>
541541
</modulePositions>
@@ -548,11 +548,11 @@
548548
<noteHTML>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
549549
&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
550550
p, li { white-space: pre-wrap; }
551-
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;Lucida Grande&apos;; font-size:13pt; font-weight:400; font-style:normal;&quot;&gt;
552-
&lt;p style=&quot; margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; color:#ffffff;&quot;&gt;ID: 1&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</noteHTML>
551+
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;MS Shell Dlg 2&apos;; font-size:8.25pt; font-weight:400; font-style:normal;&quot;&gt;
552+
&lt;p style=&quot; margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:&apos;Lucida Grande&apos;; font-size:13pt; color:#ffffff;&quot;&gt;ID: 1&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</noteHTML>
553553
<noteText>ID: 1</noteText>
554554
<position>0</position>
555-
<fontSize>13</fontSize>
555+
<fontSize>8</fontSize>
556556
</second>
557557
</item>
558558
</moduleNotes>

0 commit comments

Comments
 (0)