Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(310)

Side by Side Diff: Source/core/html/HTMLMediaElement.h

Issue 302093011: Oilpan: move the MediaPlayer and MediaPlayerClient objects to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Move DummyBase from WebCore to WTF Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after
267 267
268 MediaController* controller() const; 268 MediaController* controller() const;
269 void setController(PassRefPtr<MediaController>); // Resets the MediaGroup an d sets the MediaController. 269 void setController(PassRefPtr<MediaController>); // Resets the MediaGroup an d sets the MediaController.
270 270
271 void scheduleEvent(PassRefPtrWillBeRawPtr<Event>); 271 void scheduleEvent(PassRefPtrWillBeRawPtr<Event>);
272 272
273 // Current volume that should be used by the webMediaPlayer(). This method t akes muted state 273 // Current volume that should be used by the webMediaPlayer(). This method t akes muted state
274 // and m_mediaController multipliers into account. 274 // and m_mediaController multipliers into account.
275 double playerVolume() const; 275 double playerVolume() const;
276 276
277 #if ENABLE(OILPAN)
278 bool isFinalizing() const { return m_isFinalizing; }
279 #endif
280
281 protected: 277 protected:
282 HTMLMediaElement(const QualifiedName&, Document&); 278 HTMLMediaElement(const QualifiedName&, Document&);
283 virtual ~HTMLMediaElement(); 279 virtual ~HTMLMediaElement();
284 280
285 virtual void parseAttribute(const QualifiedName&, const AtomicString&) OVERR IDE; 281 virtual void parseAttribute(const QualifiedName&, const AtomicString&) OVERR IDE;
286 virtual void finishParsingChildren() OVERRIDE FINAL; 282 virtual void finishParsingChildren() OVERRIDE FINAL;
287 virtual bool isURLAttribute(const Attribute&) const OVERRIDE; 283 virtual bool isURLAttribute(const Attribute&) const OVERRIDE;
288 virtual void attach(const AttachContext& = AttachContext()) OVERRIDE; 284 virtual void attach(const AttachContext& = AttachContext()) OVERRIDE;
289 285
290 virtual void didMoveToNewDocument(Document& oldDocument) OVERRIDE; 286 virtual void didMoveToNewDocument(Document& oldDocument) OVERRIDE;
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
452 448
453 // The last time a timeupdate event was sent in movie time. 449 // The last time a timeupdate event was sent in movie time.
454 double m_lastTimeUpdateEventMovieTime; 450 double m_lastTimeUpdateEventMovieTime;
455 451
456 // Loading state. 452 // Loading state.
457 enum LoadState { WaitingForSource, LoadingFromSrcAttr, LoadingFromSourceElem ent }; 453 enum LoadState { WaitingForSource, LoadingFromSrcAttr, LoadingFromSourceElem ent };
458 LoadState m_loadState; 454 LoadState m_loadState;
459 RefPtrWillBeMember<HTMLSourceElement> m_currentSourceNode; 455 RefPtrWillBeMember<HTMLSourceElement> m_currentSourceNode;
460 RefPtrWillBeMember<Node> m_nextChildNodeToConsider; 456 RefPtrWillBeMember<Node> m_nextChildNodeToConsider;
461 457
462 OwnPtr<MediaPlayer> m_player; 458 OwnPtrWillBeMember<MediaPlayer> m_player;
463 blink::WebLayer* m_webLayer; 459 blink::WebLayer* m_webLayer;
464 460
465 MediaPlayer::Preload m_preload; 461 MediaPlayer::Preload m_preload;
466 462
467 DisplayMode m_displayMode; 463 DisplayMode m_displayMode;
468 464
469 RefPtr<HTMLMediaSource> m_mediaSource; 465 RefPtr<HTMLMediaSource> m_mediaSource;
470 466
471 mutable double m_cachedTime; 467 mutable double m_cachedTime;
472 mutable double m_cachedTimeWallClockUpdateTime; 468 mutable double m_cachedTimeWallClockUpdateTime;
(...skipping 26 matching lines...) Expand all
499 495
500 bool m_closedCaptionsVisible : 1; 496 bool m_closedCaptionsVisible : 1;
501 497
502 bool m_completelyLoaded : 1; 498 bool m_completelyLoaded : 1;
503 bool m_havePreparedToPlay : 1; 499 bool m_havePreparedToPlay : 1;
504 bool m_delayingLoadForPreloadNone : 1; 500 bool m_delayingLoadForPreloadNone : 1;
505 501
506 bool m_tracksAreReady : 1; 502 bool m_tracksAreReady : 1;
507 bool m_haveVisibleTextTrack : 1; 503 bool m_haveVisibleTextTrack : 1;
508 bool m_processingPreferenceChange : 1; 504 bool m_processingPreferenceChange : 1;
509 #if ENABLE(OILPAN)
510 bool m_isFinalizing : 1;
511 #endif
512 double m_lastTextTrackUpdateTime; 505 double m_lastTextTrackUpdateTime;
513 506
514 RefPtrWillBeMember<TextTrackList> m_textTracks; 507 RefPtrWillBeMember<TextTrackList> m_textTracks;
515 WillBeHeapVector<RefPtrWillBeMember<TextTrack> > m_textTracksWhenResourceSel ectionBegan; 508 WillBeHeapVector<RefPtrWillBeMember<TextTrack> > m_textTracksWhenResourceSel ectionBegan;
516 509
517 CueIntervalTree m_cueTree; 510 CueIntervalTree m_cueTree;
518 511
519 CueList m_currentlyActiveCues; 512 CueList m_currentlyActiveCues;
520 int m_ignoreTrackDisplayUpdate; 513 int m_ignoreTrackDisplayUpdate;
521 514
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
560 inline bool isHTMLMediaElement(const HTMLElement& element) 553 inline bool isHTMLMediaElement(const HTMLElement& element)
561 { 554 {
562 return isHTMLAudioElement(element) || isHTMLVideoElement(element); 555 return isHTMLAudioElement(element) || isHTMLVideoElement(element);
563 } 556 }
564 557
565 DEFINE_HTMLELEMENT_TYPE_CASTS_WITH_FUNCTION(HTMLMediaElement); 558 DEFINE_HTMLELEMENT_TYPE_CASTS_WITH_FUNCTION(HTMLMediaElement);
566 559
567 } //namespace 560 } //namespace
568 561
569 #endif 562 #endif
OLDNEW
« no previous file with comments | « no previous file | Source/core/html/HTMLMediaElement.cpp » ('j') | Source/platform/graphics/media/MediaPlayer.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698