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

Side by Side Diff: chrome/browser/ui/views/tabs/window_finder_win.cc

Issue 184903003: Window ownership -> WindowTreeHost (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 9 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/views/tabs/window_finder.h" 5 #include "chrome/browser/ui/views/tabs/window_finder.h"
6 6
7 #include "base/win/scoped_gdi_object.h" 7 #include "base/win/scoped_gdi_object.h"
8 #include "base/win/windows_version.h" 8 #include "base/win/windows_version.h"
9 #include "ui/aura/window.h" 9 #include "ui/aura/window.h"
10 #include "ui/gfx/screen.h" 10 #include "ui/gfx/screen.h"
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after
200 // ShouldStopIterating if an appropriate window is found. 200 // ShouldStopIterating if an appropriate window is found.
201 HWND result_; 201 HWND result_;
202 202
203 DISALLOW_COPY_AND_ASSIGN(LocalProcessWindowFinder); 203 DISALLOW_COPY_AND_ASSIGN(LocalProcessWindowFinder);
204 }; 204 };
205 205
206 std::set<HWND> RemapIgnoreSet(const std::set<gfx::NativeView>& ignore) { 206 std::set<HWND> RemapIgnoreSet(const std::set<gfx::NativeView>& ignore) {
207 std::set<HWND> hwnd_set; 207 std::set<HWND> hwnd_set;
208 std::set<gfx::NativeView>::const_iterator it = ignore.begin(); 208 std::set<gfx::NativeView>::const_iterator it = ignore.begin();
209 for (; it != ignore.end(); ++it) { 209 for (; it != ignore.end(); ++it) {
210 HWND w = (*it)->GetDispatcher()->host()->GetAcceleratedWidget(); 210 HWND w = (*it)->GetHost()->GetAcceleratedWidget();
211 if (w) 211 if (w)
212 hwnd_set.insert(w); 212 hwnd_set.insert(w);
213 } 213 }
214 return hwnd_set; 214 return hwnd_set;
215 } 215 }
216 216
217 } // namespace 217 } // namespace
218 218
219 aura::Window* GetLocalProcessWindowAtPoint( 219 aura::Window* GetLocalProcessWindowAtPoint(
220 chrome::HostDesktopType host_desktop_type, 220 chrome::HostDesktopType host_desktop_type,
221 const gfx::Point& screen_point, 221 const gfx::Point& screen_point,
222 const std::set<aura::Window*>& ignore) { 222 const std::set<aura::Window*>& ignore) {
223 #if defined(USE_ASH) 223 #if defined(USE_ASH)
224 if (host_desktop_type == chrome::HOST_DESKTOP_TYPE_ASH) 224 if (host_desktop_type == chrome::HOST_DESKTOP_TYPE_ASH)
225 return GetLocalProcessWindowAtPointAsh(screen_point, ignore); 225 return GetLocalProcessWindowAtPointAsh(screen_point, ignore);
226 #endif 226 #endif
227 return LocalProcessWindowFinder::GetProcessWindowAtPoint( 227 return LocalProcessWindowFinder::GetProcessWindowAtPoint(
228 screen_point, RemapIgnoreSet(ignore)); 228 screen_point, RemapIgnoreSet(ignore));
229 } 229 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698