Bug 1317882 - Fix the height fitting issue of username dropdown in insecure warning case. draft
authorSean Lee <selee@mozilla.com>
Wed, 16 Nov 2016 10:33:46 +0800
changeset 442780 1e2a87fa45c509b835f6a9ca3e8d95aa7d2c5d54
parent 441645 b7f895c1dc2e91530240efbf50ac063a0f8a9cb5
child 537881 5e04b853597ec8aa82468f24aadc543ab442b086
push id36804
push userbmo:selee@mozilla.com
push dateWed, 23 Nov 2016 06:29:11 +0000
bugs1317882
milestone53.0a1
Bug 1317882 - Fix the height fitting issue of username dropdown in insecure warning case. MozReview-Commit-ID: ENrJk2UzTzO
toolkit/content/widgets/autocomplete.xml
--- a/toolkit/content/widgets/autocomplete.xml
+++ b/toolkit/content/widgets/autocomplete.xml
@@ -1245,16 +1245,19 @@ extends="chrome://global/content/binding
             if (numRows > this.maxRows) {
               // Set a fixed max-height to avoid flicker when growing the panel.
               let lastVisibleRowRect = rows[this.maxRows - 1].getBoundingClientRect();
               let visibleHeight = lastVisibleRowRect.bottom - firstRowRect.top;
               this.richlistbox.style.maxHeight =
                 visibleHeight + this._rlbPadding + "px";
             }
 
+            for (let i = 0; i < numRows; i++) {
+              rows[i]._handleOverflow();
+            }
             let lastRowRect = rows[numRows - 1].getBoundingClientRect();
             // Calculate the height to have the first row to last row shown
             height = lastRowRect.bottom - firstRowRect.top +
                      this._rlbPadding;
           }
 
           let animate = this._rlbAnimated &&
                         this.getAttribute("dontanimate") != "true";