Accumulating LayoutUnits with floats for determining block preferred width can lead to wrapping
https://bugs.webkit.org/show_bug.cgi?id=93513

Reviewed by Eric Seidel.

Source/WebCore:

Sub-pixel values from floats are subject to small losses in precision when accumulated with
floating point values, as we do in RenderBlock. This patch adds a new method to FractionalLayoutUnit --
ceilToFloat -- which guarantees us a floating point value at least as big as our original LayoutUnit
value, and uses it along with ceiledLayoutUnit to avoid underprovisioning RenderBlock's preferred
widths due to lost precision.

Test: fast/sub-pixel/block-preferred-widths-with-sub-pixel-floats.html

* platform/FractionalLayoutUnit.h:
(WebCore::FractionalLayoutUnit::ceilToFloat): Returns a float value the same or larger than the
FractionalLayoutUnit value.
(FractionalLayoutUnit):
(WebCore::FractionalLayoutUnit::epsilon): Now returns 0 when sub-pixel is disabled.
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::computeLogicalLocationForFloat): Adding a LayoutUnit::epsilon fudge factor
for fitting floats. This is probably necessary due to precision being lost elsewhere.
(WebCore::RenderBlock::computeInlinePreferredLogicalWidths): Ensure no precision is lost due to conversion
when accumulating our min/max width with floats.

LayoutTests:

Ensuring floats with sub-pixel values don't unnecessarily wrap.

* fast/sub-pixel/block-preferred-widths-with-sub-pixel-floats-expected.txt: Added.
* fast/sub-pixel/block-preferred-widths-with-sub-pixel-floats.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125591 268f45cc-cd09-0410-ab3c-d52691b4dbfc
DOMWindow::document() should not reach through Frame
https://bugs.webkit.org/show_bug.cgi?id=27640

Reviewed by Eric Seidel.

Source/WebCore:

Originally, the lifetime of DOMWindow was similar to that of Frame in
that it was reused for each document that was displayed in the Frame.
To fix some tricky security issues, all modern browsers use a "split
window" architecture whereby the DOMWindow is not reused by each
Document in a Frame. Instead a JavaScript "window shell" object
redirects JavaScript references to the active Document's DOMWindow.

When we implemented split windows, we left DOMWindow attached to the
Frame and attempted to keep it in sync with the Document via a lot of
delicate code. One of the main problems with this approach is that
finding the DOMWindow associated with a Document or the Document
associated with a DOMWindow required traversing through the Frame.
Because there is a many-to-one relationship between both Documents and
Frames (as well as DOMWindows and Frames), this traversal is error
prone and not always available (e.g., for inactive documents).

This patch moves the "owning" reference for DOMWindow to Document so
that we can directly traverse from Document to DOMWindow. For
traversing from DOMWindow to Document, each DOMWindow keeps a Document
pointer via a ContextDestructionObserver base class.

The main sublties in this patch are related to situations in which
there isn't precisely a one-to-one relationship between Documents and
DOMWindows. Previously, these situations were handled implicitly by the
"flex and slop" of having separate Document and DOMWindow pointers in
Frame. In this patch, these sublties are made explicit via
Document::takeDOMWindowFrom, which explicitly transfers the DOMWindow
(as well as ASSERTs that all the relevant objects exist in a sensible
constellation).

* WebCore.exp.in:
    - These functions are no longer exported because they're inline.
* bindings/js/ScriptController.cpp:
(WebCore::ScriptController::clearWindowShell):
* bindings/js/ScriptController.h:
(ScriptController):
    - clearWindowShell now explicitly takes the new DOMWindow that will
      be pointed to by the WindowShell. Previously, clearWindowShell
      would implicitly create the new DOMWindow by accessing
      Frame::domWindow (which used to lazily create the DOMWindow).
* bindings/v8/BindingState.cpp:
(WebCore::currentDocument):
* bindings/v8/BindingState.h:
(WebCore):
    - currentDocument provides a directly path from the current
      v8::Context to the Document (by way of DOMWindow). Previously,
      code transited via the Frame using currentFrame.
* bindings/v8/ScriptController.cpp:
(WebCore::ScriptController::clearWindowShell):
* bindings/v8/ScriptController.h:
(ScriptController):
    - Mirror JSC changes to clearWindowShell.
* bindings/v8/V8Utilities.cpp:
(WebCore::getScriptExecutionContext):
    - Update getScriptExecutionContext to transit directly from the
      DOMWindow to the Document rather than detouring via the Frame.
