OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 512 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
523 | 523 |
524 size_t insertPosition = 0; | 524 size_t insertPosition = 0; |
525 while (insertPosition < m_activeSourceBuffers->length() | 525 while (insertPosition < m_activeSourceBuffers->length() |
526 && m_sourceBuffers->find(m_activeSourceBuffers->item(insertPosition)) <
indexInSourceBuffers) { | 526 && m_sourceBuffers->find(m_activeSourceBuffers->item(insertPosition)) <
indexInSourceBuffers) { |
527 ++insertPosition; | 527 ++insertPosition; |
528 } | 528 } |
529 | 529 |
530 m_activeSourceBuffers->insert(insertPosition, sourceBuffer); | 530 m_activeSourceBuffers->insert(insertPosition, sourceBuffer); |
531 } | 531 } |
532 | 532 |
| 533 HTMLMediaElement* MediaSource::getHTMLMediaElement() const |
| 534 { |
| 535 return m_attachedElement; |
| 536 } |
| 537 |
533 bool MediaSource::isClosed() const | 538 bool MediaSource::isClosed() const |
534 { | 539 { |
535 return readyState() == closedKeyword(); | 540 return readyState() == closedKeyword(); |
536 } | 541 } |
537 | 542 |
538 void MediaSource::close() | 543 void MediaSource::close() |
539 { | 544 { |
540 setReadyState(closedKeyword()); | 545 setReadyState(closedKeyword()); |
541 } | 546 } |
542 | 547 |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
613 | 618 |
614 m_asyncEventQueue->enqueueEvent(event.release()); | 619 m_asyncEventQueue->enqueueEvent(event.release()); |
615 } | 620 } |
616 | 621 |
617 URLRegistry& MediaSource::registry() const | 622 URLRegistry& MediaSource::registry() const |
618 { | 623 { |
619 return MediaSourceRegistry::registry(); | 624 return MediaSourceRegistry::registry(); |
620 } | 625 } |
621 | 626 |
622 } // namespace blink | 627 } // namespace blink |
OLD | NEW |