MediaStream API: Update getUserMedia to match the latest specification
https://bugs.webkit.org/show_bug.cgi?id=97540

Reviewed by Adam Barth.

Source/Platform:

* chromium/public/WebMediaConstraints.h:
(WebMediaConstraints):

Source/WebCore:

http://dev.w3.org/2011/webrtc/editor/getusermedia.html#navigatorusermedia
Navigator.getUserMedia is changed so that the audio and video members can either
be a bool or a constraints object.

Existing tests expanded to cover the new change.

* Modules/mediastream/MediaConstraintsImpl.cpp:
(WebCore::MediaConstraintsImpl::create):
(WebCore):
* Modules/mediastream/MediaConstraintsImpl.h:
(MediaConstraintsImpl):
* Modules/mediastream/NavigatorMediaStream.cpp:
(WebCore::NavigatorMediaStream::webkitGetUserMedia):
* Modules/mediastream/UserMediaRequest.cpp:
(WebCore::parseOptions):
(WebCore):
(WebCore::UserMediaRequest::create):
(WebCore::UserMediaRequest::UserMediaRequest):
(WebCore::UserMediaRequest::audio):
(WebCore::UserMediaRequest::video):
(WebCore::UserMediaRequest::audioConstraints):
(WebCore::UserMediaRequest::videoConstraints):
* Modules/mediastream/UserMediaRequest.h:
(WebCore):
(UserMediaRequest):
* platform/chromium/support/WebMediaConstraints.cpp:
(WebKit::WebMediaConstraints::WebMediaConstraints):
(WebKit):

Source/WebKit/chromium:

http://dev.w3.org/2011/webrtc/editor/getusermedia.html#navigatorusermedia
Navigator.getUserMedia is changed so that the audio and video members can either
be a bool or a constraints object.

* public/WebUserMediaRequest.h:
(WebKit):
(WebUserMediaRequest):
* src/WebUserMediaRequest.cpp:
(WebKit::WebUserMediaRequest::audioConstraints):
(WebKit):
(WebKit::WebUserMediaRequest::videoConstraints):

Tools:

Adding mock support for the enhanced getUserMedia call.

* DumpRenderTree/DumpRenderTree.gypi:
* DumpRenderTree/chromium/MockConstraints.cpp: Copied from Source/WebCore/platform/chromium/support/WebMediaConstraints.cpp.
(MockConstraints):
(MockConstraints::isSupported):
(MockConstraints::isValid):
(MockConstraints::verify):
* DumpRenderTree/chromium/MockConstraints.h: Copied from Tools/DumpRenderTree/chromium/WebUserMediaClientMock.h.
(WebKit):
(MockConstraints):
* DumpRenderTree/chromium/MockWebRTCPeerConnectionHandler.cpp:
(RTCSessionDescriptionRequestSuccededTask::RTCSessionDescriptionRequestSuccededTask):
(RTCSessionDescriptionRequestFailedTask::RTCSessionDescriptionRequestFailedTask):
(RTCVoidRequestTask::RTCVoidRequestTask):
(MockWebRTCPeerConnectionHandler::initialize):
* DumpRenderTree/chromium/WebUserMediaClientMock.cpp:
(UserMediaRequestTask):
(UserMediaRequestTask::UserMediaRequestTask):
(WebUserMediaClientMock::requestUserMedia):
* DumpRenderTree/chromium/WebUserMediaClientMock.h:
(WebUserMediaClientMock):
(WebUserMediaClientMock::taskList):
* DumpRenderTree/chromium/WebViewHost.h:
(WebKit):
(WebViewHost):

LayoutTests:

Expanding tests to cover the new getUserMedia behaviour.

* fast/mediastream/getusermedia-expected.txt:
* fast/mediastream/getusermedia.html:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129517 268f45cc-cd09-0410-ab3c-d52691b4dbfc
#undef some symbols before redefining them.
https://bugs.webkit.org/show_bug.cgi?id=97568.

