OLD | NEW |
(Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef UI_OZONE_WINDOW_WINDOW_FACTORY_OZONE_H_ |
| 6 #define UI_OZONE_WINDOW_WINDOW_FACTORY_OZONE_H_ |
| 7 |
| 8 #include <string> |
| 9 |
| 10 #include "base/memory/scoped_ptr.h" |
| 11 #include "ui/ozone/ozone_export.h" |
| 12 |
| 13 namespace gfx { |
| 14 class Rect; |
| 15 } |
| 16 |
| 17 namespace ui { |
| 18 |
| 19 class OzoneWindow; |
| 20 |
| 21 // Platform interface for creating OzoneWindows. |
| 22 class OZONE_EXPORT WindowFactoryOzone { |
| 23 public: |
| 24 WindowFactoryOzone(); |
| 25 virtual ~WindowFactoryOzone(); |
| 26 |
| 27 // Returns the instance |
| 28 static WindowFactoryOzone* GetInstance(); |
| 29 |
| 30 // Sets the implementation delegate. Ownership is retained by the caller. |
| 31 static void SetInstance(WindowFactoryOzone* impl); |
| 32 |
| 33 // Create an ozone window. |
| 34 virtual scoped_ptr<OzoneWindow> CreateWindow(const gfx::Rect& bounds); |
| 35 |
| 36 private: |
| 37 static WindowFactoryOzone* impl_; // not owned |
| 38 }; |
| 39 |
| 40 } // namespace ui |
| 41 |
| 42 #endif // UI_OZONE_WINDOW_WINDOW_FACTORY_OZONE_H_ |
OLD | NEW |