Closed
Bug 236484
Opened 21 years ago
Closed 21 years ago
menus in menubar still painted as active after popup is dismissed
Categories
(Core :: CSS Parsing and Computation, defect)
Core
CSS Parsing and Computation
Tracking
()
RESOLVED
FIXED
People
(Reporter: p_ch, Assigned: p_ch)
Details
Attachments
(2 files)
19.16 KB,
image/png
|
Details | |
2.73 KB,
patch
|
bzbarsky
:
review+
bzbarsky
:
superreview+
|
Details | Diff | Splinter Review |
Step to reproduce with a fresh gtk2 build:
- click on a menubar menu
- click outside the popup
expected: menubar menu state is back to normal
current: it is still active...
This bug has been revealed by the skin simplifications I've done in menu.css,
popup.css in skin/gtk2. It did not appear when we were using the files in
skin/win (with the menuitem appearance enabled...) that I have now backed out.
Assignee | ||
Comment 2•21 years ago
|
||
Assignee | ||
Comment 3•21 years ago
|
||
This bug appeared after I removed all the references to the attribute
"_moz-menuactive" in menu.css. In nsITheme, this attribute controls the state of
the menu item gtk widget.
What happens is that the style system has no rule involving "_moz-menuactive"
and doesn't take into account its changes.
Problem goes away when I add a dummy rule:
menuitem, menu { border-color:transparent;}
even if this rule is superceded by the appearance...
I guess that a proper fix would involve getting rid of the attribute
"_moz-menuactive" and use the :active state.
Assignee: p_ch → dbaron
Component: Menus → Style System (CSS)
OS: Linux → All
Product: Firefox → Browser
QA Contact: bugzilla → ian
Hardware: PC → All
Target Milestone: Firefox0.9 → ---
Version: unspecified → Trunk
Assignee | ||
Comment 4•21 years ago
|
||
updating summary.
I checked in a workaround into skin/gtk2/menu.css:
menu[_moz-menuactive="true"],
menuitem[_moz-menuactive="true"] {
+ /* dummy rule to force repainting when _moz-menuactive changes */
+ border-color: transparent;
/* color: HighlightText; should be fg[PRELIGHT] */
}
Summary: [GTK2] menus in menubar still active after popup is dismissed → menus in menubar still painted as active after popup is dismissed
Comment 5•21 years ago
|
||
Um... Isn't this what we have WidgetStateChanged() for? If it uses a magic
attribute, it should check it and return true accordingly.
Assignee | ||
Comment 7•21 years ago
|
||
I included also the "focused" attribute that controls the focus state of
textbox
Assignee | ||
Updated•21 years ago
|
Attachment #142973 -
Flags: superreview?(bzbarsky)
Attachment #142973 -
Flags: review?(bzbarsky)
Comment 8•21 years ago
|
||
Comment on attachment 142973 [details] [diff] [review]
patch v1.0
r+sr=bzbarsky, but in general you _do_ want to switch to using content state
changes for this, I would think...
I assume this magic attribute is gtk2-only and hence mac/win/whatever don't
need similar patches.
Attachment #142973 -
Flags: superreview?(bzbarsky)
Attachment #142973 -
Flags: superreview+
Attachment #142973 -
Flags: review?(bzbarsky)
Attachment #142973 -
Flags: review+
Assignee | ||
Comment 9•21 years ago
|
||
(In reply to comment #8)
> I assume this magic attribute is gtk2-only and hence mac/win/whatever don't
> need similar patches.
yes
checked in.
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•