Bug 69190 - [Chromium] Need a wrapper for UserGestureIndicator in WebKit
Summary: [Chromium] Need a wrapper for UserGestureIndicator in WebKit
Status: RESOLVED DUPLICATE of bug 77690
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-30 17:03 PDT by Bill Budge
Modified: 2012-02-10 10:45 PST (History)
2 users (show)

See Also:


Attachments
Proposed Patch (7.49 KB, patch)
2011-09-30 17:11 PDT, Bill Budge
no flags Details | Formatted Diff | Diff
Proposed Patch (8.40 KB, patch)
2011-10-02 08:12 PDT, Bill Budge
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Bill Budge 2011-09-30 17:03:01 PDT
We would like to extend user gestures for clients of asynchronous APIs to give them a chance to make requests before the user gesture is considered over. Create a new class in WebKit, WebUserGestureIndicator, that wraps WebCore::UserGestureIndicator.
Comment 1 Bill Budge 2011-09-30 17:11:45 PDT
Created attachment 109377 [details]
Proposed Patch

I still need to verify that this will be useful.
Comment 2 Darin Fisher (:fishd, Google) 2011-09-30 21:38:03 PDT
Comment on attachment 109377 [details]
Proposed Patch

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

can you say more about how you will use this?

> Source/WebKit/chromium/src/WebUserGestureIndicator.cpp:40
> +#define COMPILE_ASSERT_MATCHING_ENUM(webkit_name, webcore_name) \

nit: we usually just put these in AssertMatchingEnums.cpp so that we only have to define this helper macro once.  it also keeps the code here a bit cleaner.
Comment 3 Bill Budge 2011-10-01 15:01:51 PDT
Normally, the user gesture is processed while an input event is being reported through the callbacks. With our asynchronous APIs, a client's request won't be received until WebKit considers the user gesture to be over. We plan to use an ACK message to determine if the client made the request within the original user gesture. When such a request is then received, we use this wrapper to fake the user gesture so that WebKit will allow the request. It checks for a user gesture, for example, when there is a request for full screen on an element.

In short, this wrapper simply allows us to create a user gesture out of WebCore.
Comment 4 Bill Budge 2011-10-02 08:12:16 PDT
Created attachment 109421 [details]
Proposed Patch
Comment 5 Bill Budge 2012-02-05 09:44:22 PST

*** This bug has been marked as a duplicate of bug 77690 ***
Comment 6 Eric Seidel (no email) 2012-02-10 10:45:04 PST
Comment on attachment 109421 [details]
Proposed Patch

Cleared review? from attachment 109421 [details] so that this bug does not appear in http://webkit.org/pending-review.  If you would like this patch reviewed, please attach it to a new bug (or re-open this bug before marking it for review again).