]> gerrit.simantics Code Review - simantics/sysdyn.git/commitdiff
Added sample Sysdyn models (refs #4702).
authormiettinen <miettinen@ac1ea38d-2e2b-0410-8846-a27921b304fc>
Tue, 25 Feb 2014 11:18:33 +0000 (11:18 +0000)
committermiettinen <miettinen@ac1ea38d-2e2b-0410-8846-a27921b304fc>
Tue, 25 Feb 2014 11:18:33 +0000 (11:18 +0000)
Fix for launching Sysdyn experiments (refs #4728).

git-svn-id: https://www.simantics.org/svn/simantics/sysdyn/trunk@28937 ac1ea38d-2e2b-0410-8846-a27921b304fc

org.simantics.sysdyn.feature/rootfiles/sampleModels/Discovery And Exploitation Of Resources.tg
org.simantics.sysdyn.feature/rootfiles/sampleModels/Global Carbon Cycle.tg
org.simantics.sysdyn.feature/rootfiles/sampleModels/Predator And Limited Prey.tg
org.simantics.sysdyn.feature/rootfiles/sampleModels/Resource Exploitation Use Recycling.tg
org.simantics.sysdyn.feature/rootfiles/sampleModels/Tourists Environments And Hotel Facilities.tg
org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/handlers/SysdynExperimentActivator.java

index c00a8865942500ce55dd45084de132c55bff3ce1..bcbd16c29db79db92bb4931bf8f5f9f985515782 100644 (file)
Binary files a/org.simantics.sysdyn.feature/rootfiles/sampleModels/Discovery And Exploitation Of Resources.tg and b/org.simantics.sysdyn.feature/rootfiles/sampleModels/Discovery And Exploitation Of Resources.tg differ
index cedf440a287e273a6f82b50a4b390907f0e05d39..60edfdfa6b34efe0ec79d99065f8efd73cafbbf8 100644 (file)
Binary files a/org.simantics.sysdyn.feature/rootfiles/sampleModels/Global Carbon Cycle.tg and b/org.simantics.sysdyn.feature/rootfiles/sampleModels/Global Carbon Cycle.tg differ
index 3a1c507abc141bb4223cc11b72cd6c971c13d362..2a8f549df8ed295af817bc820272292ccb38be5b 100644 (file)
Binary files a/org.simantics.sysdyn.feature/rootfiles/sampleModels/Predator And Limited Prey.tg and b/org.simantics.sysdyn.feature/rootfiles/sampleModels/Predator And Limited Prey.tg differ
index 4c49bbb3eea444e8fedfdc152ccd32d42a6a91a1..132c2fc7044d528b9d8b0b854381255be23b0544 100644 (file)
Binary files a/org.simantics.sysdyn.feature/rootfiles/sampleModels/Resource Exploitation Use Recycling.tg and b/org.simantics.sysdyn.feature/rootfiles/sampleModels/Resource Exploitation Use Recycling.tg differ
index 1dc2331672d81b7f704cc38c703c6090ff6688b1..496ef1cbb5bee631991f939ee2a619f899b84eae 100644 (file)
Binary files a/org.simantics.sysdyn.feature/rootfiles/sampleModels/Tourists Environments And Hotel Facilities.tg and b/org.simantics.sysdyn.feature/rootfiles/sampleModels/Tourists Environments And Hotel Facilities.tg differ
index 04f1a694025284d3464a3b84f8a9145f8639f4c2..7d6906019c6bf96ea8b3fcd2cef10fcdc07898ca 100644 (file)
@@ -1,5 +1,5 @@
 /*******************************************************************************\r
- * Copyright (c) 2010 Association for Decentralized Information Management in\r
+ * Copyright (c) 2010, 2014 Association for Decentralized Information Management in\r
  * Industry THTH ry.\r
  * All rights reserved. This program and the accompanying materials\r
  * are made available under the terms of the Eclipse Public License v1.0\r
@@ -105,7 +105,11 @@ public class SysdynExperimentActivator {
         SysdynExperimentManagerListener.listenManager(manager);\r
         IExperiment[] experiments = manager.getExperiments();\r
         SubMonitor shutdownMon = mon.newChild(10000);\r
-        int workPerExperiment = 10000 / experiments.length;\r
+        int workPerExperiment;\r
+        if (experiments.length > 0)\r
+               workPerExperiment = 10000 / experiments.length;\r
+        else\r
+               workPerExperiment = 10000;\r
         for(IExperiment e : experiments)\r
             if(e.getState() != ExperimentState.DISPOSED)\r
                 e.shutdown(shutdownMon.newChild(workPerExperiment));\r