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

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

Issue 169363004: Remove the mediaEnabled setting (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase Created 6 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/frame/Settings.in ('k') | Source/core/inspector/InspectorOverlay.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 604 matching lines...) Expand 10 before | Expand all | Expand 10 after
615 615
616 return canPlay; 616 return canPlay;
617 } 617 }
618 618
619 void HTMLMediaElement::load() 619 void HTMLMediaElement::load()
620 { 620 {
621 RefPtr<HTMLMediaElement> protect(this); // loadInternal may result in a 'bef oreload' event, which can make arbitrary DOM mutations. 621 RefPtr<HTMLMediaElement> protect(this); // loadInternal may result in a 'bef oreload' event, which can make arbitrary DOM mutations.
622 622
623 WTF_LOG(Media, "HTMLMediaElement::load()"); 623 WTF_LOG(Media, "HTMLMediaElement::load()");
624 624
625 if (document().settings() && !document().settings()->mediaEnabled())
626 return;
627
628 if (UserGestureIndicator::processingUserGesture()) 625 if (UserGestureIndicator::processingUserGesture())
629 removeBehaviorsRestrictionsAfterFirstUserGesture(); 626 removeBehaviorsRestrictionsAfterFirstUserGesture();
630 627
631 prepareForLoad(); 628 prepareForLoad();
632 loadInternal(); 629 loadInternal();
633 prepareToPlay(); 630 prepareToPlay();
634 } 631 }
635 632
636 void HTMLMediaElement::prepareForLoad() 633 void HTMLMediaElement::prepareForLoad()
637 { 634 {
(...skipping 3282 matching lines...) Expand 10 before | Expand all | Expand 10 after
3920 { 3917 {
3921 m_mediaSource->setWebMediaSourceAndOpen(adoptPtr(webMediaSource)); 3918 m_mediaSource->setWebMediaSourceAndOpen(adoptPtr(webMediaSource));
3922 } 3919 }
3923 3920
3924 bool HTMLMediaElement::isInteractiveContent() const 3921 bool HTMLMediaElement::isInteractiveContent() const
3925 { 3922 {
3926 return fastHasAttribute(controlsAttr); 3923 return fastHasAttribute(controlsAttr);
3927 } 3924 }
3928 3925
3929 } 3926 }
OLDNEW
« no previous file with comments | « Source/core/frame/Settings.in ('k') | Source/core/inspector/InspectorOverlay.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698