Closed
Bug 449442
Opened 17 years ago
Closed 16 years ago
Use native-styled statusbar with gradient instead of css background-image
Categories
(Core :: Widget: Cocoa, defect)
Tracking
()
RESOLVED
FIXED
mozilla1.9.2a1
People
(Reporter: stefanh, Assigned: mstange)
References
Details
(Keywords: fixed1.9.1)
Attachments
(4 files, 2 obsolete files)
|
4.43 KB,
patch
|
dao
:
review+
|
Details | Diff | Splinter Review |
|
226.53 KB,
image/png
|
faaborg
:
ui-review+
|
Details |
|
227.97 KB,
image/png
|
faaborg
:
ui-review-
|
Details |
|
5.56 KB,
patch
|
beltzner
:
approval1.9.1+
|
Details | Diff | Splinter Review |
| Assignee | ||
Comment 1•17 years ago
|
||
Firefox's statusbar is actually a little strange.
On OS X, there's a difference between status bars and bottom bars. Bottom bars have a gradient and rounded bottom corners (see e.g. a Finder window); status bars have square corners and no gradient (see Safari).
I'd like to suggest drawing the native-styled statusbar (which this bug is about) with a solid color, the dark chrome grey. Later on we could add another -moz-appearance for bottom bars with gradients and rounded corners which would be used e.g. in the Download Manager.
| Assignee | ||
Comment 2•16 years ago
|
||
(In reply to comment #1)
> I'd like to suggest drawing the native-styled statusbar (which this bug is
> about) with a solid color, the dark chrome grey.
I've changed my mind. Let's keep the gradient.
| Assignee | ||
Comment 3•16 years ago
|
||
This hunk might need explanation:
@@ -1837,18 +1904,18 @@ nsNativeThemeCocoa::GetWidgetBorder(nsID
- case NS_THEME_MOZ_MAC_UNIFIED_TOOLBAR:
- aResult->SizeTo(0, 0, 1, 0);
+ case NS_THEME_STATUSBAR:
+ aResult->SizeTo(0, 1, 0, 0);
break;
}
I'm removing the bogus widget border for the unified toolbar I added in bug 439354; a border on the right makes no sense. And a border on the bottom creates problems (e.g. the hidden "menubar" at the top of the window appears).
The statusbar gets a 1px top border, although a 2px top border is rendered. That's because the second top border shouldn't take space away from the content.
Assignee: joshmoz → mstange
Status: NEW → ASSIGNED
Attachment #353431 -
Flags: superreview?(roc)
Attachment #353431 -
Flags: review?(joshmoz)
| Assignee | ||
Comment 4•16 years ago
|
||
Attachment #353438 -
Flags: review?(dao)
Comment 5•16 years ago
|
||
Comment on attachment 353438 [details] [diff] [review]
CSS part, v1
> #main-window:not([active="true"]) > #navigator-toolbox > toolbar > toolbaritem,
>-#main-window:not([active="true"]) > #navigator-toolbox > toolbar > toolbarbutton,
>-#main-window:not([active="true"]) > #browser-bottombox {
>+#main-window:not([active="true"]) > #navigator-toolbox > toolbar > toolbarbutton {
> opacity: 0.75;
> }
What about the findbar as part of #browser-bottombox?
| Assignee | ||
Comment 6•16 years ago
|
||
That was a deliberate change; in native Mac apps, find bars don't fade.
Updated•16 years ago
|
Attachment #353438 -
Flags: review?(dao) → review+
I think DrawStatusBar should handle the case where the status bar is 0 or 1px high by bailing out instead of doing something weird.
Also, can you explain why you changed your mind in comment #2?
| Assignee | ||
Comment 8•16 years ago
|
||
Attachment #353431 -
Attachment is obsolete: true
Attachment #353532 -
Flags: superreview?(roc)
Attachment #353532 -
Flags: review?(joshmoz)
Attachment #353431 -
Flags: superreview?(roc)
Attachment #353431 -
Flags: review?(joshmoz)
| Assignee | ||
Comment 9•16 years ago
|
||
(In reply to comment #7)
> Also, can you explain why you changed your mind in comment #2?
This way I don't have to add another -moz-appearance for the bottom bar in the Downloads window :)
And I think the gradient looks better... but let's have Faaborg make that decision.
| Assignee | ||
Comment 10•16 years ago
|
||
Attachment #353535 -
Flags: ui-review?(faaborg)
| Assignee | ||
Updated•16 years ago
|
Attachment #353535 -
Attachment is patch: false
Attachment #353535 -
Attachment mime type: text/plain → image/png
| Assignee | ||
Comment 11•16 years ago
|
||
Alex, which one do you prefer?
Attachment #353537 -
Flags: ui-review?(faaborg)
Comment on attachment 353532 [details] [diff] [review]
render part, v2
+ if (inBoxRect.size.height <= 1.0f)
+ return;
I think < 2.0f would be better.
Attachment #353532 -
Flags: superreview?(roc) → superreview+
| Reporter | ||
Comment 13•16 years ago
|
||
fwiw, Camino uses a "gradient-style" statusbar.
(In reply to comment #13)
> fwiw, Camino uses a "gradient-style" statusbar.
At some point (I can't find it now) we had a discussion that we weren't using the "right" look for a status bar, but apparently we decided we didn't care.
Given that the "status bars" in Gecko apps often contain some form of control (via extensions and so forth), the bottom bar probably makes more sense.
| Reporter | ||
Comment 15•16 years ago
|
||
> Given that the "status bars" in Gecko apps often contain some form of control
> (via extensions and so forth), the bottom bar probably makes more sense.
Yeah, the Safari-styled status bar would only make sense in one window (browser.xul). And a bottom bar actually looks better. Also, going for the Safari-styled status bar would probably mean that the css style rules should go in browser/themes/ rather than toolkit/themes/global.
Comment 16•16 years ago
|
||
I think users probably won't be able to catch the subtle difference between if something should be a bottom bar (gradient, rounded corners) and a native status bar (no gradient, square corners). And since bottom bars seem to appear in the OS considerably more often then status bars (is Safari the only example?) this might be a case where doing the wrong thing ultimately looks more right than doing the right thing. So, by that logic we should use a bottom bar style on a bar that is only as tall as a status bar.
Overall though, I really would like for us to eventually remove the status bar (if no extensions have modified it), since that seems more respectful to the content area, and is visually cleaner (bug 425584).
Updated•16 years ago
|
Attachment #353535 -
Flags: ui-review?(faaborg) → ui-review+
Comment 17•16 years ago
|
||
Comment on attachment 353535 [details]
Screenshot: gradient-style statusbar
Sorry, forgot to set the review flags back on 12/18, see the comment above for rationale.
Comment 18•16 years ago
|
||
Comment on attachment 353537 [details]
Screenshot: Safari-style statusbar
Sorry, forgot to set the review flags back on 12/18, see comment #16 for
rationale.
Attachment #353537 -
Flags: ui-review?(faaborg) → ui-review-
Attachment #353532 -
Flags: review?(joshmoz) → review+
Comment 19•16 years ago
|
||
Comment on attachment 353532 [details] [diff] [review]
render part, v2
>+ GreyGradientInfo* info = (GreyGradientInfo*)aInfo;
new-style static_cast please
>+ CGShadingRef shading = CGShadingCreateAxial(colorSpace,
>+ CGPointMake(0, CGRectGetMinY(rect)),
>+ CGPointMake(0, CGRectGetMaxY(rect)),
>+ function, NO, NO);
Please use "false" instead of "NO" because this is C not Obj-C (bool vs. BOOL).
r+ but please post a new patch for whatever you check in
| Assignee | ||
Comment 20•16 years ago
|
||
Attachment #353532 -
Attachment is obsolete: true
| Assignee | ||
Comment 21•16 years ago
|
||
Checked in:
http://hg.mozilla.org/mozilla-central/rev/e666dabedee5
http://hg.mozilla.org/mozilla-central/rev/c7538401b1c9
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.2a1
| Assignee | ||
Updated•16 years ago
|
Attachment #353532 -
Flags: approval1.9.1?
| Assignee | ||
Updated•16 years ago
|
Attachment #355572 -
Flags: approval1.9.1?
Comment 22•16 years ago
|
||
Comment on attachment 353532 [details] [diff] [review]
render part, v2
a191=beltzner; doesn't look like there was a perf hit from doing this on trunk, but please watch for it carefully when you land on branch
Attachment #353532 -
Flags: approval1.9.1? → approval1.9.1+
Comment 23•16 years ago
|
||
Comment on attachment 355572 [details] [diff] [review]
render part, v2.1, for checkin
a191=beltzner
Attachment #355572 -
Flags: approval1.9.1? → approval1.9.1+
| Assignee | ||
Comment 24•16 years ago
|
||
http://hg.mozilla.org/releases/mozilla-1.9.1/rev/d76f278e4c6c
http://hg.mozilla.org/releases/mozilla-1.9.1/rev/ee511803c7d6
Keywords: fixed1.9.1
| Assignee | ||
Comment 25•16 years ago
|
||
(In reply to comment #22)
> (From update of attachment 353532 [details] [diff] [review])
> a191=beltzner; doesn't look like there was a perf hit from doing this on trunk,
> but please watch for it carefully when you land on branch
It looks like the landing even resulted in a slight perf improvement, or at least the numbers are more stable now:
>http://graphs-new.mozilla.org/graph.html#tests=[{%22test%22:%2217%22,%22branch%22:%223%22,%22machine%22:%2236%22},{%22test%22:%2217%22,%22branch%22:%223%22,%22machine%22:%2237%22},{%22test%22:%2217%22,%22branch%22:%223%22,%22machine%22:%2238%22},{%22test%22:%2217%22,%22branch%22:%223%22,%22machine%22:%2239%22},{%22test%22:%2217%22,%22branch%22:%223%22,%22machine%22:%2249%22}]&sel=1238206294,1238442360
You need to log in
before you can comment on or make changes to this bug.
Description
•