Reviewed by Michael Saboff.

* wtf/Platform.h:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129519 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed GTK gardening.

Removing failure expectations for a few passing reftests and reclassifying
one reftest as flaky.

* platform/gtk/TestExpectations:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129520 268f45cc-cd09-0410-ab3c-d52691b4dbfc
committers-autocomplete.js works only with WebKit based browsers
https://bugs.webkit.org/show_bug.cgi?id=66752

Patch by Peter Gal <galpeter@inf.u-szeged.hu> on 2012-09-25
Reviewed by Darin Adler.

Modified the code do only add event listeners to the given inputs,
and not to the full document.

* committers-autocomplete.js:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129521 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Chromium] Android's build archives have grown from 38M to 102M in 11 days
https://bugs.webkit.org/show_bug.cgi?id=97336

Reviewed by Adam Barth.

Each WebKit target results in four APKs in the out/{Debug,Release}/ directory,
while we really only need one. Ignoring the unsigned APKs removes six from
the archive will make sure that we only archive a single APK per target,
bringing its size back to rougly 40 megabytes.

* BuildSlaveSupport/built-product-archive:
(archiveBuiltProduct):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129522 268f45cc-cd09-0410-ab3c-d52691b4dbfc
GIFImageReader: fix tautological compare
https://bugs.webkit.org/show_bug.cgi?id=97563

Reviewed by Adam Barth.

The frame_reader->disposal_method field is of type
ImageFrame::FrameDisposalMethod, which has a range of 0--3. Therefore,
recent versions of Clang concludes that the expression
frame_reader->disposal_method == 4
will never be true, and warns about it.

This patch fixes the code by doing the comparison before storing the
value in the enum.

No new functionality, no new tests.

* platform/image-decoders/gif/GIFImageReader.cpp:
(GIFImageReader::read):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129523 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Reverting implementation for 407 error pages
https://bugs.webkit.org/show_bug.cgi?id=97455

Patch by commit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc> on 2012-09-25
Reviewed by Rob Buis.

Adding additional fixes to NetworkJob since BlackBerry::Platform::Client
is no longer avaliable. Using BlackBerryPlatformSettings to get proxy
information instead.

BlackBerryPlatformClient was deleted in PR 170160.

* platform/network/blackberry/NetworkJob.cpp:
(WebCore::NetworkJob::sendRequestWithCredentials):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129524 268f45cc-cd09-0410-ab3c-d52691b4dbfc
CSP paths: Ignore invalid path components, rather than dropping the source completely.
https://bugs.webkit.org/show_bug.cgi?id=97538

Patch by Mike West <mkwst@google.com> on 2012-09-25
Reviewed by Adam Barth.

Source/WebCore:

Content Security Policy directives that accept source lists currently
handle soure URI paths containing '?' or '#' in a draconian fashion by
dropping the entire source expression. We should be slightly friendlier,
and ignore simply the portion of the source expression that we know to
be invalid, just as we previously ignored everything after and including
a '/' in source expressions before we supported paths.

The new behavior is covered by existing tests, and two test-cases added
to http/tests/security/contentSecurityPolicy/source-list-parsing-paths-02.html.

* page/ContentSecurityPolicy.cpp:
(WebCore::CSPSourceList::parsePath):
    Report an error to the console, rather than ignoring a path that
    contains an invalid fragment or query.
(WebCore::ContentSecurityPolicy::reportInvalidPathCharacter):
(WebCore):
* page/ContentSecurityPolicy.h:
    Add a new warning type to cover this case.

LayoutTests:

* http/tests/security/contentSecurityPolicy/source-list-parsing-05-expected.txt:
* http/tests/security/contentSecurityPolicy/source-list-parsing-06-expected.txt:
    Updating to the new error message.
