Closed Bug 865591 Opened 7 years ago Closed 7 years ago

visible menu item have offscreen state

Categories

(Core :: Disability Access APIs, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla24

People

(Reporter: surkov, Assigned: surkov)

References

(Blocks 1 open bug)

Details

(Keywords: access, regression)

Attachments

(1 file)

we were reported the bug that menu items of Firefox menu have offscreen state (except top level menu items).
Robert, perhaps you could help. We walk up from menu frame to containing XUL scroll frame and then check whether their rects are intersected (http://mxr.mozilla.org/mozilla-central/source/accessible/src/generic/Accessible.cpp#657). In case of menu items they aren't and we conclude that menu item is not visible. Could you please take a look perhaps you will see what's wrong with our code.

I'd guess that menus are special so it doesn't really make sense to check whether its rect is intersected with parent scrollable frame since it can be out of Firefox window boundaries. If so then what a correct way to check whether menuitem is visible or not?
Don't bother checking the ancestors of any frame for which nsLayoutUtils::IsPopup returns true.
regressed in Firefox 18
Keywords: regression
(In reply to Robert O'Callahan (:roc) (Mozilla Corporation) from comment #2)
> Don't bother checking the ancestors of any frame for which
> nsLayoutUtils::IsPopup returns true.

ok, good, thank you. But how to detect whether a menuitem (or nsLayoutUtils::IsPopup() == true frame) is invisible (its menu is not shown) or it is offscreen (when menuitem is scrolled off)?
you can check whether the popup is visible using frame->GetView()->GetViewVisibility() == nsViewVisibility_kShow
Alex, will you be acting on this bug soon?
yes, hopefully
Blocks: 2013q2a11y
Attached patch patchSplinter Review
Assignee: nobody → surkov.alexander
Status: NEW → ASSIGNED
Attachment #748737 - Flags: review?(trev.saunders)
Attachment #748737 - Flags: review?(trev.saunders) → review+
https://hg.mozilla.org/mozilla-central/rev/820f28f1f2ce
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla24
Flags: in-testsuite+
You need to log in before you can comment on or make changes to this bug.