OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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_OZONE_PLATFORM_DRI_DRI_GPU_PLATFORM_SUPPORT_HOST_H_ | 5 #ifndef UI_OZONE_PLATFORM_DRI_DRI_GPU_PLATFORM_SUPPORT_HOST_H_ |
6 #define UI_OZONE_PLATFORM_DRI_DRI_GPU_PLATFORM_SUPPORT_HOST_H_ | 6 #define UI_OZONE_PLATFORM_DRI_DRI_GPU_PLATFORM_SUPPORT_HOST_H_ |
7 | 7 |
8 #include <queue> | 8 #include <queue> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 21 matching lines...) Expand all Loading... |
32 | 32 |
33 bool IsConnected() const; | 33 bool IsConnected() const; |
34 | 34 |
35 void RegisterHandler(GpuPlatformSupportHost* handler); | 35 void RegisterHandler(GpuPlatformSupportHost* handler); |
36 void UnregisterHandler(GpuPlatformSupportHost* handler); | 36 void UnregisterHandler(GpuPlatformSupportHost* handler); |
37 | 37 |
38 void AddChannelObserver(ChannelObserver* observer); | 38 void AddChannelObserver(ChannelObserver* observer); |
39 void RemoveChannelObserver(ChannelObserver* observer); | 39 void RemoveChannelObserver(ChannelObserver* observer); |
40 | 40 |
41 // GpuPlatformSupportHost: | 41 // GpuPlatformSupportHost: |
42 virtual void OnChannelEstablished(int host_id, IPC::Sender* sender) OVERRIDE; | 42 virtual void OnChannelEstablished(int host_id, IPC::Sender* sender) override; |
43 virtual void OnChannelDestroyed(int host_id) OVERRIDE; | 43 virtual void OnChannelDestroyed(int host_id) override; |
44 | 44 |
45 // IPC::Listener: | 45 // IPC::Listener: |
46 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; | 46 virtual bool OnMessageReceived(const IPC::Message& message) override; |
47 | 47 |
48 // IPC::Sender: | 48 // IPC::Sender: |
49 virtual bool Send(IPC::Message* message) OVERRIDE; | 49 virtual bool Send(IPC::Message* message) override; |
50 | 50 |
51 // HardwareCursorDelegate: | 51 // HardwareCursorDelegate: |
52 virtual void SetHardwareCursor(gfx::AcceleratedWidget widget, | 52 virtual void SetHardwareCursor(gfx::AcceleratedWidget widget, |
53 const std::vector<SkBitmap>& bitmaps, | 53 const std::vector<SkBitmap>& bitmaps, |
54 const gfx::Point& location, | 54 const gfx::Point& location, |
55 int frame_delay_ms) OVERRIDE; | 55 int frame_delay_ms) override; |
56 virtual void MoveHardwareCursor(gfx::AcceleratedWidget widget, | 56 virtual void MoveHardwareCursor(gfx::AcceleratedWidget widget, |
57 const gfx::Point& location) OVERRIDE; | 57 const gfx::Point& location) override; |
58 | 58 |
59 private: | 59 private: |
60 int host_id_; | 60 int host_id_; |
61 IPC::Sender* sender_; | 61 IPC::Sender* sender_; |
62 std::vector<GpuPlatformSupportHost*> handlers_; | 62 std::vector<GpuPlatformSupportHost*> handlers_; |
63 // If messages are sent before the channel is created, store the messages and | 63 // If messages are sent before the channel is created, store the messages and |
64 // delay sending them until the channel is created. These messages are stored | 64 // delay sending them until the channel is created. These messages are stored |
65 // in |queued_messaged_|. | 65 // in |queued_messaged_|. |
66 std::queue<IPC::Message*> queued_messages_; | 66 std::queue<IPC::Message*> queued_messages_; |
67 ObserverList<ChannelObserver> channel_observers_; | 67 ObserverList<ChannelObserver> channel_observers_; |
68 }; | 68 }; |
69 | 69 |
70 } // namespace ui | 70 } // namespace ui |
71 | 71 |
72 #endif // UI_OZONE_GPU_DRI_GPU_PLATFORM_SUPPORT_HOST_H_ | 72 #endif // UI_OZONE_GPU_DRI_GPU_PLATFORM_SUPPORT_HOST_H_ |
OLD | NEW |