| Index: ui/aura/window_tree_host_platform.h
|
| diff --git a/ui/aura/window_tree_host_win.h b/ui/aura/window_tree_host_platform.h
|
| similarity index 73%
|
| rename from ui/aura/window_tree_host_win.h
|
| rename to ui/aura/window_tree_host_platform.h
|
| index e49890d2f67ea7789136ba32711820ead8437e1d..79f41b1bf38f2431083aff3a04d0caf6a3fd965a 100644
|
| --- a/ui/aura/window_tree_host_win.h
|
| +++ b/ui/aura/window_tree_host_platform.h
|
| @@ -1,26 +1,30 @@
|
| -// Copyright (c) 2012 The Chromium Authors. All rights reserved.
|
| +// Copyright 2015 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 UI_AURA_WINDOW_TREE_HOST_WIN_H_
|
| -#define UI_AURA_WINDOW_TREE_HOST_WIN_H_
|
| +#ifndef UI_AURA_WINDOW_TREE_HOST_PLATFORM_H_
|
| +#define UI_AURA_WINDOW_TREE_HOST_PLATFORM_H_
|
|
|
| #include "base/compiler_specific.h"
|
| #include "base/memory/scoped_ptr.h"
|
| #include "ui/aura/aura_export.h"
|
| #include "ui/aura/window_tree_host.h"
|
| +#include "ui/gfx/native_widget_types.h"
|
| #include "ui/platform_window/platform_window.h"
|
| #include "ui/platform_window/platform_window_delegate.h"
|
|
|
| namespace aura {
|
|
|
| -class AURA_EXPORT WindowTreeHostWin
|
| +// The unified WindowTreeHost implementation for platforms
|
| +// that implement PlatformWindow.
|
| +class AURA_EXPORT WindowTreeHostPlatform
|
| : public WindowTreeHost,
|
| public NON_EXPORTED_BASE(ui::PlatformWindowDelegate) {
|
| public:
|
| - explicit WindowTreeHostWin(const gfx::Rect& bounds);
|
| - ~WindowTreeHostWin() override;
|
| + explicit WindowTreeHostPlatform(const gfx::Rect& bounds);
|
| + ~WindowTreeHostPlatform() override;
|
|
|
| + protected:
|
| // WindowTreeHost:
|
| ui::EventSource* GetEventSource() override;
|
| gfx::AcceleratedWidget GetAcceleratedWidget() override;
|
| @@ -35,8 +39,7 @@ class AURA_EXPORT WindowTreeHostWin
|
| void MoveCursorToNative(const gfx::Point& location) override;
|
| void OnCursorVisibilityChangedNative(bool show) override;
|
|
|
| - protected:
|
| - gfx::AcceleratedWidget hwnd() const { return widget_; }
|
| + ui::PlatformWindow* platform_window() { return platform_window_.get(); }
|
|
|
| private:
|
| // ui::PlatformWindowDelegate:
|
| @@ -51,14 +54,15 @@ class AURA_EXPORT WindowTreeHostWin
|
| float device_pixel_ratio) override;
|
| void OnActivationChanged(bool active) override;
|
|
|
| - bool has_capture_;
|
| - gfx::Rect bounds_;
|
| gfx::AcceleratedWidget widget_;
|
| scoped_ptr<ui::PlatformWindow> window_;
|
| + bool has_capture_;
|
| + gfx::NativeCursor current_cursor_;
|
| + gfx::Rect bounds_;
|
|
|
| - DISALLOW_COPY_AND_ASSIGN(WindowTreeHostWin);
|
| + DISALLOW_COPY_AND_ASSIGN(WindowTreeHostPlatform);
|
| };
|
|
|
| } // namespace aura
|
|
|
| -#endif // UI_AURA_WINDOW_TREE_HOST_WIN_H_
|
| +#endif // UI_AURA_WINDOW_TREE_HOST_PLATFORM_H_
|
|
|