Open Bug 814565 Opened 7 years ago Updated Last year

UI glitch - clear recent history dialog does not shrink when collapsing details

Categories

(Core :: Widget, defect, P4)

17 Branch
x86
All
defect

Tracking

()

Tracking Status
firefox18 - ---
firefox19 - ---
firefox20 - ---
firefox22 --- affected
firefox23 --- affected
firefox24 --- affected
firefox25 --- affected

People

(Reporter: alice0775, Unassigned)

References

(Blocks 1 open bug)

Details

(Keywords: regression, Whiteboard: tpi:+)

Attachments

(1 file)

Build Identifier:
http://hg.mozilla.org/mozilla-central/rev/3b71d63eafd5
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:20.0) Gecko/20.0 Firefox/20.0 ID:20121122030852

See http://forums.mozillazine.org/viewtopic.php?f=9&t=2621255 .
The height of "clear recent history dialog" does not shrink when collapse listbox.


Steps to reproduce:
1. Open the Clear Recent History Dialog(Ctrl+Shift+Del)
2. Click the details expander button
3. Click it again to collapse the details

Actual results:
The height of the dialog does not shrink

Regression window(m-c)
Good:
http://hg.mozilla.org/mozilla-central/rev/23a7ba542bb5
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/17.0 Firefox/17.0 ID:20120730135738
Bad:
http://hg.mozilla.org/mozilla-central/rev/1ab429a89429
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/17.0 Firefox/17.0 ID:20120731055938
Pushlog:
http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=23a7ba542bb5&tochange=1ab429a89429

Regression window(m-i)
Good:
http://hg.mozilla.org/integration/mozilla-inbound/rev/56e0971c81ea
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/17.0 Firefox/17.0 ID:20120730192943
Bad:
http://hg.mozilla.org/integration/mozilla-inbound/rev/6d9745a02c2d
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/17.0 Firefox/17.0 ID:20120730194637
Pushlog:
http://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=56e0971c81ea&tochange=6d9745a02c2d

In local build:
Last Good: de293780ba8a
First Bad: b8a0228a10fa
Regressed by:
	b8a0228a10fa	Neil Deakin — Bug 357725, support minimum and maximum size constraints on windows and popups, r=mats,jmathies,karlt,smichaud,sr=neil
OS: Windows 7 → All
Not critical enough to track for release, although we would take a low risk fix on branches.
Assignee: nobody → enndeakin
Duplicate of this bug: 834021
FWIW, it looks like the code that is supposed to shrink the dialog is line 238 here:

> 229   /**
> 230    * Hide the history items list.
> 231    */
> 232   hideItemList: function () {
> 233     var itemList = document.getElementById("itemList");
> 234     var expanderButton = document.getElementById("detailsExpander");
> 235 
> 236     if (!itemList.collapsed) {
> 237       expanderButton.className = "expander-down";
> 238       window.resizeBy(0, -itemList.boxObject.height);
> 239       itemList.setAttribute("collapsed", "true");
> 240     }
https://mxr.mozilla.org/mozilla-central/source/browser/base/content/sanitizeDialog.js#246

That resizeBy call is apparently having no effect.
Duplicate of this bug: 888696
Duplicate of this bug: 888699
howdy y'all,

User Agent: Mozilla/5.0 (Windows NT 6.1; rv:22.0) Gecko/20100101 Firefox/22.0

the dialog DOES shrink. unfortunately, it shrinks only after the 1st cycle of the details button. that leaves the large-ish blank section from the earlier fail-to-shrink in place.

take care,
lee
Duplicate of this bug: 891949
Duplicate of this bug: 919115
Duplicate of this bug: 921702
Happens on Mac Nightly Release 27a1, too.
Duplicate of this bug: 1067048
Duplicate of this bug: 1146322
Duplicate of this bug: 1148975
Duplicate of this bug: 1160435
Since this is still open 15 cycles after it was reported, I had a quick look at the code -- an idea: maybe the resize-down fails because you're not collapsing the list element first, and it's set to not resize smaller than the control sizes that fit in the dialog, somewhere?
If so, then simply collapsing BEFORE the size-down and expanding AFTER the size-up would fix it, I think.
Flags: needinfo?(dholbert)
I experimented a little and my idea in comment 15 didn't work.

Perhaps the issue here is that the prefpane element resizes automatically to fit the expanded listbox into it, which prevents the window from being sized down (since I don't think it automatically shrinks again). When expanded a second time, the extra space at the bottom won't be taken up by the auto-expanded prefpane and as such can be shrunk again? I'm not intimitely familiar with the inherent behavior of the different XUL controls, so maybe someone in-the-know can shed some light on that.
Flags: needinfo?(dholbert)
Assignee: enndeakin → nobody
Duplicate of this bug: 1242858
Duplicate of this bug: 1251535
Blocks: fx-qx
See Also: → 1200045
In experiment,

1. when remove `persist="collapsed"` from sanitize.xul, The UI wont expand longer any more. But the window still does not shrink after collapse

https://dxr.mozilla.org/mozilla-central/source/browser/base/content/sanitize.xul#143

2. remove window.resizeBy statements in showItemList/hideItemList does not effect anything

https://dxr.mozilla.org/mozilla-central/source/browser/base/content/sanitizeDialog.js#230
This sounds a lot like bug 1247824, but in a different place.
Priority: -- → P4
Duplicate of this bug: 1277864
Priority: P4 → P1
Whiteboard: tpi:+
Duplicate of this bug: 1288893
Changing back to a P4, not sure why this got bumped up.
Priority: P1 → P4
Summary: UI glitch with clear recent history dialog → UI glitch - clear recent history dialog does not shrink when collapsing details
As the "Clear recent history" dialog has been converted to be in-content in bug 1036595, it would have been great to fix this UI bug with too.
Duplicate of this bug: 1336658
Duplicate of this bug: 1390218
You need to log in before you can comment on or make changes to this bug.