Open Bug 1562101 Opened 5 years ago Updated 2 years ago

Kinetic scrolling not working in scroll frames inside XUL popups

Categories

(Core :: Panning and Zooming, defect, P3)

defect

Tracking

()

Tracking Status
firefox69 --- affected

People

(Reporter: violet.bugreport, Unassigned)

References

(Depends on 1 open bug)

Details

STR:

  1. On Ubuntu 18.04, set pref apz.gtk.kinetic_scroll.enabled=true in Nightly.
  2. Go to about:preferences -> Fonts and Colors -> Default font.
  3. Scroll the Default font list

Expected:
Just like the main window, the scrolling of Default font list should be kinetic.

Actually:
It's not kinetic.

Blocks: 1213601

The kinetic scrolling mechanism added in bug 1213601 is built on our asynchronous scrolling (APZ) infrastructure.

Some things in the browser UI don't use APZ to scroll, e.g. because they're a XUL <listbox> rather than an HTML scrolling element. My guess is the font list is one of these.

I don't expect this will change until the relevant parts of the browser UI are rewritten in HTML (which is planned but it's a long-term project).

because they're a XUL <listbox> rather than an HTML scrolling element.

I don't think it's related to XUL element, because I found the same behavior when filing this bug in Bugzilla, which is purely written in HTML.

STR:

  1. Go to https://bugzilla.mozilla.org/query.cgi?format=advanced
  2. Click Custom Search, there is a <select> element with a lot of entries.
  3. Scroll that element.

It's still not kinetic.

I think <select> elements don't use APZ either, because they scroll in increments of 1 entry rather than pixels.

(In reply to Botond Ballo [:botond] from comment #3)

I think <select> elements don't use APZ either, because they scroll in increments of 1 entry rather than pixels.

I investigated this a bit. <select> elements indeed do not use APZ, but it's not because they have some custom scrolling mechanism. They build a XULScroll frame which does have the capability to use APZ. However, they're rendered in a popup window, and APZ is not supported in popup windows; this is tracked in bug 1493208.

Depends on: 1493208

I confirmed also that the situation is similar for the font list in about:preferences: it's a XUL <menulist> element rather than a <select>, but it also builds a XUL scroll frame which is rendered in a popup. So, if we enable APZ in popups, that should start scrolling with APZ as well.

Note that the current pref apz.popups.enabled only enables APZ in popups with remote content, which doesn't apply to either <select> or <menulist>. Popups without remote content don't even use OMTC (off-main-thread compositing), which is a preprequisite for APZ.

I discussed this briefly with Jeff. We wouldn't want to blanket-enable OMTC+APZ for all popups, since that would include things like tooltips and OMTC+APZ is a bit heavyweight for a tooltip. However, it may be reasonable to enable them for popups which actually have scrollable content, such as the <select> and <menulist> popups.

Component: Layout: Scrolling and Overflow → Panning and Zooming
Priority: -- → P3
Summary: Kinetic scrolling not working in some scrolling context → Kinetic scrolling not working in scroll frames inside XUL popups

Bug 1493208 was fixed, but as mentioned, it only enabled APZ in popups with remote content. I filed bug 1682629 to track enabling APZ in scrollable popups without remote content.

Depends on: 1682629
No longer depends on: 1493208
Severity: normal normal → S3 S3
You need to log in before you can comment on or make changes to this bug.