Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1834)

Unified Diff: content/child/npapi/webplugin_delegate_impl_win.cc

Issue 137403005: Remove some code inside USE_AURA and OS_WIN ifdefs. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/child/npapi/webplugin_delegate_impl_win.cc
===================================================================
--- content/child/npapi/webplugin_delegate_impl_win.cc (revision 244508)
+++ content/child/npapi/webplugin_delegate_impl_win.cc (working copy)
@@ -88,10 +88,8 @@
base::LazyInstance<base::win::IATPatchFunction> g_iat_patch_get_proc_address =
LAZY_INSTANCE_INITIALIZER;
-#if defined(USE_AURA)
base::LazyInstance<base::win::IATPatchFunction> g_iat_patch_window_from_point =
LAZY_INSTANCE_INITIALIZER;
-#endif
// http://crbug.com/16114
// Enforces providing a valid device context in NPWindow, so that NPP_SetWindow
@@ -266,9 +264,7 @@
quirks_ |= PLUGIN_QUIRK_ALWAYS_NOTIFY_SUCCESS;
quirks_ |= PLUGIN_QUIRK_HANDLE_MOUSE_CAPTURE;
quirks_ |= PLUGIN_QUIRK_EMULATE_IME;
-#if defined(USE_AURA)
quirks_ |= PLUGIN_QUIRK_FAKE_WINDOW_FROM_POINT;
-#endif
} else if (filename == kAcrobatReaderPlugin) {
// Check for the version number above or equal 9.
int major_version = GetPluginMajorVersion(plugin_info);
@@ -422,14 +418,13 @@
GetProcAddressPatch);
}
-#if defined(USE_AURA)
if (windowless_ && !g_iat_patch_window_from_point.Pointer()->is_patched() &&
(quirks_ & PLUGIN_QUIRK_FAKE_WINDOW_FROM_POINT)) {
g_iat_patch_window_from_point.Pointer()->Patch(
GetPluginPath().value().c_str(), "user32.dll", "WindowFromPoint",
WebPluginDelegateImpl::WindowFromPointPatch);
}
-#endif
+
return true;
}
@@ -450,10 +445,8 @@
if (g_iat_patch_reg_enum_key_ex_w.Pointer()->is_patched())
g_iat_patch_reg_enum_key_ex_w.Pointer()->Unpatch();
-#if defined(USE_AURA)
if (g_iat_patch_window_from_point.Pointer()->is_patched())
g_iat_patch_window_from_point.Pointer()->Unpatch();
-#endif
if (mouse_hook_) {
UnhookWindowsHookEx(mouse_hook_);
@@ -1494,7 +1487,6 @@
return ::GetProcAddress(module, name);
}
-#if defined(USE_AURA)
HWND WINAPI WebPluginDelegateImpl::WindowFromPointPatch(POINT point) {
HWND window = WindowFromPoint(point);
if (::ScreenToClient(window, &point)) {
@@ -1505,7 +1497,6 @@
}
return window;
}
-#endif
void WebPluginDelegateImpl::HandleCaptureForMessage(HWND window,
UINT message) {

Powered by Google App Engine
This is Rietveld 408576698