* dom/ContextDestructionObserver.cpp:
(WebCore::ContextDestructionObserver::ContextDestructionObserver):
(WebCore::ContextDestructionObserver::~ContextDestructionObserver):
(WebCore):
(WebCore::ContextDestructionObserver::observeContext):
* dom/ContextDestructionObserver.h:
(ContextDestructionObserver):
    - When we transfer a DOMWindow from one Document to another, we
      need to update the Document pointer in the DOMWindow to point to
      the new Document. The DOMWindow holds the Document pointer via
      ContextDestructionObserver, so this patch teaches
      ContextDestructionObserver how to change which
      ScriptExecutionContext it is observing. This code mirrors similar
      code in FrameDestructionObserver.
* dom/Document.cpp:
(WebCore::Document::~Document):
(WebCore::Document::detach):
(WebCore::Document::createDOMWindow):
    - createDOMWindow now explicitly creates the DOMWindow. Previously,
      we created the DOMWindow implicitly in Frame::domWindow when it
      was first accessed.
(WebCore::Document::takeDOMWindowFrom):
    - takeDOMWindowFrom explicitly transfers the DOMWindow from one
      Document to another. The main benefit of this function is the
      ASSERTs that ensure that the Document, DOMWindow, and Frame all
      point to each other the correct configuration.
(WebCore::Document::didUpdateSecurityOrigin):
    - We no longer need to keep the SecurityOrigin pointer in DOMWindow
      in sync with the Document because DOMWindow no longer has a
      SecurityOrigin object.
* dom/Document.h:
(Document):
(WebCore::Document::domWindow):
* history/CachedFrame.cpp:
(WebCore::CachedFrame::CachedFrame):
(WebCore::CachedFrame::destroy):
* history/CachedFrame.h:
(CachedFrameBase):
    - Previously, CachedFrame held the Document and the DOMWindow with
      separate pointers. Now, the CachedFrame holds the DOMWnidow via
      the Document, which makes adding and removing Documents from the
      PageCache simpler because we don't need to keep the Frame's
      DOMWindow pointer synchronized.
* loader/DocumentWriter.cpp:
(WebCore::DocumentWriter::begin):
    - begin now explicitly creates the DOMWindow and transfers
      DOMWindow when performing a "secure transition." Previously, both
      of these processes were handled implicitly: the DOMWindow was
      created implicitly by Frame::domWindow, and the DOMWindow was
      reused during navigation by not clearing Frame::m_domWindow.
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::cancelAndClear):
(WebCore::FrameLoader::clear):
    - These functions now pass the new Document so that we have access
      to the new DOMWindow in clearDOMWindowShell.
(WebCore::FrameLoader::setOpener):
    - We no longer need to keep the DOMWindow's SecurityOrigin in sync
      with the Document's SecurityOrigin because DOMWindow no longer
      has a duplicate SecurityOrigin pointer.
(WebCore::FrameLoader::open):
    - We no longer need to keep the Frame::m_domWindow in sync with the
      Document because the Document carries its own DOMWindow.
* loader/FrameLoader.h:
(FrameLoader):
* page/DOMWindow.cpp:
(WebCore::DOMWindow::DOMWindow):
    - DOMWindow now uses Document as its primary context object. In a
      future patch, we should remove the FrameDestructionObserver base
      class and instead access the frame via DOMWindow::document().
(WebCore::DOMWindow::didSecureTransitionTo):
    - Notify the DOMWindow that it is now associated with a new
      Document.
(WebCore::DOMWindow::scriptExecutionContext):
(WebCore::DOMWindow::document):
(WebCore::DOMWindow::securityOrigin):
    - These functions now retrieve the Document directly rather than
      transiting via the Frame.
* page/DOMWindow.h:
(WebCore::DOMWindow::create):
(DOMWindow):
* page/Frame.cpp:
(WebCore::Frame::setDocument):
    - Add more ASSERTs that the Document and its DOMWindow are properly
      wired up to this Frame.
(WebCore::Frame::domWindow):
    - Rather than lazily creating the DOMWindow, this function now just
      accesses the already-created DOMWindow on Document. Eventually,
      all callers should retreive the DOMWindow from the Document
      directly.
* page/Frame.h:
(WebCore::Frame::existingDOMWindow):
    - The DOMWindow always exists, so there is no distinction between
      domWindow() and existingDOMWindow().
