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

Unified Diff: chrome/browser/ui/views/tabs/window_finder_win.cc

Issue 2894483002: Migrate from ScopedComPtr::CreateInstance() to CoCreateInstance in chrome/... (Closed)
Patch Set: Fix Header Include Location Created 3 years, 7 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: chrome/browser/ui/views/tabs/window_finder_win.cc
diff --git a/chrome/browser/ui/views/tabs/window_finder_win.cc b/chrome/browser/ui/views/tabs/window_finder_win.cc
index 7f1d144690b67af6e1f47b9cbc1eea5f1ba2c138..a79c6521b9826a43807c8ed3598f12cecb2e30e0 100644
--- a/chrome/browser/ui/views/tabs/window_finder_win.cc
+++ b/chrome/browser/ui/views/tabs/window_finder_win.cc
@@ -4,6 +4,7 @@
#include "chrome/browser/ui/views/tabs/window_finder.h"
+#include <objbase.h>
#include <shobjidl.h>
#include "base/macros.h"
@@ -200,8 +201,9 @@ class LocalProcessWindowFinder : public BaseWindowFinder {
: BaseWindowFinder(ignore),
result_(NULL) {
if (base::win::GetVersion() >= base::win::VERSION_WIN10) {
- CHECK(SUCCEEDED(virtual_desktop_manager_.CreateInstance(
- __uuidof(VirtualDesktopManager))));
+ CHECK(SUCCEEDED(::CoCreateInstance(
+ __uuidof(VirtualDesktopManager), nullptr, CLSCTX_ALL,
+ IID_PPV_ARGS(&virtual_desktop_manager_))));
}
screen_loc_ = display::win::ScreenWin::DIPToScreenPoint(screen_loc);
EnumThreadWindows(GetCurrentThreadId(), WindowCallbackProc, as_lparam());
« no previous file with comments | « chrome/browser/ui/views/status_icons/status_tray_state_changer_win.cc ('k') | chrome/browser/win/jumplist_updater.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698