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_root_window_host_x11.h" | 5 #include "ui/views/widget/desktop_aura/desktop_root_window_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 505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
516 is_always_on_top_ = always_on_top; | 516 is_always_on_top_ = always_on_top; |
517 SetWMSpecState(always_on_top, | 517 SetWMSpecState(always_on_top, |
518 atom_cache_.GetAtom("_NET_WM_STATE_ABOVE"), | 518 atom_cache_.GetAtom("_NET_WM_STATE_ABOVE"), |
519 None); | 519 None); |
520 } | 520 } |
521 | 521 |
522 bool DesktopRootWindowHostX11::IsAlwaysOnTop() const { | 522 bool DesktopRootWindowHostX11::IsAlwaysOnTop() const { |
523 return is_always_on_top_; | 523 return is_always_on_top_; |
524 } | 524 } |
525 | 525 |
526 bool DesktopRootWindowHostX11::SetWindowTitle(const string16& title) { | 526 bool DesktopRootWindowHostX11::SetWindowTitle(const base::string16& title) { |
527 if (window_title_ == title) | 527 if (window_title_ == title) |
528 return false; | 528 return false; |
529 window_title_ = title; | 529 window_title_ = title; |
530 std::string utf8str = UTF16ToUTF8(title); | 530 std::string utf8str = UTF16ToUTF8(title); |
531 XChangeProperty(xdisplay_, | 531 XChangeProperty(xdisplay_, |
532 xwindow_, | 532 xwindow_, |
533 atom_cache_.GetAtom("_NET_WM_NAME"), | 533 atom_cache_.GetAtom("_NET_WM_NAME"), |
534 atom_cache_.GetAtom("UTF8_STRING"), | 534 atom_cache_.GetAtom("UTF8_STRING"), |
535 8, | 535 8, |
536 PropModeReplace, | 536 PropModeReplace, |
(...skipping 1002 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1539 if (linux_ui) { | 1539 if (linux_ui) { |
1540 ui::NativeTheme* native_theme = linux_ui->GetNativeTheme(); | 1540 ui::NativeTheme* native_theme = linux_ui->GetNativeTheme(); |
1541 if (native_theme) | 1541 if (native_theme) |
1542 return native_theme; | 1542 return native_theme; |
1543 } | 1543 } |
1544 | 1544 |
1545 return ui::NativeTheme::instance(); | 1545 return ui::NativeTheme::instance(); |
1546 } | 1546 } |
1547 | 1547 |
1548 } // namespace views | 1548 } // namespace views |
OLD | NEW |