OLD | NEW |
---|---|
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #if defined(USE_AURA) && !defined(OS_MACOSX) | |
8 #include "content/public/common/service_manager_connection.h" | |
9 #include "services/service_manager/runner/common/client_util.h" | |
10 | |
11 gfx::NativeWindow GetLocalProcessWindowAtPointMus( | |
12 const gfx::Point& screen_point, | |
13 const std::set<gfx::NativeWindow>& ignore); | |
14 #endif | |
15 | |
7 WindowFinder::WindowFinder() {} | 16 WindowFinder::WindowFinder() {} |
17 | |
8 WindowFinder::~WindowFinder() {} | 18 WindowFinder::~WindowFinder() {} |
19 | |
20 gfx::NativeWindow WindowFinder::GetLocalProcessWindowAtPoint( | |
21 const gfx::Point& screen_point, | |
22 const std::set<gfx::NativeWindow>& ignore) { | |
23 #if defined(USE_AURA) && !defined(OS_MACOSX) | |
sky
2016/10/26 22:01:28
I dislike the amount of ifdefs needed as a result
| |
24 content::ServiceManagerConnection* service_manager_connection = | |
25 content::ServiceManagerConnection::GetForProcess(); | |
26 if (service_manager_connection && service_manager::ServiceManagerIsRemote()) | |
27 return GetLocalProcessWindowAtPointMus(screen_point, ignore); | |
28 #endif | |
29 | |
30 return GetLocalProcessWindowAtPointImpl(screen_point, ignore); | |
31 } | |
OLD | NEW |