Closed Bug 180015 Opened 22 years ago Closed 20 years ago

[FIX] {drag-select} Scrolling by selecting & dragging jumps to top of page when marquee tag is encountered

Categories

(Core :: DOM: Selection, defect)

x86
All
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: dansoper, Assigned: MatsPalmgren_bugz)

References

Details

(Keywords: testcase)

Attachments

(2 files, 1 obsolete file)

User-Agent:       Mozilla/5.0 (Windows; U; Win98; es-ES; m18) Gecko/20010131 Netscape6/6.01
Build Identifier: Mozilla 1.0.1 build 2002082606

When selecting text in any page that contains a < marquee >, when the selection
reaches that marquee the browser immediately jumps to the top of the page.

Reproducible: Always

Steps to Reproduce:
1. Find a page which uses the Marquee tag.
2. Click on text in the page and drag downwards ot select.
3. Continue to drag below the bottom of the browser window, so the page scrolls
downward as the selection grows.


Actual Results:  
When the selection reaches the marquee, the page jumps right back up to the top.

Expected Results:  
Keep on scrolling (and selecting) downwards.

Reproducibility: doesn't happen *every* time, but very nearly.
My browser User-Agent ain't what it says in that report, btw. :-)
For how long should a bug be "unconfirmed" before the reporter (me) is entitled
to think it's been ignored or overlooked?

Whatever, shortly after posting the bug I discovered how to switch off the
marquee tag by adding:

     marquee { -moz-binding: none; }

to UserContent.css, which I immediately did.
How about attaching a testcase?
Attached file Test case
Apologies for the delay.

Attaching a simple html page in which the bug may be observed: Select text in
the page, and drag downwards so the page scrolls. The text "Scrolling text..."
is in the marquee tag, so when you've scrolled down that far, position your
mouse such that the marquee text is partly selected. Hold the mouse still at
this point, and wait for the marquee to scroll around again. As soon as the
beginning of the marquee text reaches your mouse pointer, the page jumps up to
the top, as described in my original report. If nothing happens, a slight
movement of the mouse might be necessary.

I have found this bug is also present in Phoenix.
I still see this in
Mozilla/5.0 (Windows; U; Win98; de-AT; rv:1.4b) Gecko/20030502
Status: UNCONFIRMED → NEW
Ever confirmed: true
Bug also occurs in Linux trunk build 2004-07-23-06. Steps to reproduce:
load testcase, scroll to end, click on the last text and drag upwards, when
you reach the marquee - move the mouse to the *right* of it.
Keywords: testcase
OS: Windows 98 → All
Drag-selection in the testcases for bug 97283 and bug 56602 also triggers
the same bug and results in "impossible" selection regions sometimes.
Taking bug as I have a fix for this...
Assignee: mjudge → mats.palmgren
Summary: Scrolling by selecting & dragging jumps to top of page when marquee tag is encountered → [FIX] {drag-select} Scrolling by selecting & dragging jumps to top of page when marquee tag is encountered
Attached patch Patch rev. 1 (obsolete) — Splinter Review
When dispatching the event to a new frame we must translate the event position
the new frame's closest view (when different).
Attachment #154304 - Flags: superreview?(dbaron)
Attachment #154304 - Flags: review?(bzbarsky)
Comment on attachment 154304 [details] [diff] [review]
Patch rev. 1

r=bzbarsky
Attachment #154304 - Flags: review?(bzbarsky) → review+
Attachment #154304 - Flags: superreview?(dbaron) → superreview+
Is there a reason this patch hasn't been checked in?
Blocks: 263099
*** Bug 206861 has been marked as a duplicate of this bug. ***
*** Bug 217164 has been marked as a duplicate of this bug. ***
There might be a good reason why this patch (which has review+ and
supperreview+) never got checked in, but it could also be that this patch simply
is forgotten, not?
So if soemone could confirm there is a reason other than that is forgotten, then
I won't "harass" this bug again.
This should still be landed, as far as I can tell.
Though at this point I'd prefer it be modified to use nsIView::GetOffsetTo.
(In reply to comment #10)
> Is there a reason this patch hasn't been checked in?

Well, I started looking at bug 253076, and then I looked a bit at this "mouse
capturer thing" and the translations for that... thinking that that does not
belong in frame code but in the view/event manager perhaps and that someone
should look broader at this event origin problem...
... and only then I forgot about the whole thing ;-)
Attachment #154304 - Attachment is obsolete: true
Attachment #168086 - Flags: superreview?(roc)
Attachment #168086 - Flags: review?(bzbarsky)
Comment on attachment 168086 [details] [diff] [review]
Patch rev. 2 (using nsIView::GetOffsetTo)

r+sr=bzbarsky, though the closestView != resultFrameView check is redundant,
imo, and the null-check on resultFrameView is also somewhat redundant (can it
ever be null?  I don't believe so).
Attachment #168086 - Flags: superreview?(roc)
Attachment #168086 - Flags: superreview+
Attachment #168086 - Flags: review?(bzbarsky)
Attachment #168086 - Flags: review+
Isn't this ready to be landed?
It was checked in before your comment ;-)  I waiting for Tinderbox...
Checked in 2005-01-16 10:10 PDT

-> FIXED
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: