Closed Bug 536481 Opened 16 years ago Closed 16 years ago

scrollbar moves with mouse when no mouse buttons pressed with change of focus

Categories

(Core :: XUL, defect)

x86
Windows 2000
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: tnikkel, Assigned: enndeakin)

References

Details

Attachments

(1 file, 2 obsolete files)

Click on scrollbar and hold. Move mouse far enough away from scrollbar so that the scrollbar doesn't respond to movements of the mouse anymore. Alt-tab to another application. Release mouse. Go back to Firefox window. Scrollbar still responds to mouse movements, when it should not because there are no mouse buttons down. Regression range is http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=90d3e6d2cbb9&tochange=4430cae50dad Based on that bug 178324 seems most likely.
It think it may be the case that the call to ClearMouseCapture in nsViewManager.cpp isn't called. Likely, a call to ClearMouseCapture is needed within nsFocusManager::WindowLowered instead. When testing this, I saw this bug on Firefox 3.5 as well, but only managed to reproduce it a couple of times, and not since.
Assignee: nobody → enndeakin
Status: NEW → ASSIGNED
Attachment #419009 - Flags: review?(Olli.Pettay)
Comment on attachment 419009 [details] [diff] [review] clear capture when window is lowered A testcase would be great.
Attachment #419009 - Flags: review?(Olli.Pettay) → review+
Attachment #419009 - Attachment is obsolete: true
Attachment #419573 - Flags: review?(Olli.Pettay)
I'm not sure about the nsSubDocumentFrame change. Changing type attribute doesn't necessarily mean hiding the iframe/browser. Would it work if presshell used some helper method to check that capturing content has a frame in a currently visible presshell, which is in the currently active window? And it not, release capturing content. For the WindowLowered case setting capturing content explicitly null is probably needed.
In reply to comment #5) > I'm not sure about the nsSubDocumentFrame change. > Changing type attribute doesn't necessarily mean hiding the iframe/browser. I added it here only to accompany the call to HidePopupsInDocShell which should be called in the same situation. Is there a better suitable place to call these when a tab/window is being hidden? > Would it work if presshell used some helper method to check that > capturing content has a frame in a currently visible presshell Do you mean check this in HandleEvent? What 'currently visible presshell' check were you thinking of here?
(In reply to comment #6) > Do you mean check this in HandleEvent? Right > What 'currently visible presshell' check were you thinking of here? Could checking viewmanager's rootview's visibility be enough, maybe iterating parent presshell's viewmanagers too.
Enn, are you going to update the patch?
(In reply to comment #7) > > What 'currently visible presshell' check were you thinking of here? > Could checking viewmanager's rootview's visibility be enough There's already a call to clear the capture if needed when a view is hidden in nsView::NotifyEffectiveVisibilityChanged
Ah. Well why do we need the a bit strange change to nsFrameFrame.cpp?
Attachment #419573 - Attachment is obsolete: true
Attachment #423588 - Flags: review?(Olli.Pettay)
Attachment #419573 - Flags: review?(Olli.Pettay)
Attachment #423588 - Flags: review?(Olli.Pettay) → review+
Blocks: 546533
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: