| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #ifndef UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_FACTORY_OZONE_H_ | 5 #ifndef UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_FACTORY_OZONE_H_ |
| 6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_FACTORY_OZONE_H_ | 6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_FACTORY_OZONE_H_ |
| 7 | 7 |
| 8 #include "ui/views/views_export.h" | 8 #include "ui/views/views_export.h" |
| 9 | 9 |
| 10 namespace display { | 10 namespace display { |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 } | 24 } |
| 25 | 25 |
| 26 class VIEWS_EXPORT DesktopFactoryOzone { | 26 class VIEWS_EXPORT DesktopFactoryOzone { |
| 27 public: | 27 public: |
| 28 DesktopFactoryOzone(); | 28 DesktopFactoryOzone(); |
| 29 virtual ~DesktopFactoryOzone(); | 29 virtual ~DesktopFactoryOzone(); |
| 30 | 30 |
| 31 // Returns the instance. | 31 // Returns the instance. |
| 32 static DesktopFactoryOzone* GetInstance(); | 32 static DesktopFactoryOzone* GetInstance(); |
| 33 | 33 |
| 34 // Sets the implementation delegate. Ownership is retained by the caller. | |
| 35 static void SetInstance(DesktopFactoryOzone* impl); | |
| 36 | |
| 37 // Delegates implementation of DesktopWindowTreeHost::Create externally to | 34 // Delegates implementation of DesktopWindowTreeHost::Create externally to |
| 38 // Ozone implementation. | 35 // Ozone implementation. |
| 39 virtual DesktopWindowTreeHost* CreateWindowTreeHost( | 36 virtual DesktopWindowTreeHost* CreateWindowTreeHost( |
| 40 internal::NativeWidgetDelegate* native_widget_delegate, | 37 internal::NativeWidgetDelegate* native_widget_delegate, |
| 41 DesktopNativeWidgetAura* desktop_native_widget_aura) = 0; | 38 DesktopNativeWidgetAura* desktop_native_widget_aura) = 0; |
| 42 | 39 |
| 43 // Delegates implementation of DesktopScreen externally to | 40 // Delegates implementation of DesktopScreen externally to |
| 44 // Ozone implementation. | 41 // Ozone implementation. |
| 45 virtual display::Screen* CreateDesktopScreen() = 0; | 42 virtual display::Screen* CreateDesktopScreen() = 0; |
| 46 | 43 |
| 47 private: | 44 private: |
| 48 static DesktopFactoryOzone* impl_; // not owned | 45 static DesktopFactoryOzone* impl_; // not owned |
| 49 }; | 46 }; |
| 50 | 47 |
| 51 } // namespace views | 48 } // namespace views |
| 52 | 49 |
| 53 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_FACTORY_OZONE_H_ | 50 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_FACTORY_OZONE_H_ |
| OLD | NEW |