diff options
Diffstat (limited to 'WebKit/mac')
-rw-r--r-- | WebKit/mac/ChangeLog | 37 | ||||
-rw-r--r-- | WebKit/mac/Misc/WebCoreStatistics.h | 1 | ||||
-rw-r--r-- | WebKit/mac/Misc/WebCoreStatistics.mm | 6 | ||||
-rw-r--r-- | WebKit/mac/Plugins/Hosted/NetscapePluginInstanceProxy.mm | 9 | ||||
-rw-r--r-- | WebKit/mac/WebView/WebVideoFullscreenHUDWindowController.mm | 8 |
5 files changed, 57 insertions, 4 deletions
diff --git a/WebKit/mac/ChangeLog b/WebKit/mac/ChangeLog index 205583a..8bbd4de 100644 --- a/WebKit/mac/ChangeLog +++ b/WebKit/mac/ChangeLog @@ -1 +1,38 @@ +2010-02-01 Shinichiro Hamaji <hamaji@chromium.org> + + Reviewed by Eric Seidel. + + Provide a way to get page number with layoutTestController + https://bugs.webkit.org/show_bug.cgi?id=33840 + + * Misc/WebCoreStatistics.h: + * Misc/WebCoreStatistics.mm: + (-[WebFrame pageNumberForElement:element:pageWidth:]): + +2010-01-29 Gavin Barraclough <barraclough@apple.com> + + Reviewed by Sam Weinig + Oliver Hunt. + + Bug 34346 - With JSC bindings, make processingUserGesture work with events in Isolated Worlds + + Pass processeing user gensture flag to media play/pause methods. + + * WebView/WebVideoFullscreenHUDWindowController.mm: + (-[WebVideoFullscreenHUDWindowController setPlaying:]): + +2010-02-01 Dan Bernstein <mitz@apple.com> + + Reviewed by Anders Carlsson. + + <rdar://problem/7044385> Crash at NetscapePlugInStreamLoader::didReceiveResponse() + + The crash was caused by having two streams with a streamID of 1. + + * Plugins/Hosted/NetscapePluginInstanceProxy.mm: + (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy): Fixed a typo. Now + correctly increments m_currentURLRequestID to account for the manual stream. + (WebKit::NetscapePluginInstanceProxy::disconnectStream): If the stream is the manual stream, + null it out instead of trying to remove it from the map. Added an assertion. + (WebKit::NetscapePluginInstanceProxy::loadRequest): Added an assertion. + == Rolled over to ChangeLog-2010-01-29 == diff --git a/WebKit/mac/Misc/WebCoreStatistics.h b/WebKit/mac/Misc/WebCoreStatistics.h index 7a189ae..6c45fb9 100644 --- a/WebKit/mac/Misc/WebCoreStatistics.h +++ b/WebKit/mac/Misc/WebCoreStatistics.h @@ -84,4 +84,5 @@ @interface WebFrame (WebKitDebug) - (NSString *)renderTreeAsExternalRepresentation; - (NSString *)counterValueForElement:(DOMElement*)element; +- (int)pageNumberForElement:(DOMElement*)element:(float)pageWidthInPixels:(float)pageHeightInPixels; @end diff --git a/WebKit/mac/Misc/WebCoreStatistics.mm b/WebKit/mac/Misc/WebCoreStatistics.mm index f204ddb..b18ee29 100644 --- a/WebKit/mac/Misc/WebCoreStatistics.mm +++ b/WebKit/mac/Misc/WebCoreStatistics.mm @@ -40,6 +40,7 @@ #import <WebCore/IconDatabase.h> #import <WebCore/JSDOMWindow.h> #import <WebCore/PageCache.h> +#import <WebCore/PrintContext.h> #import <WebCore/RenderTreeAsText.h> #import <WebCore/RenderView.h> @@ -250,4 +251,9 @@ using namespace WebCore; return counterValueForElement(core(element)); } +- (int)pageNumberForElement:(DOMElement*)element:(float)pageWidthInPixels:(float)pageHeightInPixels +{ + return PrintContext::pageNumberForElement(core(element), FloatSize(pageWidthInPixels, pageHeightInPixels)); +} + @end diff --git a/WebKit/mac/Plugins/Hosted/NetscapePluginInstanceProxy.mm b/WebKit/mac/Plugins/Hosted/NetscapePluginInstanceProxy.mm index 187b0ea..e4fe1d2 100644 --- a/WebKit/mac/Plugins/Hosted/NetscapePluginInstanceProxy.mm +++ b/WebKit/mac/Plugins/Hosted/NetscapePluginInstanceProxy.mm @@ -126,7 +126,7 @@ NetscapePluginInstanceProxy::NetscapePluginInstanceProxy(NetscapePluginHostProxy if (fullFramePlugin) { // For full frame plug-ins, the first requestID will always be the one for the already // open stream. - ++m_currentRequestID; + ++m_currentURLRequestID; } // Assign a plug-in ID. @@ -261,6 +261,12 @@ bool NetscapePluginInstanceProxy::cancelStreamLoad(uint32_t streamID, NPReason r void NetscapePluginInstanceProxy::disconnectStream(HostedNetscapePluginStream* stream) { + if (stream == m_manualStream) { + m_manualStream = 0; + return; + } + + ASSERT(m_streams.get(stream->streamID()) == stream); m_streams.remove(stream->streamID()); } @@ -655,6 +661,7 @@ NPError NetscapePluginInstanceProxy::loadRequest(NSURLRequest *request, const ch } else { RefPtr<HostedNetscapePluginStream> stream = HostedNetscapePluginStream::create(this, requestID, request); + ASSERT(!m_streams.contains(requestID)); m_streams.add(requestID, stream); stream->start(); } diff --git a/WebKit/mac/WebView/WebVideoFullscreenHUDWindowController.mm b/WebKit/mac/WebView/WebVideoFullscreenHUDWindowController.mm index 82cb1bf..83e2d09 100644 --- a/WebKit/mac/WebView/WebVideoFullscreenHUDWindowController.mm +++ b/WebKit/mac/WebView/WebVideoFullscreenHUDWindowController.mm @@ -578,13 +578,15 @@ static NSTextField *createTimeTextField(NSRect frame) - (void)setPlaying:(BOOL)playing { - if (![_delegate mediaElement]) + HTMLMediaElement* mediaElement = [_delegate mediaElement]; + + if (!mediaElement) return; if (playing) - [_delegate mediaElement]->play(); + mediaElement->play(mediaElement->processingUserGesture()); else - [_delegate mediaElement]->pause(); + mediaElement->pause(mediaElement->processingUserGesture()); } static NSString *timeToString(double time) |