Index: ash/host/ash_window_tree_host_x11.h |
diff --git a/ash/host/ash_window_tree_host_x11.h b/ash/host/ash_window_tree_host_x11.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..6a11ef31a4e0fb482e538cbdf45146b85d8d79a4 |
--- /dev/null |
+++ b/ash/host/ash_window_tree_host_x11.h |
@@ -0,0 +1,77 @@ |
+// Copyright 2014 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef ASH_HOST_ASH_WINDOW_TREE_HOST_X11_H_ |
+#define ASH_HOST_ASH_WINDOW_TREE_HOST_X11_H_ |
+ |
+#include "ash/ash_export.h" |
+#include "ash/host/ash_window_tree_host.h" |
+#include "base/memory/scoped_ptr.h" |
+#include "ui/aura/env_observer.h" |
+#include "ui/aura/window_tree_host_x11.h" |
+#include "ui/gfx/insets.h" |
+#include "ui/gfx/rect.h" |
+ |
+namespace ash { |
+ |
+namespace internal { |
+class TouchEventCalibrate; |
+} |
+class RootWindowTransformer; |
+ |
+class ASH_EXPORT AshWindowTreeHostX11 : public AshWindowTreeHost, |
+ public aura::WindowTreeHostX11, |
+ public aura::EnvObserver { |
+ public: |
+ explicit AshWindowTreeHostX11(const gfx::Rect& bounds); |
+ virtual ~AshWindowTreeHostX11(); |
+ |
+ // AshWindowTreeHost: |
+ virtual void ToggleFullScreen() OVERRIDE; |
+ virtual gfx::Insets GetInsets() const OVERRIDE; |
+ virtual void SetInsets(const gfx::Insets& insets) OVERRIDE; |
+ virtual bool ConfineCursorToRootWindow() OVERRIDE; |
+ virtual void UnConfineCursor() OVERRIDE; |
+ virtual void SetRootWindowTransformer( |
+ scoped_ptr<RootWindowTransformer> transformer) OVERRIDE; |
+ virtual aura::WindowTreeHost* AsWindowTreeHost() OVERRIDE; |
+ |
+ // aura::WindowTreehost: |
+ virtual void SetTransform(const gfx::Transform& transform) OVERRIDE; |
+ virtual gfx::Transform GetRootTransform() const OVERRIDE; |
+ virtual gfx::Transform GetInverseRootTransform() const OVERRIDE; |
+ virtual void UpdateRootWindowSize(const gfx::Size& host_size) OVERRIDE; |
+ virtual void OnCursorVisibilityChangedNative(bool show) OVERRIDE; |
+ |
+ // aura::WindowTreeHostX11: |
+ virtual void TranslateAndDispatchLocatedEvent(ui::LocatedEvent* event) OVERRIDE; |
+ |
+ // EnvObserver overrides. |
+ virtual void OnWindowInitialized(aura::Window* window) OVERRIDE; |
+ virtual void OnHostInitialized(aura::WindowTreeHost* host) OVERRIDE; |
+ |
+ protected: |
+ |
+ private: |
+ void SetCrOSTapPaused(bool state); |
+ void UpdateIsInternalDisplay(); |
+ |
+ // The insets that specifies the effective area within the |window_|. |
+ gfx::Insets insets_; |
+ |
+ // True if the root host resides on the internal display |
+ bool is_internal_display_; |
+ |
+ scoped_ptr<XID[]> pointer_barriers_; |
+ |
+ scoped_ptr<internal::TouchEventCalibrate> touch_calibrate_; |
+ |
+ scoped_ptr<RootWindowTransformer> transformer_; |
+ |
+ DISALLOW_COPY_AND_ASSIGN(AshWindowTreeHostX11); |
+}; |
+ |
+} // namespace ash |
+ |
+#endif // ASH_HOST_ASH_WINDOW_TREE_HOST_X11_H_ |