From f574e6727a27ac819480246a8541b2acc1394ae7 Mon Sep 17 00:00:00 2001 From: "tfarina@chromium.org" Date: Fri, 10 Dec 2010 23:53:36 +0000 Subject: views: Include base/win/scope_comptr.h instead of base/scoped_comptr_win.h Also add base::win:: to ScopedComPtr where necessary. BUG=None TEST=trybots Review URL: http://codereview.chromium.org/5625006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@68910 0039d316-1c4b-4281-b951-d872f2087c98 --- views/controls/button/native_button_win.cc | 4 ++-- views/controls/textfield/native_textfield_win.cc | 10 +++++----- views/controls/textfield/native_textfield_win.h | 4 ++-- views/widget/widget_win.cc | 2 +- views/widget/widget_win.h | 4 ++-- views/window/window_win.cc | 6 +++--- 6 files changed, 15 insertions(+), 15 deletions(-) (limited to 'views') diff --git a/views/controls/button/native_button_win.cc b/views/controls/button/native_button_win.cc index 5aac782..71434e0 100644 --- a/views/controls/button/native_button_win.cc +++ b/views/controls/button/native_button_win.cc @@ -8,7 +8,7 @@ #include #include "base/logging.h" -#include "base/scoped_comptr_win.h" +#include "base/win/scoped_comptr.h" #include "base/win_util.h" #include "base/win/windows_version.h" #include "views/controls/button/checkbox.h" @@ -73,7 +73,7 @@ void NativeButtonWin::UpdateDefault() { void NativeButtonWin::UpdateAccessibleName() { std::wstring name; if (native_button_->GetAccessibleName(&name)) { - ScopedComPtr pAccPropServices; + base::win::ScopedComPtr pAccPropServices; HRESULT hr = CoCreateInstance(CLSID_AccPropServices, NULL, CLSCTX_SERVER, IID_IAccPropServices, reinterpret_cast(&pAccPropServices)); if (SUCCEEDED(hr)) { diff --git a/views/controls/textfield/native_textfield_win.cc b/views/controls/textfield/native_textfield_win.cc index 3f4b0eb..d559592 100644 --- a/views/controls/textfield/native_textfield_win.cc +++ b/views/controls/textfield/native_textfield_win.cc @@ -116,7 +116,7 @@ NativeTextfieldWin::NativeTextfieldWin(Textfield* textfield) } // Set up the text_object_model_. - ScopedComPtr ole_interface; + base::win::ScopedComPtr ole_interface; ole_interface.Attach(GetOleInterface()); if (ole_interface) text_object_model_.QueryFrom(ole_interface); @@ -358,7 +358,7 @@ void NativeTextfieldWin::InitializeAccessibilityInfo() { // Set the accessible state. accessibility_state_ = 0; - ScopedComPtr pAccPropServices; + base::win::ScopedComPtr pAccPropServices; HRESULT hr = CoCreateInstance(CLSID_AccPropServices, NULL, CLSCTX_SERVER, IID_IAccPropServices, reinterpret_cast(&pAccPropServices)); if (!SUCCEEDED(hr)) @@ -390,7 +390,7 @@ void NativeTextfieldWin::InitializeAccessibilityInfo() { void NativeTextfieldWin::UpdateAccessibleState(uint32 state_flag, bool set_value) { - ScopedComPtr pAccPropServices; + base::win::ScopedComPtr pAccPropServices; HRESULT hr = CoCreateInstance(CLSID_AccPropServices, NULL, CLSCTX_SERVER, IID_IAccPropServices, reinterpret_cast(&pAccPropServices)); if (!SUCCEEDED(hr)) @@ -408,7 +408,7 @@ void NativeTextfieldWin::UpdateAccessibleState(uint32 state_flag, } void NativeTextfieldWin::UpdateAccessibleValue(const std::wstring& value) { - ScopedComPtr pAccPropServices; + base::win::ScopedComPtr pAccPropServices; HRESULT hr = CoCreateInstance(CLSID_AccPropServices, NULL, CLSCTX_SERVER, IID_IAccPropServices, reinterpret_cast(&pAccPropServices)); if (!SUCCEEDED(hr)) @@ -1046,7 +1046,7 @@ void NativeTextfieldWin::SetContainsMouse(bool contains_mouse) { ITextDocument* NativeTextfieldWin::GetTextObjectModel() const { if (!text_object_model_) { - ScopedComPtr ole_interface; + base::win::ScopedComPtr ole_interface; ole_interface.Attach(GetOleInterface()); if (ole_interface) text_object_model_.QueryFrom(ole_interface); diff --git a/views/controls/textfield/native_textfield_win.h b/views/controls/textfield/native_textfield_win.h index b01b87e..5dc882f 100644 --- a/views/controls/textfield/native_textfield_win.h +++ b/views/controls/textfield/native_textfield_win.h @@ -16,7 +16,7 @@ #include #include "app/menus/simple_menu_model.h" -#include "base/scoped_comptr_win.h" +#include "base/win/scoped_comptr.h" #include "gfx/insets.h" #include "views/controls/textfield/native_textfield_wrapper.h" @@ -236,7 +236,7 @@ class NativeTextfieldWin gfx::Insets content_insets_; // This interface is useful for accessing the CRichEditCtrl at a low level. - mutable ScopedComPtr text_object_model_; + mutable base::win::ScopedComPtr text_object_model_; // The position and the length of the ongoing composition string. // These values are used for removing a composition string from a search diff --git a/views/widget/widget_win.cc b/views/widget/widget_win.cc index 9b30754..b94efa3 100644 --- a/views/widget/widget_win.cc +++ b/views/widget/widget_win.cc @@ -622,7 +622,7 @@ LRESULT WidgetWin::OnGetObject(UINT uMsg, WPARAM w_param, LPARAM l_param) { // Accessibility readers will send an OBJID_CLIENT message if (OBJID_CLIENT == l_param) { // Retrieve MSAA dispatch object for the root view. - ScopedComPtr root( + base::win::ScopedComPtr root( ViewAccessibility::GetAccessibleForView(GetRootView())); // Create a reference that MSAA will marshall to the client. diff --git a/views/widget/widget_win.h b/views/widget/widget_win.h index 8b85e47..0c9f1b0 100644 --- a/views/widget/widget_win.h +++ b/views/widget/widget_win.h @@ -15,8 +15,8 @@ #include #include "base/message_loop.h" -#include "base/scoped_comptr_win.h" #include "base/scoped_vector.h" +#include "base/win/scoped_comptr.h" #include "gfx/window_impl.h" #include "views/focus/focus_manager.h" #include "views/layout_manager.h" @@ -570,7 +570,7 @@ class WidgetWin : public gfx::WindowImpl, bool restore_focus_when_enabled_; // Instance of accessibility information and handling for MSAA root - ScopedComPtr accessibility_root_; + base::win::ScopedComPtr accessibility_root_; scoped_ptr default_theme_provider_; diff --git a/views/window/window_win.cc b/views/window/window_win.cc index e940fdd..5cf09bb 100644 --- a/views/window/window_win.cc +++ b/views/window/window_win.cc @@ -1416,7 +1416,7 @@ void WindowWin::ResetWindowRegion(bool force) { } void WindowWin::UpdateAccessibleName(std::wstring& accessible_name) { - ScopedComPtr pAccPropServices; + base::win::ScopedComPtr pAccPropServices; HRESULT hr = CoCreateInstance(CLSID_AccPropServices, NULL, CLSCTX_SERVER, IID_IAccPropServices, reinterpret_cast(&pAccPropServices)); if (SUCCEEDED(hr)) { @@ -1429,7 +1429,7 @@ void WindowWin::UpdateAccessibleName(std::wstring& accessible_name) { } void WindowWin::UpdateAccessibleRole() { - ScopedComPtr pAccPropServices; + base::win::ScopedComPtr pAccPropServices; HRESULT hr = CoCreateInstance(CLSID_AccPropServices, NULL, CLSCTX_SERVER, IID_IAccPropServices, reinterpret_cast(&pAccPropServices)); if (SUCCEEDED(hr)) { @@ -1445,7 +1445,7 @@ void WindowWin::UpdateAccessibleRole() { } void WindowWin::UpdateAccessibleState() { - ScopedComPtr pAccPropServices; + base::win::ScopedComPtr pAccPropServices; HRESULT hr = CoCreateInstance(CLSID_AccPropServices, NULL, CLSCTX_SERVER, IID_IAccPropServices, reinterpret_cast(&pAccPropServices)); if (SUCCEEDED(hr)) { -- cgit v1.1