- String mset[] = new String[viewer.ms.mc];
- _modelFileNameMap = new int[mset.length];
- String m = viewer.ms.getModelFileName(0);
- if (m != null)
- {
- mset[0] = m;
- try
- {
- mset[0] = new File(m).getAbsolutePath();
- } catch (AccessControlException x)
- {
- // usually not allowed to do this in applet
- System.err
- .println("jmolBinding: Using local file string from Jmol: "
- + m);
- }
- if (mset[0].indexOf("/file:") != -1)
- {
- // applet path with docroot - discard as format won't match pdbfile
- mset[0] = m;
- }
- }
- int j = 1;
- for (int i = 1; i < mset.length; i++)
+ int modelCount = viewer.ms.mc;
+ String filePath = null;
+ for (int i = 0; i < modelCount; ++i)