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

Unified Diff: ash/host/ash_window_tree_host_x11.cc

Issue 25108005: linux_aura: Compile ash into chrome. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Reupload to try off of ToT instead of LKGR Created 6 years, 7 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/host/ash_window_tree_host_x11.h ('k') | ash/host/ash_window_tree_host_x11_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/host/ash_window_tree_host_x11.cc
diff --git a/ash/host/ash_window_tree_host_x11.cc b/ash/host/ash_window_tree_host_x11.cc
index 94ca0cc67d2ba615b1d3fc12e098d4cb9e00175e..216dbb18f1f641b5750141e46aa93130fe03d288 100644
--- a/ash/host/ash_window_tree_host_x11.cc
+++ b/ash/host/ash_window_tree_host_x11.cc
@@ -286,7 +286,9 @@ void AshWindowTreeHostX11::UpdateRootWindowSize(const gfx::Size& host_size) {
}
void AshWindowTreeHostX11::OnCursorVisibilityChangedNative(bool show) {
+#if defined(OS_CHROMEOS)
SetCrOSTapPaused(!show);
+#endif
}
void AshWindowTreeHostX11::OnWindowInitialized(aura::Window* window) {}
@@ -300,9 +302,11 @@ void AshWindowTreeHostX11::OnHostInitialized(aura::WindowTreeHost* host) {
return;
UpdateIsInternalDisplay();
+#if defined(OS_CHROMEOS)
// We have to enable Tap-to-click by default because the cursor is set to
// visible in Shell::InitRootWindowController.
SetCrOSTapPaused(false);
+#endif
}
void AshWindowTreeHostX11::OnConfigureNotify() {
@@ -323,6 +327,7 @@ void AshWindowTreeHostX11::TranslateAndDispatchLocatedEvent(
case ui::ET_TOUCH_PRESSED:
case ui::ET_TOUCH_CANCELLED:
case ui::ET_TOUCH_RELEASED: {
+#if defined(OS_CHROMEOS)
ui::TouchEvent* touchev = static_cast<ui::TouchEvent*>(event);
if (base::SysInfo::IsRunningOnChromeOS()) {
// X maps the touch-surface to the size of the X root-window.
@@ -337,6 +342,7 @@ void AshWindowTreeHostX11::TranslateAndDispatchLocatedEvent(
touch_calibrate_->Calibrate(touchev, bounds());
#endif // defined(USE_XI2_MT)
}
+#endif // defined(OS_CHROMEOS)
break;
}
default: {
@@ -372,6 +378,7 @@ void AshWindowTreeHostX11::UpdateIsInternalDisplay() {
is_internal_display_ = display.IsInternal();
}
+#if defined(OS_CHROMEOS)
void AshWindowTreeHostX11::SetCrOSTapPaused(bool state) {
if (!ui::IsXInput2Available())
return;
@@ -414,6 +421,7 @@ void AshWindowTreeHostX11::SetCrOSTapPaused(bool state) {
}
}
}
+#endif
AshWindowTreeHost* AshWindowTreeHost::Create(const gfx::Rect& initial_bounds) {
return new AshWindowTreeHostX11(initial_bounds);
« no previous file with comments | « ash/host/ash_window_tree_host_x11.h ('k') | ash/host/ash_window_tree_host_x11_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698