Mercurial > hg > webaudioevaluationtool
changeset 395:629b96c14ee1 Dev_main
Bug #1467: Popup resize created and bound to Interface.resize()
author | Nicholas Jillings <n.g.r.jillings@se14.qmul.ac.uk> |
---|---|
date | Fri, 11 Dec 2015 11:19:11 +0000 |
parents | d0073ab16551 |
children | 76638abe1414 |
files | core.js |
diffstat | 1 files changed, 11 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/core.js Fri Dec 11 11:06:21 2015 +0000 +++ b/core.js Fri Dec 11 11:19:11 2015 +0000 @@ -569,6 +569,16 @@ } } }; + + this.resize = function(event) + { + // Called on window resize; + this.popup.style.left = (window.innerWidth/2)-250 + 'px'; + this.popup.style.top = (window.innerHeight/2)-125 + 'px'; + var blank = document.getElementsByClassName('testHalt')[0]; + blank.style.width = window.innerWidth; + blank.style.height = window.innerHeight; + }; } function advanceState() @@ -2160,6 +2170,7 @@ this.resizeWindow = function(event) { + popup.resize(event); for(var i=0; i<this.commentBoxes.length; i++) {this.commentBoxes[i].resize();} for(var i=0; i<this.commentQuestions.length; i++)