* http/tests/security/contentSecurityPolicy/source-list-parsing-paths-02-expected.txt:
* http/tests/security/contentSecurityPolicy/source-list-parsing-paths-02.html:
    Adding new tests to check that valid paths followed by '?' or '#'
    drop the invalid component, but remain valid sources.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129525 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Qt] PageViewportController: Consolidate positionRangeForViewportAtScale and boundPosition
https://bugs.webkit.org/show_bug.cgi?id=97222

Reviewed by Kenneth Rohde Christiansen.

Those methods are used together everywhere, merge them into a single
clampViewportToContents method.

* UIProcess/PageViewportController.cpp:
(WebKit::PageViewportController::innerBoundedViewportScale):
(WebKit::PageViewportController::outerBoundedViewportScale):
(WebKit::PageViewportController::clampViewportToContents):
(WebKit):
(WebKit::PageViewportController::pageDidRequestScroll):
(WebKit::PageViewportController::syncVisibleContents):
* UIProcess/PageViewportController.h:
(PageViewportController):
(WebKit):
* UIProcess/qt/PageViewportControllerClientQt.cpp:
(WebKit::PageViewportControllerClientQt::focusEditableArea):
(WebKit::PageViewportControllerClientQt::zoomToAreaGestureEnded):
(WebKit::PageViewportControllerClientQt::nearestValidVisibleContentsRect):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129526 268f45cc-cd09-0410-ab3c-d52691b4dbfc
AX: Chromium doesn't pass accessibility text range and line number tests
https://bugs.webkit.org/show_bug.cgi?id=97246

Reviewed by Chris Fleizach.

Source/WebCore:

Adds a method to get all line breaks at once, so retrieving all
line breaks isn't an O(n^2) operation for Chromium.

Enables four existing tests to pass on Chromium:
Tests: accessibility/textarea-insertion-point-line-number.html
       accessibility/textarea-line-for-index.html
       accessibility/textarea-selected-text-range.html
       accessibility/textbox-role-reports-selection.html

* accessibility/AccessibilityObject.h:
(WebCore::AccessibilityObject::lineBreaks):
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::lineBreaks):
(WebCore):
* accessibility/AccessibilityRenderObject.h:
(AccessibilityRenderObject):

Source/WebKit/chromium:

Use improved implementation of AccessibilityRenderObject::lineBreaks
and implement methods to get the line number of the selection and
to set the text range.

Enables four existing tests to pass on Chromium:
Tests: accessibility/textarea-insertion-point-line-number.html
       accessibility/textarea-line-for-index.html
       accessibility/textarea-selected-text-range.html
       accessibility/textbox-role-reports-selection.html

* public/WebAccessibilityObject.h:
(WebAccessibilityObject):
* src/WebAccessibilityObject.cpp:
(WebKit::WebAccessibilityObject::selectionEndLineNumber):
(WebKit):
(WebKit::WebAccessibilityObject::selectionStartLineNumber):
(WebKit::WebAccessibilityObject::setSelectedTextRange):
(WebKit::WebAccessibilityObject::lineBreaks):

Tools:

Provide a chromium implementation of some AccessibilityUIElement
methods needed by accessibility tests.

Enables four existing tests to pass on Chromium:
Tests: accessibility/textarea-insertion-point-line-number.html
       accessibility/textarea-line-for-index.html
       accessibility/textarea-selected-text-range.html
       accessibility/textbox-role-reports-selection.html

* DumpRenderTree/chromium/TestRunner/AccessibilityUIElementChromium.cpp:
(AccessibilityUIElement::insertionPointLineNumberGetterCallback):
(AccessibilityUIElement::selectedTextRangeGetterCallback):
(AccessibilityUIElement::lineForIndexCallback):
(AccessibilityUIElement::setSelectedTextRangeCallback):

LayoutTests:

Enables four tests on chromium:
Tests: accessibility/textarea-insertion-point-line-number.html
       accessibility/textarea-line-for-index.html
       accessibility/textarea-selected-text-range.html
       accessibility/textbox-role-reports-selection.html

* platform/chromium/TestExpectations:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129527 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Handling required for multiple consecutive whitespace
https://bugs.webkit.org/show_bug.cgi?id=97575

Patch by Nima Ghanavatian <nghanavatian@rim.com> on 2012-09-25
Reviewed by Rob Buis.

PR211670
Need specific handling in the case where we have multiple
consecutive whitespaces which exceeds our character limit. This
breaks some of the functionality employed with the visible_units
methods used here to tranverse the text.

Internally reviewed by Mike Fenton.

* WebKitSupport/DOMSupport.cpp:
(BlackBerry::WebKit::DOMSupport::trimWhitespaceFromRange):
(DOMSupport):
(BlackBerry::WebKit::DOMSupport::isEmptyRangeOrAllSpaces):
* WebKitSupport/DOMSupport.h:
(WebCore):
* WebKitSupport/InputHandler.cpp:
(BlackBerry::WebKit::InputHandler::spellCheckBlock):
(BlackBerry::WebKit::InputHandler::getRangeForSpellCheckWithFineGranularity):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129528 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] REGRESSION: Incorrect preferred width calculation for table cells
https://bugs.webkit.org/show_bug.cgi?id=97497

Reviewed by Levi Weintraub.

Source/WebCore: 

In fixing bug 93911 r125694 caused a problem with the preferred
width calculations for table cells with a fractional padding
where the logic to ensure that the cell is wide enough for the
content returns different results for cells with a fixed width
and cells with an automatic width.

Test: fast/sub-pixel/table-cells-have-stable-width.html

* rendering/AutoTableLayout.cpp:
(WebCore::AutoTableLayout::recalcColumn):
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::computePreferredLogicalWidths):
Move the logic that ensures that a cell is wide enough from AutoTableLayout::recalcColumn to RenderBlock::computePreferredLogicalWidths to. This way it also applies to FixedTableLayout which had the same problem.

LayoutTests: 

Added test for cell width calculation and reverted three svg tests to the results prior to r125694.

* fast/sub-pixel/table-cells-have-stable-width-expected.txt: Added.
* fast/sub-pixel/table-cells-have-stable-width.html: Added.
* platform/chromium-linux/svg/zoom/page/zoom-img-preserveAspectRatio-support-1-expected.png:
* platform/chromium-linux/svg/zoom/page/zoom-img-preserveAspectRatio-support-1-expected.txt:
* platform/chromium-linux/svg/zoom/page/zoom-svg-through-object-with-absolute-size-expected.png:
* platform/chromium-linux/svg/zoom/page/zoom-svg-through-object-with-absolute-size-expected.txt:
* platform/chromium-linux/svg/zoom/page/zoom-svg-through-object-with-percentage-size-expected.png:
* platform/chromium-win/svg/zoom/page/zoom-svg-through-object-with-percentage-size-expected.txt:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129529 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CSS Exclusions] Enable css exclusions for multiple blocks per element
https://bugs.webkit.org/show_bug.cgi?id=89993

Patch by Bear Travis <betravis@adobe.com> on 2012-09-25
Reviewed by Julien Chaffraix.

Source/WebCore:

Similar to multi-column layout, a parent RenderBlock's WrapShapeInfo may affect
the inline content of its children. This patch follows the example of ColumnInfo
and adds WrapShapeInfo to LayoutState, which tracks the current shape-inside that
inline content should respect.

Tests: fast/exclusions/shape-inside/shape-inside-multiple-blocks.html
       fast/exclusions/shape-inside/shape-inside-multiple-blocks-vertical.html

