Bug 197123 - When resizing tree columns, make the rightmost column compensate the width difference instead of the column directly after the resized one. ui-r=faaborg, r=enndeakin
authorMarkus Stange <mstange@themasta.com>
Mon, 05 Oct 2009 15:19:20 +1300
changeset 33514 586c0c651891e12d0a9a5fbf33af091b804417fc
parent 33513 54e0f634d9616c0b6b6be62aa776bd66da1b8eb5
child 33515 f47c8163a2a5fd2de3af40a469d08f700fb75e6b
push idunknown
push userunknown
push dateunknown
reviewersfaaborg, enndeakin
bugs197123
milestone1.9.3a1pre
Bug 197123 - When resizing tree columns, make the rightmost column compensate the width difference instead of the column directly after the resized one. ui-r=faaborg, r=enndeakin
toolkit/content/widgets/tree.xml
--- a/toolkit/content/widgets/tree.xml
+++ b/toolkit/content/widgets/tree.xml
@@ -903,16 +903,24 @@
     <implementation implements="nsIAccessibleProvider">
       <property name="accessibleType" readonly="true">
         <getter>
           <![CDATA[
             return Components.interfaces.nsIAccessibleProvider.XULTreeColumns;
           ]]>
         </getter>
       </property>
+      <constructor><![CDATA[
+        // Set resizeafter="farthest" on the splitters if nothing else has been
+        // specified.
+        Array.forEach(this.getElementsByTagName("splitter"), function (splitter) {
+          if (!splitter.hasAttribute("resizeafter"))
+            splitter.setAttribute("resizeafter", "farthest");
+        });
+      ]]></constructor>
     </implementation>
   </binding>
 
   <binding id="treerows" extends="chrome://global/content/bindings/tree.xml#tree-base">
     <content>
       <xul:hbox flex="1" class="tree-bodybox">
         <children/>
       </xul:hbox>