* xml/XMLHttpRequest.cpp:
(WebCore::XMLHttpRequest::open):
    - Previously, open would exit early if it was unable to find its
      ScriptExecutionContext (e.g., if the ScriptExecutionContext was
      inactive). Now we can always locate the ScriptExecutionContext
      and so we need to test whether the ScriptExecutionContext is
      still attached to the Page before accessing Settings. Tests
      verify that the platform-visible behaviors of XMLHttpRequest are
      unchanged, even for XMLHttpRequest constructors associated with
      inactive Documents.
* xml/XSLTProcessor.cpp:
(WebCore::XSLTProcessor::createDocumentFromSource):
    - Make it explicit that XSLT re-uses the DOMWindow from the source
      Document in the transformed Document.

LayoutTests:

* fast/dom/Window/timer-null-script-execution-context.html:
    - This test was assuming that we'd throw an exception when we
      failed to find the script execution context. Now that we are
      always able to find the script execution context, we never throw
      that exception, even after GC. As far as I can tell, the original
      intent of the test was to make sure we don't crash in that case,
      which of course we don't.
* fast/dom/xmlhttprequest-constructor-in-detached-document-expected.txt:
    - Remove warning message about not being able to find the script
      execution context. We can now always find the script execution
      context.
* http/tests/security/MessagePort/event-listener-context-expected.txt:
* http/tests/security/MessagePort/event-listener-context.html:
    - This test is attempting to check that MessagePorts behave in a
      reasonable way when created in inactive documents. The test
      relies on us throwing an exception in the inactive case because
      we're unable to find the script execution context. We are now
      able to find the script execution context (as above), so we no
      longer throw the exception. It's not clear whether this test is
      valuable any more, but I've converted it to be a test that we
      don't crash in this situation.
* platform/chromium/fast/dom/xmlhttprequest-constructor-in-detached-document-expected.txt: Removed.
    - Remove platform-specific result as it now matches the cross-platform result.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125592 268f45cc-cd09-0410-ab3c-d52691b4dbfc
WebKitTestRunner needs layoutTestController.dumpResourceLoadCallbacks
https://bugs.webkit.org/show_bug.cgi?id=42332

Patch by Mikhail Pozdnyakov <mikhail.pozdnyakov@intel.com> on 2012-08-14
Reviewed by Kenneth Rohde Christiansen.

Source/WebCore:

Provide build for mac.

* WebCore.exp.in: Added __ZNK7WebCore19ResourceRequestBase20firstPartyForCookiesEv.

Source/WebKit2:

Added new getters to WKURL, WKURLRequest, WKURLResponse so that it is possible
to dump information necessary for the tests passing.

* Shared/API/c/WKURL.cpp:
(WKURLCopyPath):
* Shared/API/c/WKURL.h:
* Shared/API/c/WKURLRequest.cpp:
(WKURLRequestCopyFirstPartyForCookies):
(WKURLRequestCopyHTTPMethod):
* Shared/API/c/WKURLRequest.h:
* Shared/API/c/WKURLResponse.cpp:
(WKURLResponseHTTPStatusCode):
* Shared/API/c/WKURLResponse.h:
* Shared/WebURL.h:
(WebKit::WebURL::path):
(WebURL):

Tools:

Added Resource Callbacks logging. Several aux dumping functions are added.

* WebKitTestRunner/InjectedBundle/Bindings/LayoutTestController.idl:
* WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
(WTR::isFileScheme):
(WTR):
(WTR::pathSuitableForTestResult):
(WTR::urlSuitableForTestResult):
(WTR::InjectedBundlePage::resetAfterTest):
(WTR::dumpRequestDescriptionSuitableForTestResult):
(WTR::dumpResponseDescriptionSuitableForTestResult):
(WTR::dumpErrorDescriptionSuitableForTestResult):
(WTR::InjectedBundlePage::didInitiateLoadForResource):
(WTR::InjectedBundlePage::willSendRequestForFrame):
(WTR::InjectedBundlePage::didReceiveResponseForResource):
(WTR::InjectedBundlePage::didFinishLoadForResource):
(WTR::InjectedBundlePage::didFailLoadForResource):
* WebKitTestRunner/InjectedBundle/LayoutTestController.cpp:
(WTR::LayoutTestController::LayoutTestController):
* WebKitTestRunner/InjectedBundle/LayoutTestController.h:
(WTR::LayoutTestController::dumpResourceLoadCallbacks):
(WTR::LayoutTestController::shouldDumpResourceLoadCallbacks):
(LayoutTestController):

