Closed Bug 1629096 Opened 4 years ago Closed 4 years ago

nsFocusManager should always respect scroll-padding/margin.

Categories

(Core :: DOM: UI Events & Focus Handling, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: emilio, Assigned: emilio)

References

Details

Attachments

(3 files)

Attached file t.html

Consider the attached test-case. Tab forward then backwards.

When tabbing forward, you always see the focused input. when tabbing backwards you don't. I don't think that's acceptable. That's what these properties are supposed to solve in the first place.

We should always do this, otherwise stuff may not end up being visible which is
not acceptable for focus navigation.

Kinda drive-by, but I think this is sane and not risky... This is used for
<select size> / <select multiple>, and only scrolls the option into view (it
only scrolls a single scroll frame, the one inside the <select>).

If the author specifies scroll-padding / margin in there I don't see why we
shouldn't respect it when doing key selection / navigation / etc.

Attachment #9139814 - Attachment description: Bug 1629096 - Honor scroll-padding / margin in nsListControlFrame. r=hiro → Bug 1629096 - Honor scroll-padding / margin in ns{ListControl,MenuPopup}Frame. r=hiro
Keywords: leave-open
Pushed by ealvarez@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/df36546db7e4
Honor scroll-padding / margin in ns{ListControl,MenuPopup}Frame. r=hiro
Pushed by ealvarez@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/cf4823d69b53
Always honor scroll-margin / scroll-padding from nsFocusManager. r=masayuki
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Regressions: 1629827
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: