OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2013 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_COMPOSITOR_COMPOSITOR_RETRIEVER_DELEGATE_H_ |
| 6 #define UI_COMPOSITOR_COMPOSITOR_RETRIEVER_DELEGATE_H_ |
| 7 |
| 8 namespace gfx { |
| 9 class Display; |
| 10 } |
| 11 |
| 12 namespace ui { |
| 13 |
| 14 class Compositor; |
| 15 |
| 16 // A class that allows retrieving a compositor associated with a display. |
| 17 class CompositorRetrieverDelegate { |
| 18 public: |
| 19 // Returns the compositor associated with the display. |
| 20 virtual ui::Compositor* GetCompositorForDisplay( |
| 21 const gfx::Display& display) = 0; |
| 22 |
| 23 // Sets the CompositorRetrieverDelegate. Only one delegate may be registered. |
| 24 static void SetDelegate(CompositorRetrieverDelegate* delegate); |
| 25 |
| 26 // Gets the global CompositorRetrieverDelegate instance. |
| 27 static CompositorRetrieverDelegate* GetInstance(); |
| 28 }; |
| 29 |
| 30 } // namespace ui |
| 31 |
| 32 #endif // UI_COMPOSITOR_COMPOSITOR_RETRIEVER_DELEGATE_H_ |
OLD | NEW |