Update '12/index.html'

master
Max Lehmann 5 years ago
parent bfcd549220
commit 879d556198

@ -41,7 +41,7 @@
</div>
<div id="implicancies_05">
<div id="shell_03" class="" onmousedown='mydragg.startMoving(this,"container",event);' onmouseup='mydragg.stopMoving("container");'><div class="" id="shell_03header">click here do move</div><iframe name="shell" id="iframe_clock" src='blank12_5.html'></iframe></div>
<div id="shell_03" class=""><div class="" id="shell_03header">click here do move</div><iframe name="shell" id="iframe_clock" src='blank12_5.html'></iframe></div>
<div id="info">
<div id="title"></div>
<div id="authors"></div>
@ -300,59 +300,7 @@
document.querySelector("#implicancies_05 #resources_05").classList.toggle("hidden");
});
var mydragg = function(){
return {
move : function(divid,xpos,ypos){
divid.style.left = xpos + 'px';
divid.style.top = ypos + 'px';
},
startMoving : function(divid,container,evt){
evt = evt || window.event;
var posX = evt.clientX,
posY = evt.clientY,
divTop = divid.style.top,
divLeft = divid.style.left,
eWi = parseInt(divid.style.width),
eHe = parseInt(divid.style.height),
cWi = parseInt(document.getElementById(container).style.width),
cHe = parseInt(document.getElementById(container).style.height);
document.getElementById(container).style.cursor='move';
divTop = divTop.replace('px','');
divLeft = divLeft.replace('px','');
var diffX = posX - divLeft,
diffY = posY - divTop;
document.onmousemove = function(evt){
evt = evt || window.event;
var posX = evt.clientX,
posY = evt.clientY,
aX = posX - diffX,
aY = posY - diffY;
if (aX < 0) aX = 0;
if (aY < 0) aY = 0;
if (aX + eWi > cWi) aX = cWi - eWi;
if (aY + eHe > cHe) aY = cHe -eHe;
mydragg.move(divid,aX,aY);
}
},
stopMoving : function(container){
var a = document.createElement('script');
document.getElementById(container).style.cursor='default';
document.onmousemove = function(){}
},
}
}();
</script>
</body>

Loading…
Cancel
Save