r50206 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r50205‎ | r50206 | r50207 >
Date:21:35, 4 May 2009
Author:thomasv
Status:resolved (Comments)
Tags:
Comment:
scrollbar
Modified paths:
  • /trunk/extensions/ProofreadPage/proofread.js (modified) (history)

Diff [purge]

Index: trunk/extensions/ProofreadPage/proofread.js
@@ -551,9 +551,8 @@
552552 self.vertHeight = 700;
553553 }
554554 else{
555 - if(document.selection && !is_gecko){
 555+ if(document.selection && !is_gecko)
556556 self.vertHeight = Math.ceil(document.body.clientHeight*0.4);
557 - }
558557 else
559558 self.vertHeight = Math.ceil(window.innerHeight*0.4);
560559 }
@@ -570,14 +569,13 @@
571570 }
572571 else{
573572 if(!horizontal_layout){
574 - cont_w = self.DisplayWidth+"px";
575573 img_w = self.DisplayWidth;
 574+ self.container_css = "background:#000000; overflow:hidden; width:"+self.DisplayWidth+"px; height:"+self.vertHeight+"px;";
576575 }
577576 else{
578 - cont_w = "100%";
579577 img_w = 0; //prevent the container from being resized when the image is downloaded.
 578+ self.container_css = "background:#000000; overflow-x:hidden; overflow-y:scroll; width:100%; height:"+self.vertHeight+"px;";
580579 }
581 - self.container_css = "background:#000000; overflow:hidden; width:"+cont_w+"; height:"+self.vertHeight+"px;";
582580 image_container.innerHTML = "<img id=\"ProofReadImage\" src=\""+proofreadPageViewURL+"\" width=\""+img_w+"\" />";
583581 image_container.style.cssText = self.container_css;
584582 document.getElementById("wpTextbox1").style.cssText = "height:"+self.vertHeight+"px";

Comments

#Comment by Brion VIBBER (talk | contribs)   21:37, 5 May 2009

IIRC overflow-x and overflow-y aren't universally supported. Any cross-browser issues?

#Comment by ThomasV (talk | contribs)   21:53, 5 May 2009

it looks like there were issues for early versions of firefox (earlier than 1.1) http://annevankesteren.nl/2004/09/overflow

#Comment by ThomasV (talk | contribs)   08:30, 6 May 2009

fixed in 50253

Status & tagging log