#9238: J. Gutow's update to Jmol in the notebook...
---------------------------------------------------------------+------------
Reporter: gutow |
Owner: gutow
Type: enhancement |
Status: needs_review
Priority: major |
Milestone: sage-4.7.2
Component: notebook |
Keywords: sd31, sd32
Work_issues: |
Upstream: N/A
Reviewer: Jason Grout, Karl-Dieter Crisman, William Stein |
Author: Jonathan Gutow
Merged: |
Dependencies:
---------------------------------------------------------------+------------
Comment(by strogdon):
I've tested some of the features of this ticket on vanilla
sage-4.7.2.alpha2 and I have some questions. I installed
Jmol_for_SageNoteBook-1.1.6.spkg and applied the patches
{{{
trac_9238_interactive_js.patch
trac_9238-add-help.patch
trac_9238_jmol_lib_async.patch
}}}
The add-help patch would not apply with the response that a JmolHelp.html
file already existed. I did not attempt to apply the IE patches. After
applying the patches I issued "sage -b" and started sage and the notebook.
Now when I load a worksheet that has Jmol applets I get pop-ups. If there
are numerous applets, I get numerous pop-ups. These pop-ups seem to be
triggered by the follow alerts in trac_9238_jmol_lib_async.patch
{{{
+ if(loading>=0){//we found a loading applet
+ jmolStatus.attempts[loading]+=1; //update number of checks for
load completion.
+ if(jmolStatus.defaultdirectory[loading]=="done"){//Applet is
ready.
+ jmolAppletLive(loading);
+ }else{ //Applet not ready. How many checks have we done?
+ if(jmolStatus.attempts[loading]==10){
+ alert("Jmol Applet #"+loading+" is having trouble
loading. Will retry once.");
+ var scriptStr = 'x=defaultdirectory; data "directory
@x";';
+ scriptStr += 'set MessageCallback "jmolMessageHandler";
show defaultdirectory;';
+ jmolScript(scriptStr);
+ }
+ if(jmolStatus.attempts[loading]==20){
+ alert("Second attempt to finish launch of Jmol Applet
#"+loading+" failed. Recommend reevaluating the cell manually.");
+ jmolStatus.jmolArray[loading]=-2; //launch failed.
+ }
+ }
+ }else{//no loading applets. Search for queued applet.
}}}
since the quoted expressions in the alerts appear in the pop-ups. Loading
the applets is extremely slow and the pop-ups have to be "clicked" before
loading continues. Now if I do not install trac_9238_jmol_lib_async.patch
then I do not get the pop-ups and the loading of the applets is much
faster. I have used Firefox 3 and Firefox 6 with the same result. Are the
pop-ups a feature or is the jmol_lib_async only intended for safari
browsers?
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/9238#comment:172>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.