Closed Bug 17989 Opened 25 years ago Closed 25 years ago

[DOGFOOD] Selection AutoScrolling broken when using GFX Scrollbars

Categories

(Core :: DOM: Selection, defect, P1)

defect

Tracking

()

VERIFIED FIXED

People

(Reporter: kinmoz, Assigned: kinmoz)

References

Details

(Whiteboard: [PDT+] [by 11/18])

Selection AutoScrolling doesn't work when using Gfx Scrollbars.

To reproduce:

1. Edit your prefs.js file to include the following line.

         user_pref("nglayout.widget.gfxscrollbars", true);

2. Start the browser and load a page that is larger than the viewable area. This
will force the scrollbars in the content area to appear.

3. Click and hold the mouse over some text and then drag out of the window.

The content area should auto scroll to show you the content that is in the
direction the mouse is moving, but it doesn't.
Status: NEW → ASSIGNED
Target Milestone: M12
Accepting bug. Setting milestone to M12.
Duplicate of 17830?
Whiteboard: [PDT+]
Putting on PDT+ radar.
Priority: P3 → P1
bumping up priority since it's a PDT+
Blocks: 12658
linking to PDT+ tracking bug 12658
*** Bug 17830 has been marked as a duplicate of this bug. ***
[note that 17830 contains additional details not present in this bug report.]
Blocks: 18471
Whiteboard: [PDT+] → [PDT+] [by 11/15]
this has been investigated and Kin has an idea on how to resolve it, he may or
may not need mjudge to help resolve it.
Additional details:
Selection Autoscrolling with gfx-scrollbars actually seems to snap back to the
beginning of the page instead of autoscrolling.

Steps to reproduce:
1. Load a webpage that will be several screenfuls - http://news.bbc.co.uk/
   will do fine.
2. Scroll down or [PgDn] more than one screenful.
3. Attempt to invoke selection autoscrolling by click-dragging down beyond
   the edge of the canvas.

Actual results:
The page will snap back to the top of the first screenful. If you scroll down
to look, less will be selected than was selected just before the canvas bottom
was reached.

This result looks much like what happens when dragging a scrollbar slider down
if the pointer wanders left or right out of the scrollbar, except here the
jump was not back to the origin, but to the top of the page.

Expected result:
Autoscrolling selection of text.

Does not work correctly with:
1999-11-09-11-M11 nightly binary on Windows NT 4.0sp3.
1999-11-10-09-M12, 1999-10-18-08-M11, and other builds in between.

Additional Information:
1. The reporter of bug 17830 says that the same snap-back effect happens
   horizontally - confirmed.
2. Selection autoscrolling *upwards* does work correctly but slowly,
   pixel-by-pixel, not line-by-line of text.
Blocks: 18951
Whiteboard: [PDT+] [by 11/15] → [PDT+] [by 11/18]
I have a fix for this in my tree. I'll probably check it in on 11/18/1999 after
I've had it code reviewed.
Whiteboard: [PDT+] [by 11/18] → [PDT+] [by 11/18] Currently waiting on a code review from evaughan@netscape.com
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Whiteboard: [PDT+] [by 11/18] Currently waiting on a code review from evaughan@netscape.com → [PDT+] [by 11/18]
Fix is checked in and should appear in the 11/19/99 builds.



layout/base/src/nsRangeList.cpp  revision 1.164
        - Added
ConstrainFrameAndPointToAnchorSubtree() and various utility
          methods.

      - Modified HandleDrag() to call ConstrainFrameAndPointToAnchorSubtree().


   layout/html/base/src/nsFrame.cpp  revision 3.176
        - Modified
GetContentAndOffsetFromPoint() to skip over generated
          and anonymous
content frames.

    layout/html/base/src/nsGfxScrollFrame.cpp  revision 3.15

 layout/html/base/src/nsGfxScrollFrame.h    revision 3.8
        - Override the
default nsFrame::GetContentAndOffsetsFromPoint()
          implementation with a
version that calls
          mInner->GetContentAndOffsetsFromPoint(). This
prevents the
          scrollbar frames from being included in the search.


view/src/nsScrollPortView.cpp  revision 3.6
        - Fixed bug where
GetContainerSize() was returning the size of the
          ScrollPortView
instead of the ScrolledView.

r=evaughan@netscape.com??????
Status: RESOLVED → VERIFIED
Verified fixed using:
	- 1999112208 Linux
	- 1999111909 Windows NT 4.0 SP5
	- 1999112208 Mac OS

Please note that, on Linux, I was able to put Mozilla in a state in which
selection autoscrolling no longer functioned. However, I can't reproduce that
state.

(There are also known visual corruption issues during an autoscrolling drag
select on Mac OS & Linux.)
No longer blocks: 18471
No longer blocks: 18951
You need to log in before you can comment on or make changes to this bug.