Bug 605930 - [RTL]Pressing on the search icon on the awesome page shows the dialog in LTR style [r=mfinkle]
authorVivien Nicolas <21@vingtetun.org>
Thu, 21 Oct 2010 19:54:25 +0200
changeset 2264 295bccfd274c416814b02c96d0d2c97e48ac47cf
parent 2263 0b509ae95a0e08b3a810a69b3e4f37273b849ce4
child 2265 f8b592b6b1cf5f6ee73532906af616a7fc4db254
push id1916
push uservnicolas@mozilla.com
push dateThu, 21 Oct 2010 17:54:33 +0000
reviewersmfinkle
bugs605930
Bug 605930 - [RTL]Pressing on the search icon on the awesome page shows the dialog in LTR style [r=mfinkle]
chrome/content/bindings/arrowbox.xml
--- a/chrome/content/bindings/arrowbox.xml
+++ b/chrome/content/bindings/arrowbox.xml
@@ -39,17 +39,17 @@
 <bindings
     xmlns="http://www.mozilla.org/xbl"
     xmlns:xbl="http://www.mozilla.org/xbl"
     xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
 
   <binding id="arrowbox" extends="xul:box">
     <content orient="vertical">
       <xul:box anonid="container" class="panel-arrowcontainer">
-        <xul:box anonid="arrowbox" class="panel-arrowbox">
+        <xul:box anonid="arrowbox" class="panel-arrowbox" dir="ltr">
           <xul:image anonid="arrow" class="panel-arrow"/>
         </xul:box>
         <xul:box class="panel-arrowcontent" flex="1">
           <xul:box class="panel-inner-arrowcontent" xbl:inherits="align,dir,orient,pack,flex">
             <children/>
           </xul:box>
         </xul:box>
       </xul:box>
@@ -87,31 +87,31 @@
               let anchorClass = "";
               let hideArrow = false;
               if (horizPos == 0) {
                 container.orient = "vertical";
                 arrowbox.orient = "";
                 if (vertPos == 0) {
                   hideArrow = true;
                 } else {
-                  arrowbox.style.MozMarginStart = ((anchorRect.left - popupRect.left) + (anchorRect.width / 2) - HALF_ARROW_WIDTH) + "px";
+                  arrowbox.style.marginLeft = ((anchorRect.left - popupRect.left) + (anchorRect.width / 2) - HALF_ARROW_WIDTH) + "px";
                   if (vertPos == 1) {
-                    container.dir = ""; 
+                    container.dir = "ltr"; 
                     anchorClass = "top";
                   } else if (vertPos == -1) {
                     container.dir = "reverse"; 
                     anchorClass = "bottom";
                   }
                 }
               } else if (vertPos == 0) {
                 container.orient = "";
                 arrowbox.orient = "vertical";
                 arrowbox.style.marginTop = ((anchorRect.top - popupRect.top) + (anchorRect.height / 2) - HALF_ARROW_WIDTH) + "px";
                 if (horizPos == 1) {
-                  container.dir = ""; 
+                  container.dir = "ltr"; 
                   anchorClass = "left";
                 } else if (horizPos == -1) {
                   container.dir = "reverse";
                   anchorClass = "right";
                 }
               } else {
                 hideArrow = true;
               }