Bug 59837

Summary: Get rid of versions of sendContextMenuEvent and eventMayStartDrag that takes NSEvent
Product: WebKit Reporter: Ryosuke Niwa <rniwa>
Component: UI EventsAssignee: Ryosuke Niwa <rniwa>
Status: RESOLVED FIXED    
Severity: Enhancement CC: ap, commit-queue, darin, sam, simon.fraser
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Bug Depends on:    
Bug Blocks: 56410    
Attachments:
Description Flags
cleanup
none
Fixed test failures none

Description Ryosuke Niwa 2011-04-29 15:25:59 PDT
Mac WebKit port should be creating PlatformMouseEvent in WebKit code instead of pushing that code into EventHandler.
Comment 1 Ryosuke Niwa 2011-04-29 15:28:36 PDT
Created attachment 91749 [details]
cleanup
Comment 2 Ryosuke Niwa 2011-04-29 15:58:46 PDT
Created attachment 91758 [details]
Fixed test failures
Comment 3 Ryosuke Niwa 2011-04-29 15:59:33 PDT
Apparently PlatformMouseEvent(event, self) and PlatformMouseEvent(event, page->chrome()->platformPageClient()) are different in WebHTMLView.mm
Comment 4 Eric Seidel (no email) 2011-05-01 09:58:06 PDT
Comment on attachment 91758 [details]
Fixed test failures

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

SGTM.

> Source/WebKit/mac/WebView/WebHTMLView.mm:3456
> +                if (Page* page = coreFrame->page())
> +                    result = coreFrame->eventHandler()->eventMayStartDrag(PlatformMouseEvent(event, page->chrome()->platformPageClient()));

Will results still end up as false in the !page() case after this change?
Comment 5 Ryosuke Niwa 2011-05-01 11:55:04 PDT
Comment on attachment 91758 [details]
Fixed test failures

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

Thanks for the review!

>> Source/WebKit/mac/WebView/WebHTMLView.mm:3456
>> +                    result = coreFrame->eventHandler()->eventMayStartDrag(PlatformMouseEvent(event, page->chrome()->platformPageClient()));
> 
> Will results still end up as false in the !page() case after this change?

Yes, result is initialized to false.
Comment 6 WebKit Commit Bot 2011-05-01 12:46:12 PDT
Comment on attachment 91758 [details]
Fixed test failures

Clearing flags on attachment: 91758

Committed r85428: <http://trac.webkit.org/changeset/85428>
Comment 7 WebKit Commit Bot 2011-05-01 12:46:18 PDT
All reviewed patches have been landed.  Closing bug.