Bug 25926 - Clean up DragController
Summary: Clean up DragController
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Mac OS X 10.5
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-05-21 06:39 PDT by Eric Seidel (no email)
Modified: 2009-05-21 07:05 PDT (History)
1 user (show)

See Also:


Attachments
Clean up DragController (13.74 KB, patch)
2009-05-21 06:43 PDT, Eric Seidel (no email)
no flags Details | Formatted Diff | Diff
Clean up DragController (14.62 KB, patch)
2009-05-21 06:47 PDT, Eric Seidel (no email)
ap: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Seidel (no email) 2009-05-21 06:39:12 PDT
Clean up DragController

Looking at DragController this evening to fix a few bugs I was confused by m_document.  I'm no longer confused by it now that I've renamed it to m_documentUnderMouse.

I also saw copy/paste code involving clearing the selection when moving out of one document and into another.  I moved that code into a function called mouseMovedIntoDocument.

I also got rid of a couple needless null-checks after confirming via source inspection they were not ever possible.
Comment 1 Eric Seidel (no email) 2009-05-21 06:43:38 PDT
Created attachment 30542 [details]
Clean up DragController

 3 files changed, 82 insertions(+), 48 deletions(-)
Comment 2 Eric Seidel (no email) 2009-05-21 06:47:00 PDT
Created attachment 30543 [details]
Clean up DragController

 4 files changed, 86 insertions(+), 51 deletions(-)
Comment 3 Alexey Proskuryakov 2009-05-21 07:00:14 PDT
Comment on attachment 30543 [details]
Clean up DragController

r=me with some trivial comments over IRC.
Comment 4 Eric Seidel (no email) 2009-05-21 07:05:48 PDT
Committing to http://svn.webkit.org/repository/webkit/trunk ...
	M	WebCore/ChangeLog
	M	WebCore/page/DragController.cpp
	M	WebCore/page/DragController.h
	M	WebCore/page/mac/DragControllerMac.mm
Committed r43968

Hopefully future readers of DragController.cpp will find it easier to understand now. :)