Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(97)

Side by Side Diff: ui/views/widget/desktop_root_window_host_linux.cc

Issue 11275139: Move ui\aura\shared to ui\views\corewm (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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_root_window_host_linux.h" 5 #include "ui/views/widget/desktop_root_window_host_linux.h"
6 6
7 #include <X11/extensions/XInput2.h> 7 #include <X11/extensions/XInput2.h>
8 #include <X11/Xatom.h> 8 #include <X11/Xatom.h>
9 #include <X11/Xutil.h> 9 #include <X11/Xutil.h>
10 10
11 #include "base/message_pump_aurax11.h" 11 #include "base/message_pump_aurax11.h"
12 #include "base/stringprintf.h" 12 #include "base/stringprintf.h"
13 #include "base/utf_string_conversions.h" 13 #include "base/utf_string_conversions.h"
14 #include "ui/aura/client/default_capture_client.h" 14 #include "ui/aura/client/default_capture_client.h"
15 #include "ui/aura/client/screen_position_client.h" 15 #include "ui/aura/client/screen_position_client.h"
16 #include "ui/aura/client/user_action_client.h" 16 #include "ui/aura/client/user_action_client.h"
17 #include "ui/aura/desktop/desktop_activation_client.h" 17 #include "ui/aura/desktop/desktop_activation_client.h"
18 #include "ui/aura/desktop/desktop_cursor_client.h" 18 #include "ui/aura/desktop/desktop_cursor_client.h"
19 #include "ui/aura/desktop/desktop_dispatcher_client.h" 19 #include "ui/aura/desktop/desktop_dispatcher_client.h"
20 #include "ui/aura/focus_manager.h" 20 #include "ui/aura/focus_manager.h"
21 #include "ui/aura/root_window.h" 21 #include "ui/aura/root_window.h"
22 #include "ui/aura/shared/compound_event_filter.h" 22 #include "ui/views/corewm/compound_event_filter.h"
23 #include "ui/aura/shared/input_method_event_filter.h" 23 #include "ui/views/corewm/input_method_event_filter.h"
24 #include "ui/aura/window_property.h" 24 #include "ui/aura/window_property.h"
25 #include "ui/base/events/event_utils.h" 25 #include "ui/base/events/event_utils.h"
26 #include "ui/base/native_theme/native_theme.h" 26 #include "ui/base/native_theme/native_theme.h"
27 #include "ui/base/touch/touch_factory.h" 27 #include "ui/base/touch/touch_factory.h"
28 #include "ui/base/x/x11_util.h" 28 #include "ui/base/x/x11_util.h"
29 #include "ui/views/ime/input_method_bridge.h" 29 #include "ui/views/ime/input_method_bridge.h"
30 #include "ui/views/widget/desktop_layout_manager.h" 30 #include "ui/views/widget/desktop_layout_manager.h"
31 #include "ui/views/widget/desktop_native_widget_aura.h" 31 #include "ui/views/widget/desktop_native_widget_aura.h"
32 #include "ui/views/widget/desktop_screen_position_client.h" 32 #include "ui/views/widget/desktop_screen_position_client.h"
33 #include "ui/views/widget/x11_desktop_handler.h" 33 #include "ui/views/widget/x11_desktop_handler.h"
(...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
228 228
229 cursor_client_.reset(new aura::DesktopCursorClient(root_window_)); 229 cursor_client_.reset(new aura::DesktopCursorClient(root_window_));
230 aura::client::SetCursorClient(root_window_, 230 aura::client::SetCursorClient(root_window_,
231 cursor_client_.get()); 231 cursor_client_.get());
232 232
233 position_client_.reset(new DesktopScreenPositionClient()); 233 position_client_.reset(new DesktopScreenPositionClient());
234 aura::client::SetScreenPositionClient(root_window_, 234 aura::client::SetScreenPositionClient(root_window_,
235 position_client_.get()); 235 position_client_.get());
236 236
237 // No event filter for aura::Env. Create CompoundEvnetFilter per RootWindow. 237 // No event filter for aura::Env. Create CompoundEvnetFilter per RootWindow.
238 root_window_event_filter_ = new aura::shared::CompoundEventFilter; 238 root_window_event_filter_ = new views::corewm::CompoundEventFilter;
239 // Pass ownership of the filter to the root_window. 239 // Pass ownership of the filter to the root_window.
240 root_window_->SetEventFilter(root_window_event_filter_); 240 root_window_->SetEventFilter(root_window_event_filter_);
241 241
242 input_method_filter_.reset(new aura::shared::InputMethodEventFilter()); 242 input_method_filter_.reset(new views::corewm::InputMethodEventFilter);
243 input_method_filter_->SetInputMethodPropertyInRootWindow(root_window_); 243 input_method_filter_->SetInputMethodPropertyInRootWindow(root_window_);
244 root_window_event_filter_->AddFilter(input_method_filter_.get()); 244 root_window_event_filter_->AddFilter(input_method_filter_.get());
245 245
246 // TODO(erg): Unify this code once the other consumer goes away. 246 // TODO(erg): Unify this code once the other consumer goes away.
247 x11_window_event_filter_.reset( 247 x11_window_event_filter_.reset(
248 new X11WindowEventFilter(root_window_, activation_client_.get())); 248 new X11WindowEventFilter(root_window_, activation_client_.get()));
249 x11_window_event_filter_->SetUseHostWindowBorders(false); 249 x11_window_event_filter_->SetUseHostWindowBorders(false);
250 root_window_event_filter_->AddFilter(x11_window_event_filter_.get()); 250 root_window_event_filter_->AddFilter(x11_window_event_filter_.get());
251 251
252 x11_window_move_client_.reset(new X11DesktopWindowMoveClient); 252 x11_window_move_client_.reset(new X11DesktopWindowMoveClient);
(...skipping 843 matching lines...) Expand 10 before | Expand all | Expand 10 after
1096 DesktopRootWindowHost* DesktopRootWindowHost::Create( 1096 DesktopRootWindowHost* DesktopRootWindowHost::Create(
1097 internal::NativeWidgetDelegate* native_widget_delegate, 1097 internal::NativeWidgetDelegate* native_widget_delegate,
1098 DesktopNativeWidgetAura* desktop_native_widget_aura, 1098 DesktopNativeWidgetAura* desktop_native_widget_aura,
1099 const gfx::Rect& initial_bounds) { 1099 const gfx::Rect& initial_bounds) {
1100 return new DesktopRootWindowHostLinux(native_widget_delegate, 1100 return new DesktopRootWindowHostLinux(native_widget_delegate,
1101 desktop_native_widget_aura, 1101 desktop_native_widget_aura,
1102 initial_bounds); 1102 initial_bounds);
1103 } 1103 }
1104 1104
1105 } // namespace views 1105 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/widget/desktop_root_window_host_linux.h ('k') | ui/views/widget/desktop_root_window_host_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698