LayoutTests:

Unskipped correspondong test cases.

* platform/wk2/Skipped:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125593 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Update Test Expectations after r125578

       Unreviewed gardening.

       * platform/mac/TestExpectations:
       * platform/qt/TestExpectations:
       * platform/efl/TestExpectations:
       * platform/gtk/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125594 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Mark css2.1/20110323/c541-word-sp-000.htm as failing on Windows Chromium
https://bugs.webkit.org/show_bug.cgi?id=94017

Unreviewed gardening. Expectation update.

* platform/chromium/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125595 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Update Test Expectations to consolidate bug refs for new tests added
with r125578.

Unreviewed gardening.

* platform/chromium/TestExpectations:
* platform/efl/TestExpectations:
* platform/gtk/TestExpectations:
* platform/mac/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125596 268f45cc-cd09-0410-ab3c-d52691b4dbfc
REGRESSION (r109851): Video controls do not render
https://bugs.webkit.org/show_bug.cgi?id=93859

Reviewed by Simon Fraser.

Source/WebCore:

Because video layers can't act as an ancestor composited layer whose
backing can be shared by child layers, any child layer of a video
layer needs to be put into its own composited layer. Because this is
technically overlap, the "overlap" indirect compositing reason is
reused for this case.

Test: compositing/video/video-controls-layer-creation.html

* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::computeCompositingRequirements):

LayoutTests:

Convert jernoble's test into a layout test.

* compositing/video/video-controls-layer-creation.html: Added.
* platform/chromium/TestExpectations:
* platform/mac/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125597 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Queue spellcheck requests with char-count limitations
https://bugs.webkit.org/show_bug.cgi?id=93866

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

PR184196
Making spellcheck a little more granular so as to work around
the limitations of the inputservice.
Also, spellcheck the entire field on focus only if
spellcheck="on" is explicitly set.

Internally reviewed by Mike Fenton.

* WebKitSupport/InputHandler.cpp:
(BlackBerry::WebKit::InputHandler::requestCheckingOfString):
(BlackBerry::WebKit::InputHandler::spellCheckingRequestProcessed):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125598 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Web Inspector: Render breakpoint gutter markers and execution line in CodeMirrorTextEditor
https://bugs.webkit.org/show_bug.cgi?id=93686

Patch by Jan Keromnes <janx@linux.com> on 2012-08-14
Reviewed by Pavel Feldman.

Divided TextEditor.addDecoration into addBreakpoint, setExecutionLine
and addDecoration. Same for removeDecoration. Render breakpoint
markers and execution line in CodeMirrorTextEditor.

* inspector/front-end/CodeMirrorTextEditor.js:
(WebInspector.CodeMirrorTextEditor):
(WebInspector.CodeMirrorTextEditor.prototype._onGutterClick):
(WebInspector.CodeMirrorTextEditor.prototype.addBreakpoint):
(WebInspector.CodeMirrorTextEditor.prototype.removeBreakpoint):
(WebInspector.CodeMirrorTextEditor.prototype.setExecutionLine):
(WebInspector.CodeMirrorTextEditor.prototype.clearExecutionLine):
(WebInspector.CodeMirrorTextEditor.prototype.addDecoration):
(WebInspector.CodeMirrorTextEditor.prototype.removeDecoration):
(WebInspector.CodeMirrorTextEditor.prototype.highlightLine):
(WebInspector.CodeMirrorTextEditor.prototype.clearLineHighlight):
(WebInspector.CodeMirrorTextEditor.prototype.removeAttribute):
* inspector/front-end/DefaultTextEditor.js:
(WebInspector.DefaultTextEditor.prototype._onMouseDown):
(WebInspector.DefaultTextEditor.prototype.addBreakpoint):
(WebInspector.DefaultTextEditor.prototype.removeBreakpoint):
(WebInspector.DefaultTextEditor.prototype.setExecutionLine):
(WebInspector.DefaultTextEditor.prototype.clearExecutionLine):
(WebInspector.DefaultTextEditor.prototype.addDecoration):
(WebInspector.DefaultTextEditor.prototype.removeDecoration):
* inspector/front-end/JavaScriptSourceFrame.js:
(WebInspector.JavaScriptSourceFrame):
(WebInspector.JavaScriptSourceFrame.prototype._addBreakpointDecoration):
(WebInspector.JavaScriptSourceFrame.prototype._removeBreakpointDecoration):
(WebInspector.JavaScriptSourceFrame.prototype.setExecutionLine):
(WebInspector.JavaScriptSourceFrame.prototype.clearExecutionLine):
(WebInspector.JavaScriptSourceFrame.prototype._handleGutterClick):
* inspector/front-end/TextEditor.js:
(WebInspector.TextEditor.prototype.addBreakpoint):
(WebInspector.TextEditor.prototype.removeBreakpoint):
(WebInspector.TextEditor.prototype.setExecutionLine):
(WebInspector.TextEditor.prototype.clearExecutionLine):
(WebInspector.TextEditor.prototype.addDecoration):
(WebInspector.TextEditor.prototype.removeDecoration):
* inspector/front-end/cmdevtools.css:
(.CodeMirror):
(.cm-highlight):
(@-webkit-keyframes fadeout):
(to):
(.cm-breakpoint):
(.cm-breakpoint-disabled):
(.cm-breakpoint-conditional):
(.cm-execution-line):
(.webkit-html-message-bubble):
(.webkit-html-warning-message):
(.webkit-html-error-message):
(.webkit-html-message-line):
(.webkit-html-message-line-hover):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125599 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CSSRegions]regionOverset is computed as "overset" even though the region is not the last in the chain
https://bugs.webkit.org/show_bug.cgi?id=93102

