Make scrollbars in trees behave like native GTK scrollbars




13 years ago
7 years ago


(Reporter: ispiked, Unassigned)


1.8 Branch

Firefox Tracking Flags

(Not tracked)



(1 attachment)



13 years ago
I made a patch in bug 303048 that made scrollbars act like native GTK scrollbars; e.g. right click scrolled to the top/bottom of a page and middle click scrolled one page length. Apparently, scrollbars in trees aren't acting like this for some reason.

Comment 1

13 years ago
Do listboxes work? Listboxes and trees have their own nsIScrollbarMediator which handles scrollbar positioning.

Comment 2

13 years ago
Nope. <listbox>es are broken, too. The scrollbar buttons don't seem to be getting set as unactive when I release from a middle or right click, either. :(
So, what happens here is that neither listboxes or trees set an increment on their scrollbar, so they assume that the increment will only be ±1 and calculate the "real" increment based on the sign of the increment.

Alternatively, you could blame listboxes and trees for using weird units for their scroll positioning when they should use lines instead.


11 years ago
Assignee: ispiked → jag
Assignee: jag → nobody

Comment 4

7 years ago
Created attachment 562871 [details] [diff] [review]
Initial attempt: Convert pixels to lines if needed.

If the magnitude of the delta of the indexes (old and new) is greater than a row's height, then convert the delta into lines.  

Will this approach be useful, or will it add complications I'm not seeing?
You need to log in before you can comment on or make changes to this bug.