| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "ui/views/widget/desktop_aura/desktop_window_tree_host_x11.h" | 5 #include "ui/views/widget/desktop_aura/desktop_window_tree_host_x11.h" |
| 6 | 6 |
| 7 #include <X11/extensions/shape.h> | 7 #include <X11/extensions/shape.h> |
| 8 #include <X11/extensions/XInput2.h> | 8 #include <X11/extensions/XInput2.h> |
| 9 #include <X11/Xatom.h> | 9 #include <X11/Xatom.h> |
| 10 #include <X11/Xregion.h> | 10 #include <X11/Xregion.h> |
| (...skipping 544 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 555 return g_current_capture == this; | 555 return g_current_capture == this; |
| 556 } | 556 } |
| 557 | 557 |
| 558 void DesktopWindowTreeHostX11::SetAlwaysOnTop(bool always_on_top) { | 558 void DesktopWindowTreeHostX11::SetAlwaysOnTop(bool always_on_top) { |
| 559 is_always_on_top_ = always_on_top; | 559 is_always_on_top_ = always_on_top; |
| 560 SetWMSpecState(always_on_top, | 560 SetWMSpecState(always_on_top, |
| 561 atom_cache_.GetAtom("_NET_WM_STATE_ABOVE"), | 561 atom_cache_.GetAtom("_NET_WM_STATE_ABOVE"), |
| 562 None); | 562 None); |
| 563 } | 563 } |
| 564 | 564 |
| 565 void DesktopWindowTreeHostX11::SetInterceptAllKeys(bool want_all_keys) { |
| 566 // TODO(sriramsr): Need to implement for Linux. |
| 567 } |
| 568 |
| 565 bool DesktopWindowTreeHostX11::IsAlwaysOnTop() const { | 569 bool DesktopWindowTreeHostX11::IsAlwaysOnTop() const { |
| 566 return is_always_on_top_; | 570 return is_always_on_top_; |
| 567 } | 571 } |
| 568 | 572 |
| 569 void DesktopWindowTreeHostX11::SetVisibleOnAllWorkspaces(bool always_visible) { | 573 void DesktopWindowTreeHostX11::SetVisibleOnAllWorkspaces(bool always_visible) { |
| 570 SetWMSpecState(always_visible, | 574 SetWMSpecState(always_visible, |
| 571 atom_cache_.GetAtom("_NET_WM_STATE_STICKY"), | 575 atom_cache_.GetAtom("_NET_WM_STATE_STICKY"), |
| 572 None); | 576 None); |
| 573 | 577 |
| 574 int new_desktop = 0; | 578 int new_desktop = 0; |
| (...skipping 1233 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1808 if (linux_ui) { | 1812 if (linux_ui) { |
| 1809 ui::NativeTheme* native_theme = linux_ui->GetNativeTheme(window); | 1813 ui::NativeTheme* native_theme = linux_ui->GetNativeTheme(window); |
| 1810 if (native_theme) | 1814 if (native_theme) |
| 1811 return native_theme; | 1815 return native_theme; |
| 1812 } | 1816 } |
| 1813 | 1817 |
| 1814 return ui::NativeTheme::instance(); | 1818 return ui::NativeTheme::instance(); |
| 1815 } | 1819 } |
| 1816 | 1820 |
| 1817 } // namespace views | 1821 } // namespace views |
| OLD | NEW |