Patch by Andrei Onea <onea@adobe.com> on 2012-08-14
Reviewed by Eric Seidel.

Source/WebCore:

Making Element.webkitRegionOverset return "overset" only for the last region in a region chain,
if the content cannot fit inside it, to reflect current spec. http://www.w3.org/TR/css3-regions/#dom-region-regionoverset

* rendering/RenderFlowThread.cpp:
(WebCore::RenderFlowThread::computeOverflowStateForRegions):

LayoutTests:

Modified existing tests to reflect spec, where Element.webkitRegionOverset can be
"overset" only for the last region in a region chain, if the content cannot fit inside it.

* fast/regions/element-region-overset-state-expected.txt:
* fast/regions/element-region-overset-state-vertical-rl-expected.txt:
* fast/regions/element-region-overset-state-vertical-rl.html:
* fast/regions/element-region-overset-state.html:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125600 268f45cc-cd09-0410-ab3c-d52691b4dbfc
REGRESSION r125500: 7 tests crashing on Mac bots
https://bugs.webkit.org/show_bug.cgi?id=93970

Reviewed by Eric Seidel.

Make WebFrameLoaderClient::redirectDataToPlugin expect the now real possibility
of a NULL pluginWidget argument.

* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::redirectDataToPlugin)


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125601 268f45cc-cd09-0410-ab3c-d52691b4dbfc
        [WK2] Track multiple Web Processes per context
        https://bugs.webkit.org/show_bug.cgi?id=93915

        Reviewed by Sam Weinig.

        * UIProcess/Downloads/DownloadProxy.cpp:
        (WebKit::DownloadProxy::didReceiveAuthenticationChallenge): Downloads don't work
        yet, added a FIXME.

        * UIProcess/WebContext.cpp:
        (WebKit::WebContext::deprecatedSharedProcess): Renamed from process(), added an
        assertion that this is only used in single proces mode.
        (WebKit::WebContext::textCheckerStateChanged): Abstract out access to web processes.
        (WebKit::WebContext::ensureSharedWebProcess): Renamed ensureWebProcess() for clarity.
        (WebKit::WebContext::createNewWebProcess): Extracted code for creating a process
        from ensureWebProcess().
        (WebKit::WebContext::warmInitialProcess): Create the process more explicitly.
        (WebKit::WebContext::enableProcessTermination): Iterate over all processes.
        (WebKit::WebContext::shouldTerminate): Updated assertion.
        (WebKit::WebContext::processDidFinishLaunching): Changed to use process argument
        instead of m_process.
        (WebKit::WebContext::disconnectProcess): Updated code forto use m_processes.
        (WebKit::WebContext::createWebPage): Handle both process policies (initial support
        for multi-process).
        (WebKit::WebContext::relaunchProcessIfNecessary): Added cases for both policies.
        (WebKit::WebContext::download): Ditto.
        (WebKit::WebContext::postMessageToInjectedBundle): Ditto.
        (WebKit::WebContext::didReceiveSyncMessage): Fixed whitespace.
        (WebKit::WebContext::getWebCoreStatistics): Added cases for both policies.

        * UIProcess/WebContext.h:
        (WebKit::WebContext::sendToAllProcesses):
        (WebKit::WebContext::sendToAllProcessesRelaunchingThemIfNecessary):
        Send to all processes. Changed return type to void, since no caller checked it.

        * UIProcess/WebProcessProxy.cpp: (WebKit::WebProcessProxy::createWebPage): Removed
        an assertion that assumed one process per context.

        * UIProcess/WebTextChecker.cpp: (WebKit::updateStateForAllWebProcesses): Updated
        to use a WebContext method.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125602 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Convert signals/slots to Q_* macros.

