Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…12cdd6b-5c7d-d5a7-a2ba-d0f0cdb91641
  • Loading branch information
juliantenney committed Aug 19, 2011
1 parent 93dc9e0 commit e6e5602
Show file tree
Hide file tree
Showing 4 changed files with 69 additions and 16 deletions.
26 changes: 26 additions & 0 deletions JMolViewer/jmol/models/caffeine.xyz
@@ -0,0 +1,26 @@
24
Caffeine
H -3.3804130 -1.1272367 0.5733036
N 0.9668296 -1.0737425 -0.8198227
C 0.0567293 0.8527195 0.3923156
N -1.3751742 -1.0212243 -0.0570552
C -1.2615018 0.2590713 0.5234135
C -0.3068337 -1.6836331 -0.7169344
C 1.1394235 0.1874122 -0.2700900
N 0.5602627 2.0839095 0.8251589
O -0.4926797 -2.8180554 -1.2094732
C -2.6328073 -1.7303959 -0.0060953
O -2.2301338 0.7988624 1.0899730
H 2.5496990 2.9734977 0.6229590
C 2.0527432 -1.7360887 -1.4931279
H -2.4807715 -2.7269528 0.4882631
H -3.0089039 -1.9025254 -1.0498023
H 2.9176101 -1.8481516 -0.7857866
H 2.3787863 -1.1211917 -2.3743655
H 1.7189877 -2.7489920 -1.8439205
C -0.1518450 3.0970046 1.5348347
C 1.8934096 2.1181245 0.4193193
N 2.2861252 0.9968439 -0.2440298
H -0.1687028 4.0436553 0.9301094
H 0.3535322 3.2979060 2.5177747
H -1.2074498 2.7537592 1.7203047
53 changes: 39 additions & 14 deletions modules/xerte/preview_xerte_top
Expand Up @@ -21,28 +21,53 @@ function openWindow(params){
window.open(params.url,'xerte_window',"status=0,toolbar=0,location=0,menubar=0,directories=0,resizable=0,scrollbars=0,left=" + String((screen.width / 2) - (params.width / 2)) + ",top=" + String((screen.height / 2) - (params.height / 2)) + ",height=" + params.height + ",width=" + params.width);
}

function make_pop_up(height,width,x,y,bgColour,borderColour,innerHTML,src){
function makePopUp(params)
{
//kill any existing popups
var popup = document.getElementById("popup");
var parent = document.getElementById("popup_parent");

if (popup != null)
{
parent.removeChild(popup);
}

//make the div and style it...
var create_div = document.createElement("DIV");
create_div.style.height = height + "px";
create_div.style.width = width + "px";

create_div.id = 'popup';
create_div.style.height = params.height + "px";
create_div.style.width = params.width + "px";
create_div.style.position = "absolute";
create_div.style.top = x + "px";
create_div.style.left = y + "px";
create_div.style.background = bgColour;
create_div.innerHTML = innerHTML;
create_div.style.border = "1px solid " + borderColour;
document.getElementById("popup_parent").appendChild(create_div);
if(src!=""){

create_div.style.top = params.x + "px";
create_div.style.left = params.y + "px";
create_div.style.background = params.bgColour;
create_div.style.border = "1px solid " + params.borderColour;

//if we make a div, set the innerHTML
if (params.type == 'div'){
create_div.innerHTML = params.src;
}
else if (params.type == 'iframe')
{
var iframe_create_div = document.createElement("IFRAME");
iframe_create_div.src = src;
iframe_create_div.style.height = height + "px";
iframe_create_div.style.width = width + "px";
iframe_create_div.src = params.src;
iframe_create_div.style.height = params.height + "px";
iframe_create_div.style.width = params.width + "px";
iframe_create_div.frameBorder='no';
create_div.appendChild(iframe_create_div);

}

//finally append the div
parent.appendChild(create_div);
}
function killPopUp()
{
var popup = document.getElementById("popup");
var parent = document.getElementById("popup_parent");

parent.removeChild(popup);
}

</script>
Expand Down
3 changes: 2 additions & 1 deletion modules/xerte/scorm/flash.js
Expand Up @@ -6,9 +6,10 @@ document.writeln('<param name="quality" value="high" />');
document.writeln('<param name="scale" value="showAll" />');
document.writeln('<param name="salign" value="T" />');
document.writeln('<param name="bgcolor" value="#ffffff" />');
document.writeln('<param name="wmode" value="opaque" />');
document.writeln('<param name="allowScriptAccess" value="always" />');
document.writeln('<param name="seamlessTabbing" value="0" />');
document.writeln('<param name="flashVars" value="File=' + rloFile + '&FileLocation=' + FileLocation + '&scorm=' + scorm + '&browser=' + browser + '" />');
document.writeln('<embed src="MainPreloader.swf" allowScriptAccess="always" quality="high" scale="showAll" salign="T" bgcolor="#ffffff" WIDTH="100%" HEIGHT="100%" NAME="MainPreloader" ALIGN="middle" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer" flashVars="File=' + rloFile + '&FileLocation=' + FileLocation + '&scorm=' + scorm + '&browser=' + browser + '"/>');
document.writeln('<embed src="MainPreloader.swf" allowScriptAccess="always" quality="high" scale="showAll" salign="T" bgcolor="#ffffff" wmode="opaque" WIDTH="100%" HEIGHT="100%" NAME="MainPreloader" ALIGN="middle" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer" flashVars="File=' + rloFile + '&FileLocation=' + FileLocation + '&scorm=' + scorm + '&browser=' + browser + '"/>');
document.writeln('</object>');
document.writeln('</div></center>');
3 changes: 2 additions & 1 deletion modules/xerte/scorm/rloObject.js
Expand Up @@ -76,10 +76,11 @@ function resizeRLO(w,h){
document.writeln('<param name="salign" value="T" />');
document.writeln('<param name="wmode" value="opaque" />');
document.writeln('<param name="bgcolor" value="#ffffff" />');
document.writeln('<param name="wmode" value="opaque" />');
document.writeln('<param name="allowScriptAccess" value="always" />');
document.writeln('<param name="seamlessTabbing" value="0" />');
document.writeln('<param name="flashVars" value="File=' + rloFile + '&FileLocation=' + FileLocation + '&scorm=' + scorm + '&browser=' + browser + '&templateData=' + templateData + '&templatePath=' + templatePath + '&site_url=' + site + '&linkID=' + link_id + '"/>');
document.writeln('<embed src="MainPreloader.swf" allowScriptAccess="always" wmode="opaque" quality="high" scale="showAll" salign="T" bgcolor="#ffffff" WIDTH="100%" HEIGHT="100%" NAME="' + rloID + '" ALIGN="middle" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer" flashVars="File=' + rloFile + '&FileLocation=' + FileLocation + '&scorm=' + scorm + '&browser=' + browser + '&templateData=' + templateData + '&templatePath=' + templatePath + '&site_url=' + site + '&linkID=' + link_id + '"/>');
document.writeln('<embed src="MainPreloader.swf" allowScriptAccess="always" wmode="opaque" quality="high" scale="showAll" salign="T" bgcolor="#ffffff" wmode="opaque" WIDTH="100%" HEIGHT="100%" NAME="' + rloID + '" ALIGN="middle" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer" flashVars="File=' + rloFile + '&FileLocation=' + FileLocation + '&scorm=' + scorm + '&browser=' + browser + '&templateData=' + templateData + '&templatePath=' + templatePath + '&site_url=' + site + '&linkID=' + link_id + '"/>');

document.writeln('</object>');
document.writeln('</div>');
Expand Down

0 comments on commit e6e5602

Please sign in to comment.