OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
3 * Copyright (C) 2011 Ericsson AB. All rights reserved. | 3 * Copyright (C) 2011 Ericsson AB. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
160 // TODO(pbos): Log warning? | 160 // TODO(pbos): Log warning? |
161 // Invalid values for video are to be ignored (similar to invalid enum | 161 // Invalid values for video are to be ignored (similar to invalid enum |
162 // values). | 162 // values). |
163 return; | 163 return; |
164 } | 164 } |
165 } | 165 } |
166 | 166 |
167 m_component->setContentHint(translatedHint); | 167 m_component->setContentHint(translatedHint); |
168 } | 168 } |
169 | 169 |
170 bool MediaStreamTrack::remote() const { | |
171 return m_component->source()->remote(); | |
172 } | |
173 | |
174 String MediaStreamTrack::readyState() const { | 170 String MediaStreamTrack::readyState() const { |
175 if (ended()) | 171 if (ended()) |
176 return "ended"; | 172 return "ended"; |
177 | 173 |
178 switch (m_readyState) { | 174 switch (m_readyState) { |
179 case MediaStreamSource::ReadyStateLive: | 175 case MediaStreamSource::ReadyStateLive: |
180 return "live"; | 176 return "live"; |
181 case MediaStreamSource::ReadyStateMuted: | 177 case MediaStreamSource::ReadyStateMuted: |
182 return "muted"; | 178 return "muted"; |
183 case MediaStreamSource::ReadyStateEnded: | 179 case MediaStreamSource::ReadyStateEnded: |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
346 } | 342 } |
347 | 343 |
348 DEFINE_TRACE(MediaStreamTrack) { | 344 DEFINE_TRACE(MediaStreamTrack) { |
349 visitor->trace(m_registeredMediaStreams); | 345 visitor->trace(m_registeredMediaStreams); |
350 visitor->trace(m_component); | 346 visitor->trace(m_component); |
351 EventTargetWithInlineData::trace(visitor); | 347 EventTargetWithInlineData::trace(visitor); |
352 ContextLifecycleObserver::trace(visitor); | 348 ContextLifecycleObserver::trace(visitor); |
353 } | 349 } |
354 | 350 |
355 } // namespace blink | 351 } // namespace blink |
OLD | NEW |