[Qt] Use Q_SLOTS and Q_SIGNALS instead of slots and signals
https://bugs.webkit.org/show_bug.cgi?id=93996

Patch by Lauro Neto <lauro.neto@openbossa.org> on 2012-08-14
Reviewed by Kenneth Rohde Christiansen.

Change usage of keyword-conflicting 'signals' and 'slots' for
Q_SIGNALS and Q_SLOTS macro.

Source/WebCore:

* bridge/testqtbindings.cpp:
(MyObject):
* platform/graphics/gstreamer/PlatformVideoWindowPrivate.h:
* platform/graphics/qt/MediaPlayerPrivateQt.h:
(MediaPlayerPrivateQt):
* platform/network/qt/DnsPrefetchHelper.h:
(DnsPrefetchHelper):
* platform/network/qt/NetworkStateNotifierPrivate.h:
(NetworkStateNotifierPrivate):
* platform/network/qt/QNetworkReplyHandler.h:
(QNetworkReplyHandler):
* platform/network/qt/QtMIMETypeSniffer.h:
(QtMIMETypeSniffer):
* platform/network/qt/SocketStreamHandlePrivate.h:
(SocketStreamHandlePrivate):
* platform/qt/GamepadsQt.cpp:
(GamepadDeviceLinuxQt):
(GamepadsQt):
* platform/qt/SharedTimerQt.cpp:
(SharedTimerQt):

Source/WebKit/qt:

* WebCoreSupport/FrameLoaderClientQt.h:
(FrameLoaderClientQt):
* WebCoreSupport/FullScreenVideoQt.h:
(FullScreenVideoQt):
* WebCoreSupport/FullScreenVideoWidget.h:
(FullScreenVideoWidget):
* WebCoreSupport/IconDatabaseClientQt.h:
(IconDatabaseClientQt):
* WebCoreSupport/InspectorClientQt.cpp:
(InspectorClientWebPage):
* WebCoreSupport/InspectorServerQt.h:
(InspectorServerQt):
(InspectorServerRequestHandlerQt):
* WebCoreSupport/PopupMenuQt.h:
(PopupMenuQt):
* WebCoreSupport/QtFallbackWebPopup.h:
(QtFallbackWebPopup):
* docs/webkitsnippets/qtwebkit_bridge_snippets.cpp:
(wrapInFunction):
* docs/webkitsnippets/webpage/main.cpp:
(Thumbnailer):
* examples/platformplugin/WebPlugin.h:
(Popup):
(WebPopup):
* tests/benchmarks/webgl/tst_webgl.cpp:
(tst_WebGlPerformance):
* tests/hybridPixmap/tst_hybridPixmap.cpp:
(tst_hybridPixmap):
* tests/hybridPixmap/widget.h:
(Widget):
* tests/qdeclarativewebview/tst_qdeclarativewebview.cpp:
(tst_QDeclarativeWebView):
* tests/qgraphicswebview/tst_qgraphicswebview.cpp:
(tst_QGraphicsWebView):
(WebPage):
(ResizeSpy):
* tests/qobjectbridge/tst_qobjectbridge.cpp:
(MyWebElementSlotOnlyObject):
(tst_QObjectBridge):
(TestPluginWidget):
* tests/qwebelement/tst_qwebelement.cpp:
(tst_QWebElement):
* tests/qwebframe/tst_qwebframe.cpp:
(tst_QWebFrame):
(FakeReply):
* tests/qwebhistory/tst_qwebhistory.cpp:
* tests/qwebhistoryinterface/tst_qwebhistoryinterface.cpp:
(tst_QWebHistoryInterface):
* tests/qwebinspector/tst_qwebinspector.cpp:
(tst_QWebInspector):
* tests/qwebpage/tst_qwebpage.cpp:
(tst_QWebPage):
(JSTestPage):
(RepaintRequestedRenderer):
(SpyForLoadSignalsOrder):
* tests/qwebplugindatabase/tst_qwebplugindatabase.cpp:
(tst_QWebPluginDatabase):
* tests/qwebview/tst_qwebview.cpp:
(tst_QWebView):
(WebViewCrashTest):

