[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
jer.noble at apple.com
jer.noble at apple.com
Wed Dec 22 14:46:14 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit c850b32a2206d374e57c641cdb9dc59e799c4199
Author: jer.noble at apple.com <jer.noble at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Tue Oct 19 21:11:24 2010 +0000
Windows: Implement 'preload=none'
https://bugs.webkit.org/show_bug.cgi?id=47317
<rdar://problem/7718442>
Reviewed by Eric Carlson.
WebCore:
Implement the 'preload=none' identically to the mac implementation. Add three new
ivars: m_preload, m_delayLoad and m_movieURL; and override the MediaPlayerPrivate
functions: prepareToPlay() and setPreload().
* platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::MediaPlayerPrivateQuickTimeVisualContext):
Initialize new ivars m_delayLoad and m_preload.
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::resumeLoad): Added; new.
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::load): Split contents between
load and loadInternal.
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::loadInternal): Added; new.
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::prepareToPlay): Added; overrides MediaPlayerPrivate.
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::setPreload): Added; overrides MediaPlayerPrivate.
* platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h:
LayoutTests:
Do not skip the media/video-preload.html test on windows any longer.
* platform/win/Skipped:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@70084 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 56ccdf5..3e876f3 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,15 @@
+2010-10-06 Jer Noble <jer.noble at apple.com>
+
+ Reviewed by Eric Carlson.
+
+ Windows: Implement 'preload=none'
+ https://bugs.webkit.org/show_bug.cgi?id=47317
+ <rdar://problem/7718442>
+
+ Do not skip the media/video-preload.html test on windows any longer.
+
+ * platform/win/Skipped:
+
2010-10-19 Zhenyao Mo <zmo at google.com>
Unreviewed, remove a passing webgl test from test_expectations.txt.
diff --git a/LayoutTests/platform/win/Skipped b/LayoutTests/platform/win/Skipped
index 340fb6f..dc097c8 100644
--- a/LayoutTests/platform/win/Skipped
+++ b/LayoutTests/platform/win/Skipped
@@ -830,9 +830,6 @@ java
# Need to add functionality to DumpRenderTree to handle enable/disable Spatial Navigation
fast/events/spatial-navigation
-# <rdar://problem/7718442> Implement 'preload=none'
-media/video-preload.html
-
# For some reason crashes when run with all tests. Passes individually.
fast/forms/multiple-form-submission-protection-mouse.html
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 5b50b01..46e0961 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,26 @@
+2010-10-06 Jer Noble <jer.noble at apple.com>
+
+ Reviewed by Eric Carlson.
+
+ Windows: Implement 'preload=none'
+ https://bugs.webkit.org/show_bug.cgi?id=47317
+ <rdar://problem/7718442>
+
+ Implement the 'preload=none' identically to the mac implementation. Add three new
+ ivars: m_preload, m_delayLoad and m_movieURL; and override the MediaPlayerPrivate
+ functions: prepareToPlay() and setPreload().
+
+ * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::MediaPlayerPrivateQuickTimeVisualContext):
+ Initialize new ivars m_delayLoad and m_preload.
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::resumeLoad): Added; new.
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::load): Split contents between
+ load and loadInternal.
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::loadInternal): Added; new.
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::prepareToPlay): Added; overrides MediaPlayerPrivate.
+ (WebCore::MediaPlayerPrivateQuickTimeVisualContext::setPreload): Added; overrides MediaPlayerPrivate.
+ * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h:
+
2010-10-19 Enrica Casucci <enrica at apple.com>
Reviewed by Alexey Proskuryakov.
diff --git a/WebCore/platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp b/WebCore/platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp
index d2c258e..1b4f1d9 100644
--- a/WebCore/platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp
+++ b/WebCore/platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp
@@ -174,6 +174,8 @@ MediaPlayerPrivateQuickTimeVisualContext::MediaPlayerPrivateQuickTimeVisualConte
, m_movieTransform(CGAffineTransformIdentity)
#endif
, m_visualContextClient(new MediaPlayerPrivateQuickTimeVisualContext::VisualContextClient(this))
+ , m_delayingLoad(false)
+ , m_preload(MediaPlayer::Auto)
{
}
@@ -316,8 +318,28 @@ static void disableComponentsOnce()
QTMovie::disableComponent(componentsToDisable[i]);
}
+void MediaPlayerPrivateQuickTimeVisualContext::resumeLoad()
+{
+ m_delayingLoad = false;
+
+ if (!m_movieURL.isEmpty())
+ loadInternal(m_movieURL);
+}
+
void MediaPlayerPrivateQuickTimeVisualContext::load(const String& url)
{
+ m_movieURL = url;
+
+ if (m_preload == MediaPlayer::None) {
+ m_delayingLoad = true;
+ return;
+ }
+
+ loadInternal(url);
+}
+
+void MediaPlayerPrivateQuickTimeVisualContext::loadInternal(const String& url)
+{
if (!QTMovie::initializeQuickTime()) {
// FIXME: is this the right error to return?
m_networkState = MediaPlayer::DecodeError;
@@ -347,6 +369,12 @@ void MediaPlayerPrivateQuickTimeVisualContext::load(const String& url)
m_movie->setVolume(m_player->volume());
}
+void MediaPlayerPrivateQuickTimeVisualContext::prepareToPlay()
+{
+ if (!m_movie || m_delayingLoad)
+ resumeLoad();
+}
+
void MediaPlayerPrivateQuickTimeVisualContext::play()
{
if (!m_movie)
@@ -1005,6 +1033,13 @@ bool MediaPlayerPrivateQuickTimeVisualContext::hasSingleSecurityOrigin() const
return true;
}
+void MediaPlayerPrivateQuickTimeVisualContext::setPreload(MediaPlayer::Preload preload)
+{
+ m_preload = preload;
+ if (m_delayingLoad && m_preload != MediaPlayer::None)
+ resumeLoad();
+}
+
MediaPlayerPrivateQuickTimeVisualContext::MediaRenderingMode MediaPlayerPrivateQuickTimeVisualContext::currentRenderingMode() const
{
if (!m_movie)
diff --git a/WebCore/platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h b/WebCore/platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h
index 272b90f..4c62558 100644
--- a/WebCore/platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h
+++ b/WebCore/platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h
@@ -74,9 +74,12 @@ private:
void load(const String& url);
void cancelLoad();
+ void loadInternal(const String& url);
+ void resumeLoad();
void play();
void pause();
+ void prepareToPlay();
bool paused() const;
bool seeking() const;
@@ -111,6 +114,8 @@ private:
bool hasClosedCaptions() const;
void setClosedCaptionsVisible(bool);
+ void setPreload(MediaPlayer::Preload);
+
void updateStates();
void doSeek();
void cancelSeek();
@@ -189,6 +194,9 @@ private:
bool m_isStreaming;
bool m_visible;
bool m_newFrameAvailable;
+ bool m_delayingLoad;
+ String m_movieURL;
+ MediaPlayer::Preload m_preload;
#if DRAW_FRAME_RATE
double m_frameCountWhilePlaying;
double m_timeStartedPlaying;
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list