Egon, these are recent changes relating to the popup menu needed to have 
a list of HETATM groups.

Your fixes are right on target. Shouldn't be any other problem. In
countGroups I opted for

    if (group3Lists == null || group3Lists[modelIndex] == null)
      return;

instead of checking isPDB, as it's more directly related.

Bob

Egon Willighagen wrote:

>On Tuesday 24 October 2006 23:07, Egon Willighagen wrote:
>
>>when updating Jmol in Bioclipse, I found that current SVN gave a
NullPointerException on line 572 of org.jmol.viewer.Frame.
>>Not sure what is causing this; I'm using the CDK IO here, but the
Adapter
>>interface does not seem to have a method for modelSetAuxiliaryInfo...
Did I overlook something?
>>Anyway, I applied this patch, and then it worked:
>>--- src/org/jmol/viewer/Frame.java      (revision 6012)
>>+++ src/org/jmol/viewer/Frame.java      (working copy)
>>@@ -569,6 +569,8 @@
>>     if (group3Lists == null)
>>       return;
>>     Hashtable info = getModelSetAuxiliaryInfo();
>>+    if (info == null)
>>+      return;
>>     info.put("group3Lists", group3Lists);
>>     info.put("group3Counts", group3Counts);
>>   }
>>
>Related to this seems to be another NPE at line 673:
>int pt = group3Lists[modelIndex].indexOf(g3code);
>where
>group3Lists[modelIndex]
>is null...
>Weird enough the field is indeed not initialized, because (line 283)
isPDBModel == false... which seems to be caused by 'info' (first problem)
==
>null...
>Bob, I'm sure I'm doing something wrong, but not sure what... ideas?
Adding this patch solved the second problem:
>@@ -669,6 +671,7 @@
>   }
>   void countGroup(int modelIndex, String code, String group3) {
>+    if (!isPDB) return;
>     String g3code = (group3 + "   ").substring(0, 3);
>     int pt = group3Lists[modelIndex].indexOf(g3code);
>     if (pt < 0) {
>Egon
>







-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Jmol-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-developers

Reply via email to