Source/WebKit2:

* UIProcess/API/qt/qwebkittest_p.h:
* UIProcess/API/qt/tests/inspectorserver/tst_inspectorserver.cpp:
(tst_InspectorServer):
* UIProcess/API/qt/tests/publicapi/tst_publicapi.cpp:
(tst_publicapi):
* UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp:
(tst_QQuickWebView):
* UIProcess/API/qt/tests/qrawwebview/tst_qrawwebview.cpp:
(WebView):
(tst_qrawwebview):
* UIProcess/API/qt/tests/util.cpp:
(LoadSpy):
* UIProcess/API/qt/tests/util.h:
(LoadStartedCatcher):
* UIProcess/InspectorServer/qt/WebSocketServerQt.h:
(QtTcpServerHandler):
* UIProcess/qt/QtDialogRunner.cpp:
(DialogContextBase):
(DialogContextObject):
(BaseAuthenticationContextObject):
(CertificateVerificationDialogContextObject):
(FilePickerContextObject):
(DatabaseQuotaDialogContextObject):
* UIProcess/qt/QtDialogRunner.h:
(QtDialogRunner):
* UIProcess/qt/QtWebPageEventHandler.h:
(QtWebPageEventHandler):
* WebProcess/Downloads/qt/QtFileDownloader.h:

Tools:

* DumpRenderTree/qt/DumpRenderTreeQt.h:
(NetworkAccessManager):
(WebPage):
* DumpRenderTree/qt/EventSenderQt.h:
(EventSender):
* DumpRenderTree/qt/GCControllerQt.h:
(GCController):
* DumpRenderTree/qt/TestRunnerQt.h:
(TestRunner):
* DumpRenderTree/qt/TextInputControllerQt.h:
(TextInputController):
* MiniBrowser/qt/BrowserWindow.h:
(BrowserWindow):
* MiniBrowser/qt/MiniBrowserApplication.h:
(WindowOptions):
* MiniBrowser/qt/UrlLoader.h:
(UrlLoader):
* QtTestBrowser/cookiejar.h:
(TestBrowserCookieJar):
* QtTestBrowser/fpstimer.h:
(FpsTimer):
* QtTestBrowser/launcherwindow.h:
(LauncherWindow):
* QtTestBrowser/locationedit.h:
(LocationEdit):
* QtTestBrowser/mainwindow.h:
(MainWindow):
* QtTestBrowser/urlloader.h:
(UrlLoader):
* QtTestBrowser/webinspector.h:
(WebInspector):
* QtTestBrowser/webpage.h:
(WebPage):
* QtTestBrowser/webview.h:
(WebViewGraphicsBased):
* WebKitTestRunner/InjectedBundle/qt/LayoutTestControllerQt.cpp:
(WatchdogTimerHelper):
* WebKitTestRunner/qt/PlatformWebViewQt.cpp:
(WrapperWindow):
* WebKitTestRunner/qt/main.cpp:
(Launcher):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125603 268f45cc-cd09-0410-ab3c-d52691b4dbfc
old-run-webkit-tests should skip all file extensions for ref tests, not just .html.
https://bugs.webkit.org/show_bug.cgi?id=93904

Patch by Roger Fong <roger_fong@apple.com> on 2012-08-14
Reviewed by Tim Horton.

old-run-webkit-tests ref test only skipped .html test.
They need to skip .html, .shtml, .xml, .xhtml, .pl, .htm, .php, .svg, .mht.

* Scripts/old-run-webkit-tests:
(isUsedInReftest): Skip all extensions for ref tests.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125604 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Don't crash on OOM in AC
https://bugs.webkit.org/show_bug.cgi?id=93999

Patch by Filip Spacek <fspacek@rim.com> on 2012-08-14
Reviewed by George Staikos.

Internally reviewed by George Staikos.

