Revision: 18298
          http://sourceforge.net/p/jmol/code/18298
Author:   hansonr
Date:     2013-06-06 13:47:32 +0000 (Thu, 06 Jun 2013)
Log Message:
-----------
___version=13.0.16

bug fix: restore command broken  

Modified Paths:
--------------
    branches/v13_0/Jmol/src/org/jmol/script/ScriptEvaluator.java
    branches/v13_0/Jmol/src/org/jmol/viewer/Jmol.properties

Modified: branches/v13_0/Jmol/src/org/jmol/script/ScriptEvaluator.java
===================================================================
--- branches/v13_0/Jmol/src/org/jmol/script/ScriptEvaluator.java        
2013-06-06 13:21:29 UTC (rev 18297)
+++ branches/v13_0/Jmol/src/org/jmol/script/ScriptEvaluator.java        
2013-06-06 13:47:32 UTC (rev 18298)
@@ -14019,26 +14019,26 @@
 
   private void restore() throws ScriptException {
     // restore orientation name time
+    int tok = tokAt(1);
     if (statementLength > 1) {
       String saveName = optParameterAsString(2);
-      if (getToken(1).tok != Token.orientation)
-        checkLength23();
-      float timeSeconds;
-      switch (getToken(1).tok) {
+      int len = 2;
+      switch (tok) {
       case Token.rotation:
-        timeSeconds = (statementLength > 3 ? floatParameter(3) : 0);
+      case Token.orientation:
+        float timeSeconds = (statementLength > 4 ? -1 : statementLength == 4 ? 
floatParameter(++len) : 0);
         if (timeSeconds < 0)
           error(ERROR_invalidArgument);
-        if (!isSyntaxCheck)
+        if (isSyntaxCheck)
+          return;
+        if (tok == Token.rotation)
           viewer.restoreRotation(saveName, timeSeconds);
-        return;
-      case Token.orientation:
-        timeSeconds = (statementLength > 3 ? floatParameter(3) : 0);
-        if (timeSeconds < 0)
-          error(ERROR_invalidArgument);
-        if (!isSyntaxCheck)
+        else
           viewer.restoreOrientation(saveName, timeSeconds);
         return;
+      }
+      checkLength23();
+      switch (tok) {
       case Token.bonds:
         if (!isSyntaxCheck)
           viewer.restoreBonds(saveName);

Modified: branches/v13_0/Jmol/src/org/jmol/viewer/Jmol.properties
===================================================================
--- branches/v13_0/Jmol/src/org/jmol/viewer/Jmol.properties     2013-06-06 
13:21:29 UTC (rev 18297)
+++ branches/v13_0/Jmol/src/org/jmol/viewer/Jmol.properties     2013-06-06 
13:47:32 UTC (rev 18298)
@@ -9,12 +9,13 @@
 #  Don't use ___ in your text, as that is the key for stripping out
 #  the information saved in the JAR version of this file.
 
-___version=13.0.17
+version=13.0.17
 
 =============================================================================
 
-version=13.0.16
+___version=13.0.16
 
+bug fix: restore command broken  
 bug fix: antialiasing or resizing stray lines problem solved (introduced in 
11.0, 08/2006!)
 bug fix: "display add" by itself should not do anything
 bug fix: Gaussian reader not splitting MO set by model

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
How ServiceNow helps IT people transform IT departments:
1. A cloud service to automate IT design, transition and operations
2. Dashboards that offer high-level views of enterprise services
3. A single system of record for all IT processes
http://p.sf.net/sfu/servicenow-d2d-j
_______________________________________________
Jmol-commits mailing list
Jmol-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-commits

Reply via email to