| 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 CHROME_BROWSER_MEDIA_CAST_TRANSPORT_HOST_FILTER_H_ | 5 #ifndef CHROME_BROWSER_MEDIA_CAST_TRANSPORT_HOST_FILTER_H_ |
| 6 #define CHROME_BROWSER_MEDIA_CAST_TRANSPORT_HOST_FILTER_H_ | 6 #define CHROME_BROWSER_MEDIA_CAST_TRANSPORT_HOST_FILTER_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 86 const net::IPEndPoint& local_end_point, | 86 const net::IPEndPoint& local_end_point, |
| 87 const net::IPEndPoint& remote_end_point, | 87 const net::IPEndPoint& remote_end_point, |
| 88 const base::DictionaryValue& options); | 88 const base::DictionaryValue& options); |
| 89 void OnDelete(int32_t channel_id); | 89 void OnDelete(int32_t channel_id); |
| 90 | 90 |
| 91 // Sends frame events from CastRemotingSender to renderer process for logging. | 91 // Sends frame events from CastRemotingSender to renderer process for logging. |
| 92 void OnCastRemotingSenderEvents( | 92 void OnCastRemotingSenderEvents( |
| 93 int32_t channel_id, | 93 int32_t channel_id, |
| 94 const std::vector<media::cast::FrameEvent>& events); | 94 const std::vector<media::cast::FrameEvent>& events); |
| 95 | 95 |
| 96 IDMap<media::cast::CastTransport, IDMapOwnPointer> id_map_; | 96 IDMap<std::unique_ptr<media::cast::CastTransport>> id_map_; |
| 97 | 97 |
| 98 // Clock used by Cast transport. | 98 // Clock used by Cast transport. |
| 99 base::DefaultTickClock clock_; | 99 base::DefaultTickClock clock_; |
| 100 | 100 |
| 101 // While |id_map_| is non-empty, hold an instance of | 101 // While |id_map_| is non-empty, hold an instance of |
| 102 // device::PowerSaveBlocker. This prevents Chrome from being suspended while | 102 // device::PowerSaveBlocker. This prevents Chrome from being suspended while |
| 103 // remoting content. | 103 // remoting content. |
| 104 std::unique_ptr<device::PowerSaveBlocker> power_save_blocker_; | 104 std::unique_ptr<device::PowerSaveBlocker> power_save_blocker_; |
| 105 | 105 |
| 106 // This map records all active remoting senders. It uses the unique RTP | 106 // This map records all active remoting senders. It uses the unique RTP |
| 107 // stream ID as the key. | 107 // stream ID as the key. |
| 108 IDMap<CastRemotingSender, IDMapOwnPointer> remoting_sender_map_; | 108 IDMap<std::unique_ptr<CastRemotingSender>> remoting_sender_map_; |
| 109 | 109 |
| 110 // This map stores all active remoting streams for each channel. It uses the | 110 // This map stores all active remoting streams for each channel. It uses the |
| 111 // channel ID as the key. | 111 // channel ID as the key. |
| 112 std::multimap<int32_t, int32_t> stream_id_map_; | 112 std::multimap<int32_t, int32_t> stream_id_map_; |
| 113 | 113 |
| 114 base::WeakPtrFactory<CastTransportHostFilter> weak_factory_; | 114 base::WeakPtrFactory<CastTransportHostFilter> weak_factory_; |
| 115 | 115 |
| 116 DISALLOW_COPY_AND_ASSIGN(CastTransportHostFilter); | 116 DISALLOW_COPY_AND_ASSIGN(CastTransportHostFilter); |
| 117 }; | 117 }; |
| 118 | 118 |
| 119 } // namespace cast | 119 } // namespace cast |
| 120 | 120 |
| 121 #endif // CHROME_BROWSER_MEDIA_CAST_TRANSPORT_HOST_FILTER_H_ | 121 #endif // CHROME_BROWSER_MEDIA_CAST_TRANSPORT_HOST_FILTER_H_ |
| OLD | NEW |