Index: chrome/browser/renderer_host/render_widget_host_view_win.cc |
=================================================================== |
--- chrome/browser/renderer_host/render_widget_host_view_win.cc (revision 66785) |
+++ chrome/browser/renderer_host/render_widget_host_view_win.cc (working copy) |
@@ -7,7 +7,6 @@ |
#include "app/l10n_util.h" |
#include "app/l10n_util_win.h" |
#include "app/resource_bundle.h" |
-#include "app/view_prop.h" |
#include "app/win/scoped_prop.h" |
#include "base/command_line.h" |
#include "base/i18n/rtl.h" |
@@ -52,7 +51,6 @@ |
#include "webkit/glue/webaccessibility.h" |
#include "webkit/glue/webcursor.h" |
-using app::ViewProp; |
using base::TimeDelta; |
using base::TimeTicks; |
using WebKit::WebInputEvent; |
@@ -73,7 +71,7 @@ |
// listening for MSAA events. |
const int kIdCustom = 1; |
-const char* const kRenderWidgetHostViewKey = "__RENDER_WIDGET_HOST_VIEW__"; |
+const wchar_t* kRenderWidgetHostViewKey = L"__RENDER_WIDGET_HOST_VIEW__"; |
// A callback function for EnumThreadWindows to enumerate and dismiss |
// any owned popop windows |
@@ -310,10 +308,9 @@ |
// Add a property indicating that a particular renderer is associated with |
// this window. Used by the GPU process to validate window handles it |
- // receives from renderer processes. As this is used by a separate process we |
- // have to use ScopedProp here instead of ViewProp. |
+ // receives from renderer processes. |
int renderer_id = render_widget_host_->process()->id(); |
- renderer_id_prop_.reset( |
+ props_.push_back( |
new app::win::ScopedProp(m_hWnd, |
chrome::kChromiumRendererIdProperty, |
reinterpret_cast<HANDLE>(renderer_id))); |
@@ -801,11 +798,12 @@ |
props_.push_back(views::SetWindowSupportsRerouteMouseWheel(m_hWnd)); |
// Save away our HWND in the parent window as a property so that the |
// accessibility code can find it. |
- props_.push_back(new ViewProp(GetParent(), |
- kViewsNativeHostPropForAccessibility, |
- m_hWnd)); |
- props_.push_back(new ViewProp(m_hWnd, kRenderWidgetHostViewKey, |
- static_cast<RenderWidgetHostView*>(this))); |
+ props_.push_back(new app::win::ScopedProp( |
+ GetParent(), kViewsNativeHostPropForAccessibility, |
+ m_hWnd)); |
+ props_.push_back(new app::win::ScopedProp( |
+ m_hWnd, kRenderWidgetHostViewKey, |
+ static_cast<RenderWidgetHostView*>(this))); |
return 0; |
} |
@@ -836,7 +834,6 @@ |
// sequence as part of the usual cleanup when the plugin instance goes away. |
EnumChildWindows(m_hWnd, DetachPluginWindowsCallback, NULL); |
- renderer_id_prop_.reset(); |
props_.reset(); |
ResetTooltip(); |
@@ -1638,7 +1635,11 @@ |
RenderWidgetHostView* |
RenderWidgetHostView::GetRenderWidgetHostViewFromNativeView( |
gfx::NativeView native_view) { |
- return ::IsWindow(native_view) ? |
- reinterpret_cast<RenderWidgetHostView*>( |
- ViewProp::GetValue(native_view, kRenderWidgetHostViewKey)) : NULL; |
+ if (::IsWindow(native_view)) { |
+ HANDLE raw_render_host_view = ::GetProp(native_view, |
+ kRenderWidgetHostViewKey); |
+ if (raw_render_host_view) |
+ return reinterpret_cast<RenderWidgetHostView*>(raw_render_host_view); |
+ } |
+ return NULL; |
} |
Property changes on: chrome\browser\renderer_host\render_widget_host_view_win.cc |
___________________________________________________________________ |
Deleted: svn:mergeinfo |