Closed
Bug 871590
Opened 12 years ago
Closed 12 years ago
Improve unified titlebar / toolbar handling
Categories
(Core :: Widget: Cocoa, defect)
Tracking
()
RESOLVED
FIXED
mozilla24
People
(Reporter: mstange, Assigned: mstange)
References
(Depends on 1 open bug)
Details
Attachments
(2 files)
13.69 KB,
patch
|
Details | Diff | Splinter Review | |
12.69 KB,
patch
|
roc
:
review+
|
Details | Diff | Splinter Review |
While working on bug 676241 I noticed some problems with the interaction between -moz-window-titlebar and toolbar.
Assignee | ||
Comment 1•12 years ago
|
||
This patch consists of parts from the patch in bug 625989. It was already reviewed there and is already present on the UX repo as https://hg.mozilla.org/projects/ux/rev/35d68446e000 - these are the parts that can land on mozilla-central.
Assignee | ||
Comment 2•12 years ago
|
||
This patch improves how -moz-appearance:-moz-window-titlebar and -moz-appearance:toolbar determine the unified toolbar height and fixes problems that occured when the content area is extended into the titlebar.
Attachment #748866 -
Flags: review?(roc)
Assignee | ||
Updated•12 years ago
|
Attachment #748859 -
Attachment description: add basic handling of -moz-window-titlebar → part 1: add basic handling of -moz-window-titlebar
Assignee | ||
Updated•12 years ago
|
Assignee: nobody → mstange
Comment on attachment 748866 [details] [diff] [review]
part 2: make it more robust
Review of attachment 748866 [details] [diff] [review]:
-----------------------------------------------------------------
::: widget/cocoa/nsChildView.mm
@@ +2080,3 @@
> for (uint32_t i = 0; i < aThemeGeometries.Length(); ++i) {
> + const nsIWidget::ThemeGeometry& g = aThemeGeometries[i];
> + if ((g.mWidgetType == NS_THEME_WINDOW_TITLEBAR) &&
Don't need the extra parens here
@@ +2099,5 @@
> if ((g.mWidgetType == NS_THEME_MOZ_MAC_UNIFIED_TOOLBAR ||
> g.mWidgetType == NS_THEME_TOOLBAR) &&
> g.mRect.X() <= 0 &&
> + g.mRect.XMost() >= aWindowWidth &&
> + g.mRect.Y() <= aTitlebarBottom) {
Shouldn't aTitlebarBottom be unifiedToolbarbottom here, so we can keep extending the unified toolbar bottom with multiple toolbars?
Assignee | ||
Comment 4•12 years ago
|
||
We could do that, but I don't think we want to. I don't know of any native apps which do it.
Here's a native example where the lower toolbar does not extend the upper one: http://dl.dropbox.com/u/2901861/Screenshots/Bildschirmfoto%202013-05-14%20um%2022.48.08.png
Comment on attachment 748866 [details] [diff] [review]
part 2: make it more robust
Review of attachment 748866 [details] [diff] [review]:
-----------------------------------------------------------------
r+ with that
::: widget/cocoa/nsChildView.mm
@@ +2099,5 @@
> if ((g.mWidgetType == NS_THEME_MOZ_MAC_UNIFIED_TOOLBAR ||
> g.mWidgetType == NS_THEME_TOOLBAR) &&
> g.mRect.X() <= 0 &&
> + g.mRect.XMost() >= aWindowWidth &&
> + g.mRect.Y() <= aTitlebarBottom) {
OK, can you at least set unifiedToolbarBottom to the max of unifiedToolbarBottom and g.mRect.YMost(), so that this doesn't depend on the order of aThemeGeometries?
Attachment #748866 -
Flags: review?(roc) → review+
Assignee | ||
Comment 6•12 years ago
|
||
Good call, will do.
Assignee | ||
Comment 7•12 years ago
|
||
Assignee | ||
Comment 8•12 years ago
|
||
Backed out:
https://hg.mozilla.org/integration/mozilla-inbound/rev/2861d9fba479
Without bug 676241 this appears to cause failed assertions.
Assignee | ||
Comment 9•12 years ago
|
||
Relanded on inbound together with bug 676241:
https://hg.mozilla.org/integration/mozilla-inbound/rev/1eca75a9574f
https://hg.mozilla.org/integration/mozilla-inbound/rev/5d158673711c
Comment 10•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/1eca75a9574f
https://hg.mozilla.org/mozilla-central/rev/5d158673711c
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla24
You need to log in
before you can comment on or make changes to this bug.
Description
•