| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "views/widget/monitor_win.h" | 5 #include "ui/views/widget/monitor_win.h" |
| 6 | 6 |
| 7 #include <shellapi.h> | 7 #include <shellapi.h> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "ui/gfx/rect.h" | 10 #include "ui/gfx/rect.h" |
| 11 | 11 |
| 12 namespace views { | 12 namespace views { |
| 13 | 13 |
| 14 gfx::Rect GetMonitorBoundsForRect(const gfx::Rect& rect) { | 14 gfx::Rect GetMonitorBoundsForRect(const gfx::Rect& rect) { |
| 15 RECT p_rect = rect.ToRECT(); | 15 RECT p_rect = rect.ToRECT(); |
| (...skipping 12 matching lines...) Expand all Loading... |
| 28 APPBARDATA taskbar_data = { sizeof APPBARDATA, NULL, 0, edge }; | 28 APPBARDATA taskbar_data = { sizeof APPBARDATA, NULL, 0, edge }; |
| 29 HWND taskbar = reinterpret_cast<HWND>(SHAppBarMessage(ABM_GETAUTOHIDEBAR, | 29 HWND taskbar = reinterpret_cast<HWND>(SHAppBarMessage(ABM_GETAUTOHIDEBAR, |
| 30 &taskbar_data)); | 30 &taskbar_data)); |
| 31 return (::IsWindow(taskbar) && (monitor != NULL) && | 31 return (::IsWindow(taskbar) && (monitor != NULL) && |
| 32 (MonitorFromWindow(taskbar, MONITOR_DEFAULTTONULL) == monitor) && | 32 (MonitorFromWindow(taskbar, MONITOR_DEFAULTTONULL) == monitor) && |
| 33 (GetWindowLong(taskbar, GWL_EXSTYLE) & WS_EX_TOPMOST)) ? | 33 (GetWindowLong(taskbar, GWL_EXSTYLE) & WS_EX_TOPMOST)) ? |
| 34 taskbar : NULL; | 34 taskbar : NULL; |
| 35 } | 35 } |
| 36 | 36 |
| 37 } // namespace views | 37 } // namespace views |
| OLD | NEW |