| 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 1745 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1756 DispatchMouseEvent(&mouseev); | 1756 DispatchMouseEvent(&mouseev); |
| 1757 break; | 1757 break; |
| 1758 } | 1758 } |
| 1759 case ui::ET_SCROLL_FLING_START: | 1759 case ui::ET_SCROLL_FLING_START: |
| 1760 case ui::ET_SCROLL_FLING_CANCEL: | 1760 case ui::ET_SCROLL_FLING_CANCEL: |
| 1761 case ui::ET_SCROLL: { | 1761 case ui::ET_SCROLL: { |
| 1762 ui::ScrollEvent scrollev(xev); | 1762 ui::ScrollEvent scrollev(xev); |
| 1763 SendEventToProcessor(&scrollev); | 1763 SendEventToProcessor(&scrollev); |
| 1764 break; | 1764 break; |
| 1765 } | 1765 } |
| 1766 case ui::ET_KEY_PRESSED: | |
| 1767 case ui::ET_KEY_RELEASED: { | |
| 1768 ui::KeyEvent key_event(xev); | |
| 1769 SendEventToProcessor(&key_event); | |
| 1770 break; | |
| 1771 } | |
| 1772 case ui::ET_UNKNOWN: | 1766 case ui::ET_UNKNOWN: |
| 1773 break; | 1767 break; |
| 1774 default: | 1768 default: |
| 1775 NOTREACHED(); | 1769 NOTREACHED(); |
| 1776 } | 1770 } |
| 1777 | 1771 |
| 1778 // If we coalesced an event we need to free its cookie. | 1772 // If we coalesced an event we need to free its cookie. |
| 1779 if (num_coalesced > 0) | 1773 if (num_coalesced > 0) |
| 1780 XFreeEventData(xev->xgeneric.display, &last_event.xcookie); | 1774 XFreeEventData(xev->xgeneric.display, &last_event.xcookie); |
| 1781 break; | 1775 break; |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1900 if (linux_ui) { | 1894 if (linux_ui) { |
| 1901 ui::NativeTheme* native_theme = linux_ui->GetNativeTheme(window); | 1895 ui::NativeTheme* native_theme = linux_ui->GetNativeTheme(window); |
| 1902 if (native_theme) | 1896 if (native_theme) |
| 1903 return native_theme; | 1897 return native_theme; |
| 1904 } | 1898 } |
| 1905 | 1899 |
| 1906 return ui::NativeTheme::instance(); | 1900 return ui::NativeTheme::instance(); |
| 1907 } | 1901 } |
| 1908 | 1902 |
| 1909 } // namespace views | 1903 } // namespace views |
| OLD | NEW |