* rendering/LayoutState.cpp:
(WebCore::LayoutState::LayoutState): Initialize m_wrapShapeInfo.
* rendering/LayoutState.h:
(WebCore):
(WebCore::LayoutState::LayoutState): Initialize m_wrapShapeInfo.
(LayoutState):
(WebCore::LayoutState::wrapShapeInfo): Getter for m_wrapShapeInfo.
* rendering/RenderBlockLineLayout.cpp:
(WebCore::LineWidth::LineWidth): Use LayoutState to lookup WrapShapeInfo.
(WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Ditto.
(WebCore::RenderBlock::layoutRunsAndFloatsInRange): Ditto.
* rendering/RenderView.h:
(WebCore::RenderView::pushLayoutState): Push LayoutState if a WrapShapeInfo
is present.

LayoutTests:

Adding tests to cover the case where a shape-inside affects block children's
inline content.

* fast/exclusions/shape-inside/shape-inside-multiple-blocks-expected.html: Added.
* fast/exclusions/shape-inside/shape-inside-multiple-blocks-vertical-expected.html: Added.
* fast/exclusions/shape-inside/shape-inside-multiple-blocks-vertical.html: Added.
* fast/exclusions/shape-inside/shape-inside-multiple-blocks.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129530 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Build fix, GeolocationClientMock should not be included by WebProcess InjectedBundle

Unreviewed.

The patch r129252 removes the dependencies on GeolocationClientMock, r129444 removes
GeolocationClientMock from the Mac port. The #include breaks new Mac build.

* WebProcess/InjectedBundle/InjectedBundle.cpp:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129531 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed, rolling out r129517.
http://trac.webkit.org/changeset/129517
https://bugs.webkit.org/show_bug.cgi?id=97582

Link errors in chromium (Requested by alecf on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-09-25

Source/Platform:

* chromium/public/WebMediaConstraints.h:
(WebMediaConstraints):

Source/WebCore:

* Modules/mediastream/MediaConstraintsImpl.cpp:
* Modules/mediastream/MediaConstraintsImpl.h:
* Modules/mediastream/NavigatorMediaStream.cpp:
(WebCore::NavigatorMediaStream::webkitGetUserMedia):
* Modules/mediastream/UserMediaRequest.cpp:
(WebCore::UserMediaRequest::create):
(WebCore::UserMediaRequest::UserMediaRequest):
* Modules/mediastream/UserMediaRequest.h:
(WebCore):
(UserMediaRequest):
(WebCore::UserMediaRequest::audio):
(WebCore::UserMediaRequest::video):
* platform/chromium/support/WebMediaConstraints.cpp:

Source/WebKit/chromium:

* public/WebUserMediaRequest.h:
(WebUserMediaRequest):
* src/WebUserMediaRequest.cpp:

Tools:

* DumpRenderTree/DumpRenderTree.gypi:
* DumpRenderTree/chromium/MockConstraints.cpp: Removed.
* DumpRenderTree/chromium/MockConstraints.h: Removed.
* DumpRenderTree/chromium/MockWebRTCPeerConnectionHandler.cpp:
(RTCSessionDescriptionRequestSuccededTask::RTCSessionDescriptionRequestSuccededTask):
(RTCSessionDescriptionRequestFailedTask::RTCSessionDescriptionRequestFailedTask):
(RTCVoidRequestTask::RTCVoidRequestTask):
(isSupportedConstraint):
(isValidConstraint):
(MockWebRTCPeerConnectionHandler::initialize):
* DumpRenderTree/chromium/WebUserMediaClientMock.cpp:
(WebKit::WebUserMediaClientMock::requestUserMedia):
* DumpRenderTree/chromium/WebUserMediaClientMock.h:
(WebKit):
(WebUserMediaClientMock):
* DumpRenderTree/chromium/WebViewHost.h:
(WebKit):
(WebViewHost):

LayoutTests:

* fast/mediastream/getusermedia-expected.txt:
* fast/mediastream/getusermedia.html:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129532 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Don't kill automatically the web process when the ui process finishes
https://bugs.webkit.org/show_bug.cgi?id=97580

Reviewed by Martin Robinson.

We use prctl(PR_SET_PDEATHSIG, SIGKILL); in linux to make sure the
web process is killed when the UI process finishes. This is not
needed any more since now the web process stops the main loop when
the connection with the UI process is closed in
WebProcess::didClose(). This approach is better because it works
for any platform and makes the web process finish normally from
main().

* UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
(WebKit::childSetupFunction): Don't call prctl(PR_SET_PDEATHSIG,
SIGKILL) in the child process.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129533 268f45cc-cd09-0410-ab3c-d52691b4dbfc
IndexedDB: One transaction coordinator per database
https://bugs.webkit.org/show_bug.cgi?id=97501

Reviewed by Tony Chang.

Source/WebCore:

Per the IDB spec, transactions only need to be sequenced within databases.
The implementation was using one coordinator per factory backend (effectively
a singleton), which would prevent parallel execution of transactions in different
databases. Moved ownership of the transaction coordinator to the database backend.

Tests: storage/indexeddb/transaction-coordination-across-databases.html
       storage/indexeddb/transaction-readwrite-exclusive.html

* Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
(WebCore::IDBDatabaseBackendImpl::create):
(WebCore):
(WebCore::IDBDatabaseBackendImpl::IDBDatabaseBackendImpl):
* Modules/indexeddb/IDBDatabaseBackendImpl.h:
(IDBDatabaseBackendImpl):
* Modules/indexeddb/IDBFactoryBackendImpl.cpp:
(WebCore::IDBFactoryBackendImpl::deleteDatabase):
(WebCore::IDBFactoryBackendImpl::open):
* Modules/indexeddb/IDBFactoryBackendImpl.h:
(WebCore):
(IDBFactoryBackendImpl):
* Modules/indexeddb/IDBTransactionCoordinator.cpp:
(WebCore::IDBTransactionCoordinator::create):
(WebCore::IDBTransactionCoordinator::IDBTransactionCoordinator):
* Modules/indexeddb/IDBTransactionCoordinator.h:
(IDBTransactionCoordinator):

Source/WebKit/chromium:

Remove obsolete argument.

* tests/IDBDatabaseBackendTest.h:

LayoutTests:

Test that transactions can be parallelized across databases, and ensure that
read/write transactions with overlapping scopes are not parallelized within a
database.

* storage/indexeddb/resources/transaction-coordination-across-databases.js: Added.
* storage/indexeddb/resources/transaction-readwrite-exclusive.js: Added.
* storage/indexeddb/transaction-coordination-across-databases-expected.txt: Added.
* storage/indexeddb/transaction-coordination-across-databases.html: Added.
* storage/indexeddb/transaction-readwrite-exclusive-expected.txt: Added.
* storage/indexeddb/transaction-readwrite-exclusive.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129534 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Crash after clicking in plugin at kauaiexplorer.com
<rdar://problem/11525987/> and https://bugs.webkit.org/show_bug.cgi?id=90925

Patch by Akash Vaswani <avaswani@apple.com> on 2012-09-25
Reviewed by Sam Weinig.

Source/WebKit2:

Bug: Clicking the plugin to navigate away from the page caused the browser to crash.
     This is because it is possible for a beforeunload handler to destroy the plugin
     while it is still needed. In this case the handler set visibility to "none" and
     then accessed a property on the plugin script object. This forced a layout
     that destroyed the plugin.
Fix: Protecting PluginView objects until they are no longer required.
     This was done by adding a RefPtr at the beginning of performURLRequest()

* WebProcess/Plugins/PluginView.cpp:
(WebKit::PluginView::performURLRequest):

LayoutTests:

* http/tests/plugins/get-url-beforeunload-destroys-plugin-expected.txt: Added.
* http/tests/plugins/get-url-beforeunload-destroys-plugin.html: Added.
* http/tests/plugins/resources/notify-done.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129535 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Add missing support for Geolocation tests on WebKit2
https://bugs.webkit.org/show_bug.cgi?id=97518

Patch by Benjamin Poulain <bpoulain@apple.com> on 2012-09-25
Reviewed by Sam Weinig.

Source/WebKit2: 

The existing API for reporting error does not support passing and error message.

The interface UIProcess<->WebProcess is changed to take an error message, the
existing API now pass a null String, and the new function
WKGeolocationManagerProviderDidFailToDeterminePositionWithErrorMessage() provide
the extended support with error message.

* UIProcess/API/C/WKGeolocationManager.cpp:
(WKGeolocationManagerProviderDidFailToDeterminePositionWithErrorMessage):
* UIProcess/API/C/WKGeolocationManager.h:
* UIProcess/WebGeolocationManagerProxy.cpp:
(WebKit::WebGeolocationManagerProxy::providerDidFailToDeterminePosition):
* UIProcess/WebGeolocationManagerProxy.h:
(WebGeolocationManagerProxy):
* WebProcess/Geolocation/WebGeolocationManager.cpp:
(WebKit::WebGeolocationManager::didFailToDeterminePosition):
* WebProcess/Geolocation/WebGeolocationManager.h:
(WebGeolocationManager):
* WebProcess/Geolocation/WebGeolocationManager.messages.in:

Tools: 

There are two main features added to the tooling to make the test run:
-Add support for error reporting for position errors through setMockGeolocationPositionUnavailableError.
-Support the 3 states permission: undefined-allowed-denied.

* WebKitTestRunner/GeolocationProviderMock.cpp:
(WTR::GeolocationProviderMock::GeolocationProviderMock):
(WTR::GeolocationProviderMock::setPosition):
(WTR::GeolocationProviderMock::setPositionUnavailableError):
(WTR::GeolocationProviderMock::startUpdating):
(WTR::GeolocationProviderMock::sendPositionIfNeeded):
(WTR::GeolocationProviderMock::sendErrorIfNeeded):
* WebKitTestRunner/GeolocationProviderMock.h:
(GeolocationProviderMock):
* WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
* WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
(WTR::InjectedBundle::setMockGeolocationPositionUnavailableError):
* WebKitTestRunner/InjectedBundle/InjectedBundle.h:
(InjectedBundle):
* WebKitTestRunner/InjectedBundle/TestRunner.cpp:
(WTR::TestRunner::setMockGeolocationPositionUnavailableError):
* WebKitTestRunner/InjectedBundle/TestRunner.h:
(TestRunner):
* WebKitTestRunner/TestController.cpp:
(WTR::TestController::TestController):
(WTR::decidePolicyForGeolocationPermissionRequest):
(WTR::TestController::resetStateToConsistentValues):
(WTR::TestController::setGeolocationPermission):
(WTR::TestController::setMockGeolocationPosition):
(WTR::TestController::setMockGeolocationPositionUnavailableError):
(WTR::TestController::handleGeolocationPermissionRequest):
(WTR::TestController::decidePolicyForGeolocationPermissionRequestIfPossible):
* WebKitTestRunner/TestController.h:
(TestController):
* WebKitTestRunner/TestInvocation.cpp:
(WTR::TestInvocation::didReceiveMessageFromInjectedBundle):

LayoutTests: 

Unskip almost all the layout tests.

* platform/wk2/Skipped:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129536 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Webkit 1.8.2 fails to build with MinGW with spellchecking enabled
https://bugs.webkit.org/show_bug.cgi?id=93255

Patch by Paweł Forysiuk <tuxator@o2.pl> on 2012-09-25
Reviewed by Martin Robinson.

Build dies because of invalid cast. Additionaly word "interface" is in use with MinGW compiler.

* WebCoreSupport/TextCheckerClientGtk.cpp:
(WebKit::TextCheckerClientGtk::checkSpellingOfString): Use String to avoid unneded casting
* webkit/webkitspellcheckerenchant.cpp:
(webkit_spell_checker_enchant_spell_checker_interface_init): rename interface -> checkerInterface

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@129537 268f45cc-cd09-0410-ab3c-d52691b4dbfc