Bug 22263

Summary: Web Inspector: mouse drifts away from resizer when resizing docked inspector
Product: WebKit Reporter: Adam Roben (:aroben) <aroben>
Component: Web InspectorAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: beidson, burg, commit-queue, graouts, joepeck, mattbaker, timothy, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Patch
none
Patch none

Description Adam Roben (:aroben) 2008-11-14 07:49:29 PST
To reproduce:

1. Go to any web page (e.g., <http://webkit.org/>)
2. Show the Inspector
3. Dock the Inspector into the WebView
4. Click and hold on the top edge of the Inspector to start resizing it
5. Drag the mouse down below the bottom of the Safari window
6. Start dragging the mouse up again

As soon as you begin (6), the Inspector starts growing vertically, even though the mouse is quite far from the resizer. The Inspector should instead wait until the mouse is back on top of the resizer to begin growing.
Comment 1 Adam Roben (:aroben) 2008-11-14 07:49:51 PST
<rdar://problem/6371885>
Comment 2 Timothy Hatcher 2013-04-01 16:58:57 PDT
*** Bug 35264 has been marked as a duplicate of this bug. ***
Comment 3 BJ Burg 2014-01-12 15:42:33 PST
Still reproducible! :)
Comment 4 Matt Baker 2014-09-15 11:10:06 PDT
An additional quirk when VERY quickly resizing the docked Inspector:

1. Show the Inspector docked to the bottom of the WebView.
2. Click and hold the top edge of the Inspector to start resizing it.
3. As fast as possible, flick the mouse off the bottom of the Safari window.
4. Let go once the cursor is below the bottom of the window.

Rather than being set to the minimum docked height, the height of the docked Inspector window is a large value (sometimes larger than the starting height).

This occurs whether docked at the bottom or right of the WebView.
Comment 5 Matt Baker 2014-09-15 12:19:40 PDT
Created attachment 238135 [details]
Patch
Comment 6 Joseph Pecoraro 2014-09-15 13:43:28 PDT
Comment on attachment 238135 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=238135&action=review

r=me!

> Source/WebInspectorUI/UserInterface/Base/Main.js:1302
> +        // Cursor position cannot be less than initial mouse down position when resizing docked Inspector smaller.

Maybe we should clarify these comments. "initial mouse down position" => "initial mouse down position within the window". Since that is what clientX/Y are giving us.
Comment 7 Matt Baker 2014-09-15 16:39:35 PDT
Created attachment 238147 [details]
Patch
Comment 8 WebKit Commit Bot 2014-09-15 17:41:45 PDT
Comment on attachment 238147 [details]
Patch

Clearing flags on attachment: 238147

Committed r173640: <http://trac.webkit.org/changeset/173640>
Comment 9 WebKit Commit Bot 2014-09-15 17:41:48 PDT
All reviewed patches have been landed.  Closing bug.