Fail gracefully in case we fail to allocate the bitmap
for the AC layer contents.

* platform/graphics/blackberry/InstrumentedPlatformCanvas.h:
(WebCore::InstrumentedPlatformCanvas::InstrumentedPlatformCanvas):
* platform/graphics/blackberry/LayerWebKitThread.cpp:
(WebCore::LayerWebKitThread::paintContents):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125605 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Rebaseline fast/box-sizing/box-sizing.html and compositing/overflow/clip-descendents.html.
https://bugs.webkit.org/show_bug.cgi?id=93909

Patch by Roger Fong <roger_fong@apple.com> on 2012-08-14
Reviewed by Tim Horton.

As per https://bugs.webkit.org/show_bug.cgi?id=92904 rebaselining those tests.

* compositing/overflow/clip-descendents-expected.txt: Rebaselined.
* platform/mac/TestExpectations: Removed tests from expectations list.
* platform/mac/fast/box-sizing/box-sizing-expected.txt: Rebaselined.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125606 268f45cc-cd09-0410-ab3c-d52691b4dbfc
beginElement() does not observe updated animation attributes
https://bugs.webkit.org/show_bug.cgi?id=93972

Reviewed by Dirk Schulze.

Source/WebCore:

The SVG animation attributes 'from', 'to' and 'by' should be registered as supported
SVGSMILElement attributes in order to trigger animationAttributeChanged() on dynamic
updates.

Test: svg/animations/updated-attributes.html

* svg/SVGAnimationElement.cpp:
(WebCore::SVGAnimationElement::updateAnimation):
Minor optimization - avoid recalculating animationMode().

* svg/animation/SVGSMILElement.cpp:
(WebCore::SVGSMILElement::isSupportedAttribute):
Register 'from', 'to' and 'by' as supported SVGSMILElement attributes.

LayoutTests:

* svg/animations/updated-attributes-expected.txt: Added.
* svg/animations/updated-attributes.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125608 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Remove unnecessary \n's from InputHandler log messages.
https://bugs.webkit.org/show_bug.cgi?id=94015

Reviewed by Rob Buis.

Remove many unnecessary \n's from the end of log messages.

Reviewed Internally by Nima Ghanavatian.

* WebKitSupport/InputHandler.cpp:
(BlackBerry::WebKit::convertStringToWcharVector):
(BlackBerry::WebKit::convertSpannableStringToString):
(BlackBerry::WebKit::InputHandler::spannableTextInRange):
(BlackBerry::WebKit::InputHandler::setText):
(BlackBerry::WebKit::InputHandler::setSpannableTextAndRelativeCursor):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125609 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CSSRegions]Region overset property is incorectly computed when content has negative letter spacing and is flowed near to the edge of a region
https://bugs.webkit.org/show_bug.cgi?id=92506

Patch by Andrei Onea <onea@adobe.com> on 2012-08-14
Reviewed by Eric Seidel.

Source/WebCore:

When the content which is flowed inside a region creates visual overflow in
the writing direction, the overflow rect is also extended in the other direction, and
that forces regionOverset to become "fit" for all regions.

Tests: fast/regions/element-region-overset-state-negative-letter-spacing.html
       fast/regions/element-region-overset-state-vertical-rl-negative-letter-spacing.html

* rendering/RenderFlowThread.cpp:
(WebCore::RenderFlowThread::computeOverflowStateForRegions):

LayoutTests:

Added tests for incorrect regionOverset computation when visual overflow in the writing direction creates
overset for all regions.

* fast/regions/element-region-overset-state-negative-letter-spacing-expected.txt: Added.
* fast/regions/element-region-overset-state-negative-letter-spacing.html: Added.
* fast/regions/element-region-overset-state-vertical-rl-negative-letter-spacing-expected.txt: Added.
* fast/regions/element-region-overset-state-vertical-rl-negative-letter-spacing.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125610 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Checkerboard flashes on Go Back
https://bugs.webkit.org/show_bug.cgi?id=94018

Patch by Leo Yang <leoyang@rim.com> on 2012-08-14
Reviewed by Yong Li.
Reviewed internally by Yong Li.

The backing store need to be suspended before the
WebPagePrivate::restoreHistoryViewState() is called to avoid UI thread
drawing checkerboard.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::restoreHistoryViewState):
* WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
(WebCore::FrameLoaderClientBlackBerry::restoreViewState):

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