DescriptionAdd support for custom cursors set by windowless plugins. Windowless plugins typically set the cursor in NPP_HandleEvent for WM_MOUSEMOVE.The current implementation looks for the cursor type and if the typedoes not match predefinedcursor types defaults to the pointer cursor.
The fixes are as below:-
1. Marshal the HCURSOR after copying it to ensure that it
remains valid. This works as a HCURSOR is a user object
and can be used across processes. Ideally we would
like to convert it to a skia bitmap but there are issues
with converting monochrome cursors.
2. Added support for marshaling platform specific data in
the webcursor Serialize/Deserialize functions. This is in
the form of functions like InitPlatformData,
SerializePlatformData, DeserializePlatformData, etc.
which are stubbed out for the other platforms.
3. Mimic webkit windowless plugin behavior where it sets a
flag to ignore the next setCursor after HandleEvent of
WM_MOUSEMOVE. If we don't do this the cursor keeps
changing between a pointerCursor and the cursor set by
the plugin which also causes flicker.
4. Fixed the WebCursor::IsEqual function to ensure that it
checks all fields for equality.
5. The browser(RenderWidgetHostViewWin) now maintains a
WebCursor instance representing the current cursor. Any
cursor updates received from the renderer update the
current cursor member maintained by the browser.
6. We intercept the SetCursor API for windowless plugins
like Flash and Silverlight and remember the cursor being
set. We don't invoke the original API as the browser UI
thread would do it anyways. This fixes the annoying
cursor flicker caused by the windowless flash plugin
instance constantly setting the cursor even when the tab
is not visible.
This fixes bug http://code.google.com/p/chromium/issues/detail?id=3800.
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=7798
Patch Set 1 #Patch Set 2 : '' #
Total comments: 3
Patch Set 3 : '' #Patch Set 4 : '' #Patch Set 5 : '' #Patch Set 6 : '' #
Total comments: 13
Patch Set 7 : '' #Patch Set 8 : '' #Patch Set 9 : '' #Patch Set 10 : '' #Patch Set 11 : '' #
Total comments: 3
Patch Set 12 : '' #Patch Set 13 : '' #Patch Set 14 : '' #Patch Set 15 : '' #Patch Set 16 : '' #Patch Set 17 : '' #Patch Set 18 : '' #Patch Set 19 : '' #
Total comments: 4
Patch Set 20 : '' #Patch Set 21 : '' #Patch Set 22 : '' #Patch Set 23 : '' #Patch Set 24 : '' #
Total comments: 5
Patch Set 25 : '' #Patch Set 26 : '' #Patch Set 27 : '' #Patch Set 28 : '' #Patch Set 29 : '' #
Total comments: 2
Patch Set 30 : '' #Messages
Total messages: 17 (0 generated)
|