Create a visible window with class name Chrome_RenderWidgetHostHWND which corresponds...
commitd5169a9544854ff5cb35470c328a8e7f44ff5ef1
authorananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Fri, 7 Feb 2014 00:00:30 +0000 (7 00:00 +0000)
committerananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Fri, 7 Feb 2014 00:00:30 +0000 (7 00:00 +0000)
tree2651deffb1a19b49f9deb969670710ebeb0a0f4d
parent48d031a2cd1a1d4d15b3277a9cc18c38779ccf28
Create a visible window with class name Chrome_RenderWidgetHostHWND which corresponds to the bounds of the web contents.

This is done to ensure that legacy drivers for trackpoints/trackpads and others which use track gestures for back forward
navigations work. These drivers call the WindowFromPoint API and get the process name. For Chrome they look for the old
Window class Chrome_RenderWidgetHostHWND. They use this to determine whether to send mouse wheels and special keyboard
message for back forward navigations, etc.

With Aura we don't have this window class anymore causing Chrome to not work well for a number of users.

To workaround this in the shortterm, a dummy HWND with the Chrome_RenderWidgetHostHWND class name is created. This window
is visible and handles mouse events. It is transparent to ensure that it does not need to draw. To ensure that we don't
mess wit mouse events too much we set capture to the parent window as needed. This window also serves as the parent to
windowless NPAPI plugins like Flash. Additionally the dummy accessibility window with this class name has been removed
and the functionality has been consolidated into the newly added LegacyRenderWidgetHostHWND class which provides this
functionality.

BUG=326022,335941
R=cpu@chromium.org, scottmg@chromium.org, sky@chromium.org, cpu, scottmg
TBR=jam

Review URL: https://codereview.chromium.org/151083002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@249537 0039d316-1c4b-4281-b951-d872f2087c98
12 files changed:
content/browser/accessibility/browser_accessibility_manager_win.cc
content/browser/accessibility/browser_accessibility_manager_win.h
content/browser/accessibility/browser_accessibility_win_unittest.cc
content/browser/renderer_host/legacy_render_widget_host_win.cc [new file with mode: 0644]
content/browser/renderer_host/legacy_render_widget_host_win.h [new file with mode: 0644]
content/browser/renderer_host/render_widget_host_impl.cc
content/browser/renderer_host/render_widget_host_impl.h
content/browser/renderer_host/render_widget_host_view_aura.cc
content/browser/renderer_host/render_widget_host_view_aura.h
content/content_browser.gypi
content/public/common/content_switches.cc
content/public/common/content_switches.h