webkit:qtwebkit.git
6 years ago2011-06-15 Diego Gonzalez <diegohcg@webkit.org>
Diego Gonzalez [Wed, 15 Jun 2011 15:08:23 +0000 (15:08 +0000)]
2011-06-15  Diego Gonzalez  <diegohcg@webkit.org>

        Reviewed by Kenneth Rohde Christiansen.

        [Qt] Inconsistent behavior on a form submit request...
        https://bugs.webkit.org/show_bug.cgi?id=45523

        The inconsistency occurs when a form submission requests a new window.
        Two windows are opened (instead of only one) and the first window is opened
        as a blank page.

        By default each page is put into their own unique page group, which affects popup windows
        and visited links. Page groups (per process only) is a feature making it possible to use
        separate settings for each group, so that for instance an integrated browser/email reader
        can use different settings for displaying HTML pages and HTML email. To make QtWebKit work
        as expected out of the box, we use a default group similar to what other ports are doing.

        * Api/qwebpage.cpp:

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

6 years ago2011-06-14 Andreas Kling <kling@webkit.org>
Andreas Kling [Tue, 14 Jun 2011 13:42:40 +0000 (13:42 +0000)]
2011-06-14  Andreas Kling  <kling@webkit.org>

        Reviewed by Benjamin Poulain.

        [Qt] Don't include convenience "QWebFoo" headers in WebKit code.
        https://bugs.webkit.org/show_bug.cgi?id=62632

        * WebCoreSupport/FrameNetworkingContextQt.cpp:

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

6 years ago2011-06-13 Jeffrey Pfau <jpfau@apple.com>
commit-queue [Mon, 13 Jun 2011 23:20:47 +0000 (23:20 +0000)]
2011-06-13  Jeffrey Pfau  <jpfau@apple.com>

        Reviewed by Darin Adler.

        Crash in WebCore::RenderMathMLUnderOver::layout()
        https://bugs.webkit.org/show_bug.cgi?id=57900

        Added a test that tries to remove the children of munder, mover and munderover elements.

        * mathml/munderover-remove-children-expected.txt: Added.
        * mathml/munderover-remove-children.html: Added.
2011-06-13  Jeffrey Pfau  <jpfau@apple.com>

        Reviewed by Darin Adler.

        Crash in WebCore::RenderMathMLUnderOver::layout()
        https://bugs.webkit.org/show_bug.cgi?id=57900

        Add more null checks so that removing children in MathML elements does not cause crashes.
        Note that this only half fixes the third repro in the Bugzilla bug, as another bug will
        still crash that repro.

        Test: mathml/munderover-remove-children.html

        * rendering/mathml/RenderMathMLSubSup.cpp:
        (WebCore::RenderMathMLSubSup::stretchToHeight):
        * rendering/mathml/RenderMathMLUnderOver.cpp:
        (WebCore::RenderMathMLUnderOver::layout):
        (WebCore::RenderMathMLUnderOver::nonOperatorHeight):

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

6 years ago2011-06-13 Ryosuke Niwa <rniwa@webkit.org>
Ryosuke Niwa [Mon, 13 Jun 2011 20:46:24 +0000 (20:46 +0000)]
2011-06-13  Ryosuke Niwa  <rniwa@webkit.org>

        Reviewed by Dan Bernstein.

        REGRESSION (r81518): Crash in makeRange() when invoking the dictionary panel over a file input
        https://bugs.webkit.org/show_bug.cgi?id=62544

        Fixed the crash by adding null pointer checks.

        No new tests since there's no way to open dictionary panel.

        * dom/Position.cpp:
        (WebCore::Position::parentAnchoredEquivalent):
        * editing/VisiblePosition.cpp:
        (WebCore::makeRange):
        * page/Frame.cpp:
        (WebCore::Frame::rangeForPoint):

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

6 years ago2011-06-14 Caio Marcelo de Oliveira Filho <caio.oliveira@openbossa.org>
Ademar de Souza Reis Jr [Tue, 14 Jun 2011 14:32:55 +0000 (11:32 -0300)]
2011-06-14  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] tst_QWebFrame::overloadedSlots() fails
        https://bugs.webkit.org/show_bug.cgi?id=37319

        Increase the likeness that JSElements are converted to QWebElements. When hinted
        with QWebElement metatype, we qualify the conversion from JSElement as a "perfect
        match".

        The test was failing because the wrong slot was called, since the QWebElement
        match was taken as equal to the others and not chosen when the metacall happened.

        We also remove the implicit conversion between JSDocument (which is not an
        element) to QWebElement. The conversion only worked for calling slots, while
        without hint it returned a QVariantMap (as can be seen in domCycles test). It was
        added for supporting DRT, but since this change we can use it as QVariantMap and
        get the value for "documentElement".

        This patch is based on Noam Rosenthal original patch in the same bug.

        * bridge/qt/qt_runtime.cpp:
        (JSC::Bindings::hintForRealType):
        Extracted function to choose the metatype hint based on the JSValue type.  Add
        QWebElement metatype as a hint for JSElement objects, this way if no hint is
        provided, JSElement objects will always be converted to QWebElements.

        (JSC::Bindings::convertValueToQVariant):
        Use previous function. Identify the conversion between JSElement to QWebElement
        as a "perfect match" (dist = 0). And remove the implicit conversion when the hint
        is QWebElement metatype and we have a JSDocument.  Changed from JSHTMLElement to
        JSElement to cover the 'documentElement'.
2011-06-14  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] tst_QWebFrame::overloadedSlots() fails
        https://bugs.webkit.org/show_bug.cgi?id=37319

        Since the implicit conversion was removed, change support functions of DRT to
        expect a QVariantMap instead of a QWebElement. This matches the exposed function
        in the controller, which takes 'document' and not 'document.documentElement'.

        And now that Element -> QWebElement is a perfect match, we must use QWebElement
        instead of QVariantMap, like in plainText().

        * WebCoreSupport/DumpRenderTreeSupportQt.h:
        * WebCoreSupport/DumpRenderTreeSupportQt.cpp:
        (DumpRenderTreeSupportQt::plainText): Fix to use QWebElement instead of
        QVariantMap when getting the startContainer. Also use QVariantMap directly,
        bridge will do conversion for us now.

        (getCoreDocumentFromVariantMap): Extracts the WebCore::Document* from the
        QVariantMap that Qt bridge gives us when 'document' is passed from JS.

        (DumpRenderTreeSupportQt::nodesFromRect): Use helper function.

        * tests/qwebframe/tst_qwebframe.cpp: Splitted the test domCycles() into two
        different tests. In practice, the original test just checked whether we could
        create a QVariantMap representing 'document' without infinite looping due to
        cycles in the DOM. This was more evident before since we haven't a conversion
        from JSElement to QWebElement, but from JSElement to QVariantMap.

        (tst_QWebFrame::documentHasDocumentElement): Evaluates 'document' and extracts
        'documentElement' from it. Compares to QWebFrame::documentElement().

        (tst_QWebFrame::documentAllHasDocumentElement): Look inside 'document.all' for
        the documentElement.

        (tst_QWebFrame::overloadedSlots): Remove expected failure and fix wrong comment.
2011-06-14  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] tst_QWebFrame::overloadedSlots() fails
        https://bugs.webkit.org/show_bug.cgi?id=37319

        Since we don't implictly convert 'document' object to QWebElement
        in metacalls anymore, change the controller to expect QVariantMap instead.

        The method plainText() was updated to use QVariantMap as well to let the bridge
        do the conversion directly for us.

        * DumpRenderTree/qt/LayoutTestControllerQt.cpp:
        (LayoutTestController::nodesFromRect):
        * DumpRenderTree/qt/LayoutTestControllerQt.h:
        * DumpRenderTree/qt/PlainTextControllerQt.cpp:
        (PlainTextController::plainText):
        * DumpRenderTree/qt/PlainTextControllerQt.h:

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

Conflicts:

Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.h

6 years ago<rdar://problem/9513180> REGRESSION (r84166): recalcStyle for display:inline to displ... qtwebkit-2.2-week23
Dan Bernstein [Sun, 12 Jun 2011 18:27:00 +0000 (18:27 +0000)]
<rdar://problem/9513180> REGRESSION (r84166): recalcStyle for display:inline to display:none transition has complexity N^2 where N is the number of child Text nodes
https://bugs.webkit.org/show_bug.cgi?id=61557

Reviewed by Darin Adler.

Replaced the fix for bug 58500 with a refined version.

* rendering/RenderText.cpp:
(WebCore::RenderText::clippedOverflowRectForRepaint): Use the containing block unless it is
across a layer boundary.

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

6 years ago2011-06-10 Abhishek Arya <inferno@chromium.org>
Abhishek Arya [Sat, 11 Jun 2011 16:37:59 +0000 (16:37 +0000)]
2011-06-10  Abhishek Arya  <inferno@chromium.org>

        Reviewed by Simon Fraser.

        Null parent element sheet pointers in CSSMutableStyleDeclaration consumers
        when removed from document, set them when reinserted into document.
        https://bugs.webkit.org/show_bug.cgi?id=62230

        When a HTMLBodyElement, StyledElement are removed from document,
        we didn't clear out the parent pointers from their link, style declarations.
        These parent pointers pointed to the document's element sheet which will
        get removed when document is getting destroyed. It does make sense to
        clear out parent pointers when we are getting removed from document and
        readd them when we get inserted again.

        Tests: fast/dom/body-link-decl-parent-crash.html
               fast/dom/styled-inline-style-decl-parent-crash.html

        * dom/StyledElement.cpp:
        (WebCore::StyledElement::insertedIntoDocument):
        (WebCore::StyledElement::removedFromDocument):
        * dom/StyledElement.h:
        * html/HTMLBodyElement.cpp:
        (WebCore::HTMLBodyElement::parseMappedAttribute):
        (WebCore::HTMLBodyElement::insertedIntoDocument):
        (WebCore::HTMLBodyElement::removedFromDocument):
        (WebCore::HTMLBodyElement::didMoveToNewOwnerDocument):
        * html/HTMLBodyElement.h:
2011-06-10  Abhishek Arya  <inferno@chromium.org>

        Reviewed by Simon Fraser.

        Tests that accessing the parent element sheet of an inline style, link
        declaration of styled, body elements which are removed from document,
        does not result in crash.
        https://bugs.webkit.org/show_bug.cgi?id=62230

        * fast/dom/body-link-decl-parent-crash-expected.txt: Added.
        * fast/dom/body-link-decl-parent-crash.html: Added.
        * fast/dom/styled-inline-style-decl-parent-crash-expected.txt: Added.
        * fast/dom/styled-inline-style-decl-parent-crash.html: Added.

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

6 years ago2011-06-10 Abhishek Arya <inferno@chromium.org>
Abhishek Arya [Fri, 10 Jun 2011 17:31:29 +0000 (17:31 +0000)]
2011-06-10  Abhishek Arya  <inferno@chromium.org>

        Reviewed by Tony Gentilcore.

        Tests that trying to remove all document children while building a svg <use>
        element shadow and instance tree does not result in crash.
        https://bugs.webkit.org/show_bug.cgi?id=62225

        * svg/dom/use-style-recalc-script-execute-crash-expected.txt: Added.
        * svg/dom/use-style-recalc-script-execute-crash.html: Added.
2011-06-10  James Simonsen  <simonjam@chromium.org>

        Reviewed by Tony Gentilcore.

        Don't execute scripts in shadow SVG.
        https://bugs.webkit.org/show_bug.cgi?id=62225

        Test: svg/dom/use-style-recalc-script-execute-crash.html

        * dom/ScriptElement.cpp:
        (WebCore::ScriptElement::prepareScript):

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

6 years agoCalling WebKitBlobBuilder.append with null argument should not crash
Jian Li [Fri, 10 Jun 2011 01:09:11 +0000 (01:09 +0000)]
Calling WebKitBlobBuilder.append with null argument should not crash
https://bugs.webkit.org/show_bug.cgi?id=62419

Reviewed by David Levin.

Source/WebCore:

Test: fast/files/blob-builder-crash.html

* fileapi/WebKitBlobBuilder.cpp:
(WebCore::WebKitBlobBuilder::append):

LayoutTests:

* fast/files/blob-builder-crash-expected.txt: Added.
* fast/files/blob-builder-crash.html: Added.

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

6 years agoBug 62405 - Fix integer overflow in Array.prototype.push
Gavin Barraclough [Fri, 10 Jun 2011 00:30:21 +0000 (00:30 +0000)]
Bug 62405 - Fix integer overflow in Array.prototype.push

Reviewed by Geoff Garen.

Fix geoff's review comments re static_cast.

* runtime/ArrayPrototype.cpp:
(JSC::arrayProtoFuncPush):

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

6 years agoBug 62405 - Fix integer overflow in Array.prototype.push
Gavin Barraclough [Thu, 9 Jun 2011 23:46:54 +0000 (23:46 +0000)]
Bug 62405 - Fix integer overflow in Array.prototype.push

Reviewed by Oliver Hunt.

There are three integer overflows here, leading to safe (not a security risk)
but incorrect (non-spec-compliant) behaviour.

Two overflows occur when calculating the new length after pushing (one in the
fast version of push in JSArray, one in the generic version in ArrayPrototype).
The other occurs calculating indices to write to when multiple items are pushed.

These errors result in three test-262 failures.

Source/JavaScriptCore:

* runtime/ArrayPrototype.cpp:
(JSC::arrayProtoFuncPush):
* runtime/JSArray.cpp:
(JSC::JSArray::put):
(JSC::JSArray::push):

LayoutTests:

* sputnik/Conformance/15_Native_Objects/15.4_Array/15.4.4/15.4.4.7_Array_prototype_push/S15.4.4.7_A3-expected.txt:
* sputnik/Conformance/15_Native_Objects/15.4_Array/15.4.4/15.4.4.7_Array_prototype_push/S15.4.4.7_A4_T2-expected.txt:
* sputnik/Conformance/15_Native_Objects/15.4_Array/15.4.4/15.4.4.7_Array_prototype_push/S15.4.4.7_A4_T3-expected.txt:

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

6 years ago2011-06-09 Julien Chaffraix <jchaffraix@codeaurora.org>
commit-queue [Thu, 9 Jun 2011 20:33:20 +0000 (20:33 +0000)]
2011-06-09  Julien Chaffraix  <jchaffraix@codeaurora.org>

        Reviewed by Antti Koivisto.

        REGRESSION(84329): Stylesheets on some pages do not load
        https://bugs.webkit.org/show_bug.cgi?id=61400

        Adding test to cover the regression. The test actually uncovered
        a bug in the way we handle alternate stylesheet and thus is
        failing some parts.

        * fast/css/link-disabled-attr-expected.txt: Added.
        * fast/css/link-disabled-attr.html: Added.
2011-06-09  Julien Chaffraix  <jchaffraix@codeaurora.org>

        Reviewed by Antti Koivisto.

        REGRESSION(84329): Stylesheets on some pages do not load
        https://bugs.webkit.org/show_bug.cgi?id=61400

        Test: fast/css/link-disabled-attr.html

        Fixed r84329: the change did not take into account the fact
        that HTMLLinkElement did already contain the disabled information
        and the 2 information were not linked as they should have!

        The new logic pushes the information to the stylesheet as this
        is what the spec mandates and what FF is doing. Also it keeps
        one bit of information (that JS enabled the stylesheet) as it
        is needed for the recalcStyleSelector logic.

        * dom/Document.cpp:
        (WebCore::Document::recalcStyleSelector): s/isDisabled/disabled.

        * html/HTMLLinkElement.cpp:
        (WebCore::HTMLLinkElement::HTMLLinkElement): Removed m_disabledState,
        replaced by m_isEnabledViaScript.
        (WebCore::HTMLLinkElement::setDisabled): Updated the logic after
        m_disabledState removal. It also matches the spec by forwarding
        the disabled state to our stylesheet if we have one.
        (WebCore::HTMLLinkElement::parseMappedAttribute): Removed harmful
        handling of the disabledAttr.
        (WebCore::HTMLLinkElement::process): Updated after m_disabledState removal.
        * html/HTMLLinkElement.h:
        (WebCore::HTMLLinkElement::isEnabledViaScript): Ditto.
        (WebCore::HTMLLinkElement::isAlternate): Ditto.

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

6 years ago2011-06-10 Andreas Kling <kling@webkit.org>
Andreas Kling [Fri, 10 Jun 2011 11:31:23 +0000 (11:31 +0000)]
2011-06-10  Andreas Kling  <kling@webkit.org>

        Reviewed by Benjamin Poulain.

        [Qt] Fix 'headers' autotest when building inside Qt.
        https://bugs.webkit.org/show_bug.cgi?id=62449

        * Api/qwebkitplatformplugin.h:

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

6 years ago2011-06-09 Simon Fraser <simon.fraser@apple.com>
Simon Fraser [Thu, 9 Jun 2011 20:05:51 +0000 (20:05 +0000)]
2011-06-09  Simon Fraser  <simon.fraser@apple.com>

        Reviewed by Darin Adler.

        Crashes in RenderLayerBacking::paintingGoesToWindow
        https://bugs.webkit.org/show_bug.cgi?id=61159

        Speculative fix for unreproducible crash that can occur when RenderObject::repaintUsingContainer()
        finds a repaintContainer that is not the RenderView, but that is also not
        composited (for unknown reasons), by checking to see if the layer is
        compositing before using backing(). An assertion remains to try to catch
        this in debug builds.

        * rendering/RenderLayer.cpp:
        (WebCore::RenderLayer::setBackingNeedsRepaintInRect):

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

6 years ago2011-06-09 Julien Chaffraix <jchaffraix@webkit.org>
Julien Chaffraix [Thu, 9 Jun 2011 19:52:27 +0000 (19:52 +0000)]
2011-06-09  Julien Chaffraix  <jchaffraix@webkit.org>

        Reviewed by Darin Adler.

        Test for WebCore::WebKitCSSKeyframesRuleInternal::nameAttrSetter() - crash
        https://bugs.webkit.org/show_bug.cgi?id=62384

        * fast/css/webkit-keyframes-crash-expected.txt: Added.
        * fast/css/webkit-keyframes-crash.html: Added.
2011-06-09  Julien Chaffraix  <jchaffraix@webkit.org>

        Reviewed by Darin Adler.

        WebCore::WebKitCSSKeyframesRuleInternal::nameAttrSetter() - crash
        https://bugs.webkit.org/show_bug.cgi?id=62384

        Test: fast/css/webkit-keyframes-crash.html

        * css/WebKitCSSKeyframesRule.cpp:
        (WebCore::WebKitCSSKeyframesRule::setName): stylesheet() is never garanteed
        to return a non-null pointer. Thus null-check here like the rest of the code.

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

6 years ago2011-06-08 Adam Barth <abarth@webkit.org>
Adam Barth [Thu, 9 Jun 2011 00:34:13 +0000 (00:34 +0000)]
2011-06-08  Adam Barth  <abarth@webkit.org>

        Reviewed by Eric Seidel.

        Use after free in WebCore::ContainerNode::parserAddChild
        https://bugs.webkit.org/show_bug.cgi?id=62160

        Test that we don't trigger asserts when re-entering the parser from
        tree construction.

        * fast/parser/document-write-onload-nesting-expected.txt: Added.
        * fast/parser/document-write-onload-nesting.html: Added.
        * fast/parser/document-write-onload-ordering-expected.txt: Added.
        * fast/parser/document-write-onload-ordering.html: Added.
            - The exact ordering of the script execution here differs a bit
              between browsers.  For example, Firefox executes the scripts in a
              slightly different order because Firefox runs the parser on a
              separate thread (and therefore cannot be re-entered from tree
              construction). If/when we move the parser off the main thread,
              we're likely to change the ordering here a bit, which should be
              ok.
2011-06-08  Adam Barth  <abarth@webkit.org>

        Reviewed by Eric Seidel.

        constructTreeFromToken can re-enter parser, causing ASSERTs
        https://bugs.webkit.org/show_bug.cgi?id=62160

        This patch clears the HTMLToken before constructing the tree from the
        token, putting the HTMLDocumentParser in a good state to be re-entered.

        Tests: fast/parser/document-write-onload-nesting.html
               fast/parser/document-write-onload-ordering.html

        * html/parser/HTMLDocumentParser.cpp:
        (WebCore::HTMLDocumentParser::pumpTokenizer):
        * html/parser/HTMLToken.h:
        (WebCore::HTMLToken::isUninitialized):
        * html/parser/HTMLTreeBuilder.cpp:
        (WebCore::HTMLTreeBuilder::constructTreeFromToken):

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

6 years ago2011-06-09 Andras Becsi <abecsi@webkit.org>
Andras Becsi [Thu, 9 Jun 2011 16:05:08 +0000 (16:05 +0000)]
2011-06-09  Andras Becsi  <abecsi@webkit.org>

        Reviewed by Andreas Kling.

        [Qt] Fix the in-tree build on Linux
        https://bugs.webkit.org/show_bug.cgi?id=62378

        In case of an in-tree build qmake generates defect prl dependencies for
        the QtWebKit library, because the inclusion of qtbase.pri adds explicitlib to CONFIG.

        * QtWebKit.pro: Remove explicitlib and staticlib from CONFIG.

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

6 years ago2011-06-08 Ademar de Souza Reis Jr. <ademar.reis@openbossa.org>
Ademar de Souza Reis Junior [Wed, 8 Jun 2011 17:14:30 +0000 (17:14 +0000)]
2011-06-08  Ademar de Souza Reis Jr.  <ademar.reis@openbossa.org>

        Reviewed by Andreas Kling.

        Webkit on SPARC Solaris has wrong endian
        https://bugs.webkit.org/show_bug.cgi?id=29407

        Bug 57256 fixed one crash on misaligned reads on sparc/solaris, but
        there are more ocurrences of the same code pattern in webkit.

        This patch includes the check on these other parts of the code.

        This is a speculative fix, I don't have a sparc machine to test and
        don't know which kind of test would trigger a crash (but it's quite
        obvious that it's the same code duplicated in different files).

        * runtime/UString.h:
        (JSC::UStringHash::equal):
        * wtf/text/StringHash.h:
        (WTF::StringHash::equal):

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

6 years ago2011-06-08 Yael Aharon <yael.aharon@nokia.com>
Yael Aharon [Wed, 8 Jun 2011 15:28:27 +0000 (15:28 +0000)]
2011-06-08  Yael Aharon  <yael.aharon@nokia.com>

        Reviewed by Andreas Kling.

        [Qt] Build fix for building QtWebKit inside of Qt.
        https://bugs.webkit.org/show_bug.cgi?id=62280

        Remove CONFIG=staticlib, because it causes the configure script to add -ljavascriptcore
        into QtWebKit.prl.

        No new tests, as this is just a build fix.

        * JavaScriptCore.pri:
2011-06-08  Yael Aharon  <yael.aharon@nokia.com>

        Reviewed by Andreas Kling.

        [Qt] Build fix for building QtWebKit inside of Qt.
        https://bugs.webkit.org/show_bug.cgi?id=62280

        Remove CONFIG=staticlib, because it causes the configure script to add -lwebcore
        into QtWebKit.prl.

        No new tests, as this is just a build fix.

        * WebCore.pri:
2011-06-08  Yael Aharon  <yael.aharon@nokia.com>

        Reviewed by Andreas Kling.

        [Qt] Build fix for building QtWebKit inside of Qt.
        https://bugs.webkit.org/show_bug.cgi?id=62280

        Remove CONFIG=staticlib, because it causes the configure script to add -lwebkit2
        into QtWebKit.prl.

        * WebKit2.pri:

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

6 years ago2011-06-08 Andreas Kling <kling@webkit.org>
Andreas Kling [Wed, 8 Jun 2011 12:52:34 +0000 (12:52 +0000)]
2011-06-08  Andreas Kling  <kling@webkit.org>

        Reviewed by Benjamin Poulain.

        [Qt] FrameLoaderClient: Check Vector::find() return value for WTF::notFound.
        https://bugs.webkit.org/show_bug.cgi?id=62274

        Vector::find() returns size_t (which is unsigned), so we should check
        for WTF::notFound instead of -1.

        * WebCoreSupport/FrameLoaderClientQt.cpp:
        (WebCore::FrameLoaderClientQt::createPlugin):

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

6 years ago2011-06-08 Andreas Kling <andreas.kling@nokia.com>
Ademar de Souza Reis Jr [Wed, 8 Jun 2011 14:41:31 +0000 (11:41 -0300)]
2011-06-08  Andreas Kling  <andreas.kling@nokia.com>

        Reviewed by Laszlo Gombos.

        [Symbian] Float{32,64}Array and Int16Array fail to build.
        https://bugs.webkit.org/show_bug.cgi?id=62219

        For some reason, RVCT 2.x is moaning about "class member designated by
        a using-declaration must be visible in a direct base class".
        Apply same fix as r69122 and r76592.

        * html/canvas/Float32Array.h:
        (WebCore::Float32Array::set):
        * html/canvas/Float64Array.h:
        (WebCore::Float64Array::set):
        * html/canvas/Int16Array.h:
        (WebCore::Int16Array::set):

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

Conflicts:

Source/WebCore/html/canvas/Float64Array.h

6 years ago2011-06-07 Yi Shen <yi.4.shen@nokia.com>
Yi Shen [Wed, 8 Jun 2011 02:44:35 +0000 (02:44 +0000)]
2011-06-07  Yi Shen  <yi.4.shen@nokia.com>

        Reviewed by Simon Hausmann.

        [Qt] Fix the error code for media resource failures when using QtMobility
        https://bugs.webkit.org/show_bug.cgi?id=55901

        Unskip the tests which are now passing.

        * platform/qt/Skipped:
2011-06-07  Yi Shen  <yi.4.shen@nokia.com>

        Reviewed by Simon Hausmann.

        [Qt] Fix the error code for media resource failures when using QtMobility
        https://bugs.webkit.org/show_bug.cgi?id=55901

        To indicate the media resource failures, set the network state to
        MediaPlayer::FormatError when receives QMediaPlayer::InvalidMedia or
        QMediaPlayer::ResourceError.

        * platform/graphics/qt/MediaPlayerPrivateQt.cpp:
        (WebCore::MediaPlayerPrivateQt::updateStates):

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

6 years ago2011-06-07 Aravind Akella <aravind.akella@nokia.com>
commit-queue@webkit.org [Tue, 7 Jun 2011 19:17:41 +0000 (19:17 +0000)]
2011-06-07  Aravind Akella  <aravind.akella@nokia.com>

        Reviewed by Laszlo Gombos.

        [Qt][Symbian] API test failure qdeclarativewebview
        https://bugs.webkit.org/show_bug.cgi?id=59481

        QML files cannot be loaded on Symbian due to difference
        in capabilities between qmlwebkitplugin.dll and Qtwebkit.dll.
        A PlatSec error that Qtwebkit.dll has "DRM AllFiles" capabilities
        missing is observed when dynamically loading the QML plugin.

        * declarative/declarative.pro: Match capabilities in QtWebKit.pro.
        * symbian/platformplugin/platformplugin.pro: Match capabilities with the other 2 DLLs.
        Also remove TARGET.VID from platformplugin, as it's not used in any other Qt WebKit DLL,
        and causes build warnings about undefined VENDOR_VID.
        * tests/tests.pri: Add WriteDeviceData capability for API tests.

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

6 years ago2011-06-07 Andreas Kling <andreas.kling@nokia.com>
Andreas Kling [Tue, 7 Jun 2011 13:22:31 +0000 (13:22 +0000)]
2011-06-07  Andreas Kling  <andreas.kling@nokia.com>

        Reviewed by Laszlo Gombos.

        [Qt] Fix Symbian build with RVCT 2.x
        https://bugs.webkit.org/show_bug.cgi?id=62205

        RVCT 2.x doesn't support (or need) the --signed_bitfields command-line
        option, so restrict it to version 4.x of the compiler.

        * Source/WebKit.pri:

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

6 years ago2011-06-05 Igor Oliveira <igor.oliveira@openbossa.org> qtwebkit-2.2-week22
commit-queue [Sun, 5 Jun 2011 18:34:07 +0000 (18:34 +0000)]
2011-06-05  Igor Oliveira  <igor.oliveira@openbossa.org>

        Reviewed by Kenneth Rohde Christiansen.

        fast/viewport/viewport-45.html fails in GTK+/Qt
        https://bugs.webkit.org/show_bug.cgi?id=47481

        Rebaseline tests.

        * fast/viewport/viewport-45-expected.txt:
        * fast/viewport/viewport-86-expected.txt:
        * platform/qt/Skipped:
2011-06-05  Igor Oliveira  <igor.oliveira@openbossa.org>

        Reviewed by Kenneth Rohde Christiansen.

        fast/viewport/viewport-45.html fails in GTK+/Qt
        https://bugs.webkit.org/show_bug.cgi?id=47481

        computeViewportAttributes does many math operations with float point arithmetic
        and in some cases there is loss of precision making tests have incorrect values.

        * dom/ViewportArguments.cpp:
        (WebCore::computeViewportAttributes):

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

6 years agoSkip fast/forms/selectlist-minsize.html on mac
Ademar de Souza Reis Jr [Mon, 6 Jun 2011 16:59:01 +0000 (13:59 -0300)]
Skip fast/forms/selectlist-minsize.html on mac

New test introduced in r88029, but fails on Qt-Mac. Also skipped in
trunk by r88141.

6 years agoSkip editing/pasteboard tests on mac which are failing on QtWebKit-2.2
Ademar de Souza Reis Jr [Mon, 6 Jun 2011 16:49:31 +0000 (13:49 -0300)]
Skip editing/pasteboard tests on mac which are failing on QtWebKit-2.2

5 editing/pasteboard tests are failing on our 2.2 mac bots because
their actual results are including meta tags like this:

<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

Disabling them for now.

6 years ago[Qt] Implement download feature for QtTestBrowser
Csaba Osztrogonác [Mon, 6 Jun 2011 14:52:19 +0000 (14:52 +0000)]
[Qt] Implement download feature for QtTestBrowser
https://bugs.webkit.org/show_bug.cgi?id=61865

Buildfix for --minimal and CONFIG+=qt_minimal build after r88161.

* QtTestBrowser/launcherwindow.cpp:
(LauncherWindow::LauncherWindow):
* QtTestBrowser/launcherwindow.h:

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

6 years ago2011-06-06 Barát Tibor <Barat.Tibor@stud.u-szeged.hu>
commit-queue [Mon, 6 Jun 2011 13:19:23 +0000 (13:19 +0000)]
2011-06-06  Barát Tibor  <Barat.Tibor@stud.u-szeged.hu>

        Reviewed by Csaba Osztrogonác.

        [Qt] Implement download feature for QtTestBrowser
        https://bugs.webkit.org/show_bug.cgi?id=61865

        * QtTestBrowser/launcherwindow.cpp:
        (LauncherWindow::LauncherWindow):
        (LauncherWindow::downloadRequest):
        (LauncherWindow::fileDownloadFinished):
        * QtTestBrowser/launcherwindow.h:

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

6 years ago2011-06-04 Abhishek Arya <inferno@chromium.org>
Ademar de Souza Reis Jr [Mon, 6 Jun 2011 14:46:15 +0000 (11:46 -0300)]
2011-06-04  Abhishek Arya  <inferno@chromium.org>

        Reviewed by Kent Tamura.

        Add some asserts for array boundary checks in TextRun. Fix
        an integer issue in linux text controller code.
        https://bugs.webkit.org/show_bug.cgi?id=62085

        Testing ComplexTextControllerLinux change requires a testcase
        > 32 kb which is not feasible. All other changes are tested by
        existing layouttests.

        * platform/graphics/TextRun.h:
        (WebCore::TextRun::operator[]): add assert.
        (WebCore::TextRun::data): add assert.
        * platform/graphics/WidthIterator.cpp:
        (WebCore::WidthIterator::advance): bail early and prevent access
        to one byte across the text run boundary.
        * platform/graphics/chromium/ComplexTextControllerLinux.cpp:
        (WebCore::ComplexTextController::getNormalizedTextRun): wrong
        int16 vs int comparison.
        * rendering/svg/SVGTextRunRenderingContext.cpp:
        (WebCore::SVGTextRunWalker::walk): bail early when from and to
        is outside the text run boundary. this hit easily after adding
        the assert when from = to = end and read in run.data(from).

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

Conflicts:

Source/WebCore/rendering/svg/SVGTextRunRenderingContext.cpp

6 years ago2011-06-04 Jeffrey Pfau <jpfau@apple.com>
commit-queue [Sat, 4 Jun 2011 10:32:26 +0000 (10:32 +0000)]
2011-06-04  Jeffrey Pfau  <jpfau@apple.com>

        Reviewed by Beth Dakin.

        Crash in WebCore::RenderMathMLSubSup::baselinePosition()
        https://bugs.webkit.org/show_bug.cgi?id=57897

        Added simple test that hits the relevant code.

        * mathml/msubsup-remove-children-expected.txt: Added.
        * mathml/msubsup-remove-children.xhtml: Added.
2011-06-04  Jeffrey Pfau  <jpfau@apple.com>

        Reviewed by Beth Dakin.

        Crash in WebCore::RenderMathMLSubSup::baselinePosition()
        https://bugs.webkit.org/show_bug.cgi?id=57897

        Simple patch adding NULL checks in each function.
        Test: mathml/msubsup-remove-children.xhtml

        * rendering/mathml/RenderMathMLSubSup.cpp:
        (WebCore::RenderMathMLSubSup::stretchToHeight):
        (WebCore::RenderMathMLSubSup::baselinePosition):

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

6 years ago2011-06-03 Rafael Brandao <rafael.lobo@openbossa.org>
commit-queue [Fri, 3 Jun 2011 21:53:04 +0000 (21:53 +0000)]
2011-06-03  Rafael Brandao  <rafael.lobo@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] It made two Qt API tests fail
        https://bugs.webkit.org/show_bug.cgi?id=58847

        Modified failing test's base url so it could get a valid origin
        and make use of local storage. Also added another test that checks
        local storage visibility in both scenarios.

        * tests/qwebpage/tst_qwebpage.cpp:
        (tst_QWebPage::testOptionalJSObjects):
        (checkLocalStorageVisibility):
        (tst_QWebPage::testLocalStorageVisibility):

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

6 years ago2011-06-03 Alexis Menard <alexis.menard@openbossa.org>
Alexis Menard [Fri, 3 Jun 2011 21:02:07 +0000 (21:02 +0000)]
2011-06-03  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] Warning fixes on comparisons between a signed and an unsigned.

        * WebCoreSupport/DumpRenderTreeSupportQt.cpp:
        (DumpRenderTreeSupportQt::computedStyleIncludingVisitedInfo):
        (DumpRenderTreeSupportQt::nodesFromRect):

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

6 years ago2011-06-03 Alexis Menard <alexis.menard@openbossa.org>
alexis.menard@openbossa.org [Fri, 3 Jun 2011 20:32:47 +0000 (20:32 +0000)]
2011-06-03  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Andreas Kling.

        To support building namespaced Qt, we require that forward-declarations
        of Qt classes be wrapped in QT_BEGIN_NAMESPACE and QT_END_NAMESPACE.

        * WebCoreSupport/FrameLoaderClientQt.h:
2011-06-03  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Andreas Kling.

        To support building namespaced Qt, we require that forward-declarations
        of Qt classes be wrapped in QT_BEGIN_NAMESPACE and QT_END_NAMESPACE.

        * platform/network/qt/QtMIMETypeSniffer.h:

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

6 years ago2011-06-03 Alexis Menard <alexis.menard@openbossa.org>
Alexis Menard [Fri, 3 Jun 2011 20:07:53 +0000 (20:07 +0000)]
2011-06-03  Alexis Menard  <alexis.menard@openbossa.org>

        Unreviewed build fix after r87902.

        To support building namespaced Qt, we require that forward-declarations
        of Qt classes be wrapped in QT_BEGIN_NAMESPACE and QT_END_NAMESPACE but
        only on classes inside Qt.

        * WebCoreSupport/DumpRenderTreeSupportQt.h:

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

6 years ago2011-06-03 Alexis Menard <alexis.menard@openbossa.org>
alexis.menard@openbossa.org [Fri, 3 Jun 2011 19:18:09 +0000 (19:18 +0000)]
2011-06-03  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Benjamin Poulain.

        Some warning fixes. Values in switch not handled, and
        a comparison between a signed and an unsigned.

        * Api/qwebpage.cpp:
        (QWebPagePrivate::inputMethodEvent):
        (QWebPagePrivate::dynamicPropertyChangeEvent):
        (QWebPage::action):

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

6 years ago2011-06-01 Dirk Pranke <dpranke@chromium.org>
Dirk Pranke [Wed, 1 Jun 2011 21:09:05 +0000 (21:09 +0000)]
2011-06-01  Dirk Pranke  <dpranke@chromium.org>

        Reviewed by Tony Chang.

        nrwt: make webaudio work w/o content-length header
        https://bugs.webkit.org/show_bug.cgi?id=61819

        * Scripts/webkitpy/layout_tests/layout_package/printing.py:
        * Scripts/webkitpy/layout_tests/layout_package/single_test_runner.py:
        * Scripts/webkitpy/layout_tests/port/mock_drt.py:
        * Scripts/webkitpy/layout_tests/port/webkit.py:

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

6 years ago2011-06-01 Andras Becsi <abecsi@webkit.org>
Andras Becsi [Wed, 1 Jun 2011 18:16:14 +0000 (18:16 +0000)]
2011-06-01  Andras Becsi  <abecsi@webkit.org>

        Reviewed by Csaba Osztrogonác.

        [Qt] Fix the Phonon build when logging is disabled
        https://bugs.webkit.org/show_bug.cgi?id=61869

        No new tests needed.

        * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp: Add missing guards.
        (WebCore::MediaPlayerPrivatePhonon::networkState):
        (WebCore::MediaPlayerPrivatePhonon::readyState):
        (WebCore::MediaPlayerPrivatePhonon::updateStates):
        (WebCore::MediaPlayerPrivatePhonon::stateChanged):

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

6 years ago2011-05-31 Abhishek Arya <inferno@chromium.org>
Abhishek Arya [Tue, 31 May 2011 18:16:13 +0000 (18:16 +0000)]
2011-05-31  Abhishek Arya  <inferno@chromium.org>

        Reviewed by Dimitri Glazkov.

        Improve hasMediaControls logic to check that node has
        media controls. This can be false when cloning nodes.
        https://bugs.webkit.org/show_bug.cgi?id=61765

        Test: media/media-controls-clone-crash.html

        * dom/Node.h:
        (WebCore::Node::isMediaControls):
        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::mediaControls):
        (WebCore::HTMLMediaElement::hasMediaControls):
        * html/shadow/MediaControls.h:
        (WebCore::MediaControls::isMediaControls):
        (WebCore::toMediaControls):
2011-05-31  Abhishek Arya  <inferno@chromium.org>

        Reviewed by Dimitri Glazkov.

        Tests that cloning an audio element with media controls does
        not result in crash.
        https://bugs.webkit.org/show_bug.cgi?id=61765

        * media/media-controls-clone-crash-expected.txt: Added.
        * media/media-controls-clone-crash.html: Added.

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

6 years ago2011-05-30 Eric Carlson <eric.carlson@apple.com>
Eric Carlson [Tue, 31 May 2011 01:44:55 +0000 (01:44 +0000)]
2011-05-30  Eric Carlson  <eric.carlson@apple.com>

        Reviewed by Alexey Proskuryakov.

        Audio and video files saved to the Application Cache should preserve the original file extension
        https://bugs.webkit.org/show_bug.cgi?id=61750
        <rdar://9524922>

        No new tests, it isn't possible to check the name of the file in the cache from within
        DRT. Changes verified manually.

        * loader/appcache/ApplicationCacheStorage.cpp:
        (WebCore::ApplicationCacheStorage::store): Append the original file extension to the cache
            file name.
        (WebCore::ApplicationCacheStorage::writeDataToUniqueFileInDirectory): Add extension parameter.
        * loader/appcache/ApplicationCacheStorage.h:

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

6 years ago2011-05-30 Jer Noble <jer.noble@apple.com>
Ademar de Souza Reis Jr [Fri, 3 Jun 2011 19:54:02 +0000 (16:54 -0300)]
2011-05-30  Jer Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler and Simon Fraser.

        REGRESSION (r87622): Scrubbing a Vimeo movie when in fullscreen stops playback; no way to make it start again
        https://bugs.webkit.org/show_bug.cgi?id=61717
        rdar://problem/9522272

        May be some good way to test this later. No immediate idea about the best way.

        When a media element is taken into full-screen mode, stop events from propagating
        outside the media element's shadow DOM, EventDispatcher::determineDispatchBehavior()
        has been changed to take a shadow root node. In our full screen media element check,
        we check to see if the passed shadow root is the shadow root of the full screen media
        element, and if so, specify events should StayInsideShadowDOM. The end result is that
        inside EventDispatcher::ensureEventAncestors, an ancestor chain is built up all the
        way from the SliderThumb to the video element's shadow root, but no further.

        * dom/EventDispatcher.cpp:
        (WebCore::EventDispatcher::determineDispatchBehavior): Restrict events to the
        shadow DOM when showing a full screen video.

        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::HTMLMediaElement): Removed code to manage full screen controls.
        The events telling us about activity in the shadow DOM no longer bubble out so we need to
        handle this inside the shadow DOM on the root element.
        (WebCore::HTMLMediaElement::play): Ditto.
        (WebCore::HTMLMediaElement::playbackProgressTimerFired): Ditto.
        (WebCore::HTMLMediaElement::defaultEventHandler): Ditto.
        (WebCore::HTMLMediaElement::enterFullscreen): Ditto.
        (WebCore::HTMLMediaElement::exitFullscreen): Ditto.
        * html/HTMLMediaElement.h: Added isPlaying function, removed things moved to the root element.

        * html/shadow/MediaControlElements.cpp:
        (WebCore::MediaControlVolumeSliderContainerElement::defaultEventHandler): Rolled out
        changes that tried to make special rules for events using preDispatchEventHandler and such.
        This rolls out both r87622 and r87655.
        (WebCore::MediaControlMuteButtonElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlPanelMuteButtonElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlPlayButtonElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlSeekButtonElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlRewindButtonElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlReturnToRealtimeButtonElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlTimelineElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlVolumeSliderElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlFullscreenButtonElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlFullscreenVolumeMinButtonElement::defaultEventHandler): Ditto.
        (WebCore::MediaControlFullscreenVolumeMaxButtonElement::defaultEventHandler): Ditto.
        * html/shadow/MediaControlElements.h: Ditto.

        * html/shadow/MediaControlRootElement.cpp:
        (WebCore::MediaControlRootElement::MediaControlRootElement): Initialize new data members.
        (WebCore::MediaControlRootElement::playbackStarted): Start the timer so we will consider
        hiding the controls later.
        (WebCore::MediaControlRootElement::playbackProgressed): Hide the controls if the mouse
        is no longer over the controls.
        (WebCore::MediaControlRootElement::playbackStopped): Stop the timer since we only hide
        automatically if we're playing.
        (WebCore::MediaControlRootElement::enteredFullscreen): Start the timer.
        (WebCore::MediaControlRootElement::exitedFullscreen): Stop the timer since we only care
        if we are full screen.
        (WebCore::MediaControlRootElement::containsRelatedTarget): Added. Helper for next function.
        (WebCore::MediaControlRootElement::defaultEventHandler): Do the hide/show and timer functions
        as the mouse is moved in and out.
        (WebCore::MediaControlRootElement::startHideFullscreenControlsTimer): Start the timer if
        needed.
        (WebCore::MediaControlRootElement::hideFullscreenControlsTimerFired): Hide if the conditions
        are met.
        (WebCore::MediaControlRootElement::stopHideFullscreenControlsTimer): Stop the timer.

        * html/shadow/MediaControlRootElement.h: Added new functions and data members.

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

Conflicts:

Source/WebCore/html/shadow/MediaControlRootElement.cpp

6 years ago2011-05-29 Brian Weinstein <bweinstein@apple.com>
Jer Noble [Mon, 30 May 2011 03:37:14 +0000 (03:37 +0000)]
2011-05-29  Brian Weinstein  <bweinstein@apple.com>

        Reviewed by Darin Adler.

        Controls never hide in full screen after user stops moving mouse
        https://bugs.webkit.org/show_bug.cgi?id=61715
        <rdar://problem/9522182>

        When we get a mouse move event in HTMLMediaElement::defaultEventHandler, and we are in full screen,
        show the media controls, and then start a timer.

        The timer fires 3 seconds after the user's last mouse movement (timer is restarted on every mouse
        move), and hides the controls.

        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize our new timer.
        (WebCore::HTMLMediaElement::play): If we are in full screen mode, start our timer to hide the full screen
            controls. We don't want the user to have to move the mouse to hide them when they use the spacebar
            to play.
        (WebCore::HTMLMediaElement::startHideFullscreenControlsTimer): Starts a oneshot timer 3 seconds in the future
            if we are in full screen.
        (WebCore::HTMLMediaElement::hideFullscreenControlsTimerFired): Make sure that we are currently playing, and
            we are in full screen, and hide the controls. We don't want to hide the controls if we are paused.
        (WebCore::HTMLMediaElement::stopHideFullscreenControlsTimer): Stops the timer.
        (WebCore::HTMLMediaElement::defaultEventHandler): If we get a mouse move event and are in full screen, show the
            controls and start a timer to hide them.
        (WebCore::HTMLMediaElement::enterFullscreen): Start a timer to hide the full screen controls. The user shouldn't
            have the move the mouse once they enter full screen to hide the controls.
        (WebCore::HTMLMediaElement::exitFullscreen): Stop the timer to hide the full screen controls.
        * html/HTMLMediaElement.h:
        * html/shadow/MediaControls.h: Added pure virtual shouldHideControls() method.
        * html/shadow/MediaControlRootElement.cpp:
        (WebCore::MediaControlRootElement::playbackStopped): Stop the timer to hide the full screen controls.
        (WebCore::MediaControlRootElement::shouldHideControls): Added, only report that
            the caller should hide the controls if the panel is not hovered.
        * html/shadow/MediaControlRootElement.h:

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

6 years ago2011-05-29 Darin Adler <darin@apple.com>
Darin Adler [Mon, 30 May 2011 00:00:34 +0000 (00:00 +0000)]
2011-05-29  Darin Adler  <darin@apple.com>

        Reviewed by Kevin Decker.

        REGRESSION (r87622): In media documents, clicking the full screen button and the play button pauses the video
        https://bugs.webkit.org/show_bug.cgi?id=61713

        We need to come up with a way to regression-test these changes. Nothing at the moment.

        The bug is that we removed calls to preventDefault, but we still do need to prevent
        default handling of this event.

        * html/shadow/MediaControlElements.cpp:
        (WebCore::MediaControlElement::preDispatchEventHandler): Add back the preventDefault
        that was in here before r87622 as well as the stopPropagation that was added in r87622.
        (WebCore::MediaControlMuteButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlPlayButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlSeekButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlRewindButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlReturnToRealtimeButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlToggleClosedCaptionsButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlFullscreenButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlFullscreenVolumeMinButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlFullscreenVolumeMaxButtonElement::preDispatchEventHandler): Ditto.

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

6 years ago2011-05-28 Jer Noble <jer.noble@apple.com>
Jer Noble [Sat, 28 May 2011 19:41:14 +0000 (19:41 +0000)]
2011-05-28  Jer Noble  <jer.noble@apple.com>

        Reviewed by Maciej Stachowiak.

        Mouse clicks propagate outside full-screen media controls.
        https://bugs.webkit.org/show_bug.cgi?id=61689

        Mouse click events are propagating out of the media controls, so mouse click
        listeners registered on the video element are getting fired when the user
        clicks on media controller buttons.  By default, block propagation of click
        events from MediaControlElements by overriding preDispatchEventHandler, and
        convert all instances of defaultEventHandler -> preDispatchEventHandler.  Change
        all calls of event->setDefaultHandled() to event->stopPropagation().

        * html/shadow/MediaControlElements.cpp:
        (WebCore::MediaControlElement::preDispatchEventHandler): Added.  Block
            propagation of all mouse click events.
        (WebCore::MediaControlVolumeSliderContainerElement::preDispatchEventHandler):
            Renamed from setDefaultHandled.
        (WebCore::MediaControlMuteButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlPanelMuteButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlPlayButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlSeekButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlRewindButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlReturnToRealtimeButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlToggleClosedCaptionsButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlTimelineElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlVolumeSliderElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlFullscreenButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlFullscreenVolumeMinButtonElement::preDispatchEventHandler): Ditto.
        (WebCore::MediaControlFullscreenVolumeMaxButtonElement::preDispatchEventHandler): Ditto.
        * html/shadow/MediaControlElements.h:

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

6 years ago2011-05-26 Alexis Menard <alexis.menard@openbossa.org>
Alexis Menard [Thu, 26 May 2011 18:34:52 +0000 (18:34 +0000)]
2011-05-26  Alexis Menard  <alexis.menard@openbossa.org>

        Unreviewed build fix for Qt and QuickTime backend.

        r87328 added a new system interface, we need to add it too.

        * WebCoreSupport/WebSystemInterface.mm:
        (InitWebCoreSystemInterface):
2011-05-26  Alexis Menard  <alexis.menard@openbossa.org>

        Unreviewed build fix for Qt and QuickTime backend.

        r87328 added a new system interface, we need to add it too.

        * platform/qt/WebCoreSystemInterface.h:
        * platform/qt/WebCoreSystemInterface.mm:

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

6 years ago2011-05-24 Jer Noble <jer.noble@apple.com>
Ademar de Souza Reis Jr [Fri, 27 May 2011 19:18:32 +0000 (16:18 -0300)]
2011-05-24  Jer Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        Video fails to play on Vimeo
        https://bugs.webkit.org/show_bug.cgi?id=61403

        No new tests; Covered by media/video-canvas-source.html.

        Vimeo redirects their assets from player.vimeo.com to av.vimeo.com, which is rejected
        by AVFoundation and QTKit due to our setting a ForbidCrossSiteReference option when
        creating an AVAsset or QTMovie. Instead, we should just reject local->remote and
        remote->local and make our answer to hasSingleSecurityOrigin dynamic.

        When checking whether a given request has a single security origin, use a
        SecurityOrigin to check the host, port, and scheme.

        * WebCore.exp.in:
        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
        (WebCore::MediaPlayerPrivateAVFoundation::assetURL): Added.
        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.h:
        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm:
        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Exchange ForbidCrossSiteReference
            for ForbidRemoteReferenceToLocal and ForbidLocalReferenceToRemote
        (WebCore::MediaPlayerPrivateAVFoundationObjC::hasSingleSecurityOrigin): Check to see that the
            requested and resolved URLs have the same host and port.
        * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
        (WebCore::MediaPlayerPrivateQTKit::commonMovieAttributes): Exchange NoCrossSiteAttribute for
            NoRemoteToLocalSiteAttribute and NoLocalToRemoteSiteAttribute.
        (WebCore::MediaPlayerPrivateQTKit::hasSingleSecurityOrigin):     Check to see that the
                requested and resolved URLs have the same host and port.
        * platform/mac/WebCoreSystemInterface.h: Added wkAVAssetResolvedURL.
        * platform/mac/WebCoreSystemInterface.mm: Ditto.
2011-05-24  Jer Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        Video fails to play on Vimeo
        https://bugs.webkit.org/show_bug.cgi?id=61403

        * WebCoreSupport/WebSystemInterface.mm:
        (InitWebCoreSystemInterface): Added support for wkAVAssetResolvedURL and
            wkQTMovieResolvedURL.
2011-05-24  Jer Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        Video fails to play on Vimeo
        https://bugs.webkit.org/show_bug.cgi?id=61403

        * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
        (InitWebCoreSystemInterface): Added support for wkAVAssetResolvedURL and
            wkQTMovieResolvedURL.
2011-05-25  Jer Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        Video fails to play on Vimeo
        https://bugs.webkit.org/show_bug.cgi?id=61403

        Added functions to retrieve the resolved URL for media types supported on
        mac.

        * WebKitSystemInterface.h:
        * WebKitSystemInterface.m:
        (WKAVAssetResolvedURL): Added.
        (WKQTMovieResolvedURL): Added.

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

Conflicts:

Source/WebCore/platform/mac/WebCoreSystemInterface.h
Source/WebCore/platform/mac/WebCoreSystemInterface.mm
Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm
Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm

6 years ago2011-05-15 Eric Carlson <eric.carlson@apple.com>
Eric Carlson [Sun, 15 May 2011 16:18:03 +0000 (16:18 +0000)]
2011-05-15  Eric Carlson  <eric.carlson@apple.com>

        Reviewed by Maciej Stachowiak.

        Use new AVAssetReferenceRestrictions to prevent cross site media references
        https://bugs.webkit.org/show_bug.cgi?id=60791
        <rdar://problem/9374202>

        Test: http/tests/media/video-cross-site.html

        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm:
        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Set restriction
            to prevent cross-domain references from being followed.

2011-05-15  Eric Carlson  <eric.carlson@apple.com>

        Reviewed by Maciej Stachowiak.

        Use new AVAssetReferenceRestrictions to prevent cross site media references
        https://bugs.webkit.org/show_bug.cgi?id=60791
        <rdar://problem/9374202>

        Add test for cross-domain QuickTime reference movie and test.

        * http/tests/media/resources/cross-site-reference.mov: Added.
        * http/tests/media/video-cross-site-expected.txt: Added.
        * http/tests/media/video-cross-site.html: Added.
        * platform/chromium/test_expectations.txt: Skipped, QuickTime reference movies not supported.
        * platform/gtk/Skipped: Ditto.

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

6 years ago2011-05-10 Eric Carlson <eric.carlson@apple.com>
Eric Carlson [Tue, 10 May 2011 17:08:10 +0000 (17:08 +0000)]
2011-05-10  Eric Carlson  <eric.carlson@apple.com>

        Reviewed by Darin Adler.

        Files that load quickly sometimes won't play.
        https://bugs.webkit.org/show_bug.cgi?id=60556
        <rdar://problem/9330567>

        No new tests, this failure is very difficult to reproduce on some machines. The fix was
        verified manually.

        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
        (WebCore::MediaPlayerPrivateAVFoundation::playabilityKnown): Move the call to updateStates
            to dispatchNotification so it is more obvious which state changes call it.
        (WebCore::MediaPlayerPrivateAVFoundation::setNaturalSize): Correct logging typo.
        (WebCore::MediaPlayerPrivateAVFoundation::metadataLoaded): Move updateStates call to
            dispatchNotification.
        (WebCore::MediaPlayerPrivateAVFoundation::rateChanged): Ditto.
        (WebCore::MediaPlayerPrivateAVFoundation::loadedTimeRangesChanged): Ditto.
        (WebCore::MediaPlayerPrivateAVFoundation::dispatchNotification): Call updateStates after
            processing "size changed" notification so we detect all state changes. Consolidate
            calls to updateStates here.

        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm:
        (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer): Name the video layer in
            a debug build.

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

6 years ago2011-05-05 Eric Carlson <eric.carlson@apple.com>
Eric Carlson [Thu, 5 May 2011 20:21:38 +0000 (20:21 +0000)]
2011-05-05  Eric Carlson  <eric.carlson@apple.com>

        Reviewed by Adam Roben.

        Block callbacks delivered during destruction
        https://bugs.webkit.org/show_bug.cgi?id=60291
        <rdar://problem/9382942>

        No new tests, tested by existing tests.

        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
        (WebCore::MediaPlayerPrivateAVFoundation::~MediaPlayerPrivateAVFoundation): Call
            setIgnoreLoadStateChanges(true) to cancel all callbacks.
        (WebCore::MediaPlayerPrivateAVFoundation::updateStates): Return immediately if
            m_ignoreLoadStateChanges is true.
        (WebCore::MediaPlayerPrivateAVFoundation::dispatchNotification): loadStateChanged -> updateStates.
            Don't call updateStates after calling loadedTimeRangesChanged, it already does it.
        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:

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

6 years ago2011-05-25 Andrew Scherkus <scherkus@chromium.org>
Andrew Scherkus [Wed, 25 May 2011 21:47:39 +0000 (21:47 +0000)]
2011-05-25  Andrew Scherkus  <scherkus@chromium.org>

        Reviewed by Eric Carlson.

        Fix media element regression where ended event stopped firing after changing the src attribute.

        https://bugs.webkit.org/show_bug.cgi?id=61336

        * media/media-ended-expected.txt: Added.
        * media/media-ended.html: Added.
2011-05-25  Andrew Scherkus  <scherkus@chromium.org>

        Reviewed by Eric Carlson.

        Fix media element regression where ended event stopped firing after changing the src attribute.

        https://bugs.webkit.org/show_bug.cgi?id=61336

        Test: media/media-ended.html

        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::prepareForLoad):

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

6 years ago2011-05-25 Jer Noble <jer.noble@apple.com>
Jer Noble [Wed, 25 May 2011 21:38:31 +0000 (21:38 +0000)]
2011-05-25  Jer Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        REGRESSION: Fullscreen button on embedded Vimeo videos does nothing
        https://bugs.webkit.org/show_bug.cgi?id=61461

        * fullscreen/full-screen-iframe-legacy-expected.txt: Added.
        * fullscreen/full-screen-iframe-legacy.html: Added.
        * fullscreen/resources/legacy.html: Added.
2011-05-25  Jer Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        REGRESSION: Fullscreen button on embedded Vimeo videos does nothing
        https://bugs.webkit.org/show_bug.cgi?id=61461

        Tests: fullscreen/full-screen-iframe-legacy.html

        Allow calls from the legacy full-screen API to bypass the iframe
        "webkitallowfullscreen" requirement by adding a parameter to
        Document::webkitRequestFullScreenForElement specifying the strictness
        of that check.  Specify this new parameter everywhere that function is
        called, including in the default controls' full-screen button handler.

        * dom/Document.cpp:
        (WebCore::Document::webkitRequestFullScreenForElement):
        * dom/Document.h:
        * dom/Element.cpp:
        (WebCore::Element::requestFullScreen): Renamed from webkitRequestFullScreen.
        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::enterFullscreen):
        * html/shadow/MediaControlElements.cpp:
        (WebCore::MediaControlFullscreenButtonElement::defaultEventHandler):

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

6 years ago2011-05-25 Alexis Menard <alexis.menard@openbossa.org>
Alexis Menard [Wed, 25 May 2011 19:22:25 +0000 (19:22 +0000)]
2011-05-25  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Eric Carlson.

        [Qt] Enable usage of QuickTime mediaplayer for the Qt port on Mac.
        https://bugs.webkit.org/show_bug.cgi?id=61279

        Enable the QuickTime backend for the Qt port on Mac. The patch adds the bits in WebCore
        to enable the QTKit backend of the Mac port. It can be enabled by passing DEFINES+=USE_QTKIT=1
        when calling build-webkit.

        * WebCore.pri:
        * WebCore.pro:
        * features.pri:
        * platform/KURL.h:
        * platform/SharedBuffer.h:
        * platform/cf/KURLCFNet.cpp:
        * platform/cf/SharedBufferCF.cpp:
        * platform/graphics/FloatSize.h:
        * platform/graphics/IntRect.h:
        * platform/graphics/IntSize.h:
        * platform/graphics/MediaPlayer.cpp:
        * platform/graphics/cg/FloatSizeCG.cpp:
        * platform/graphics/cg/IntRectCG.cpp:
        * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
        * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
        (WebCore::MediaPlayerPrivateQTKit::createQTMovieView):
        (WebCore::MediaPlayerPrivateQTKit::createQTVideoRenderer):
        (WebCore::MediaPlayerPrivateQTKit::createQTMovieLayer):
        (WebCore::MediaPlayerPrivateQTKit::preferredRenderingMode):
        (WebCore::MediaPlayerPrivateQTKit::paint):
        (-[WebCoreMovieObserver layerHostChanged:]):
        * platform/mac/KURLMac.mm:
        * platform/mac/SharedBufferMac.mm:
        (+[WebCoreSharedBufferData initialize]):
        * platform/mac/WebCoreObjCExtras.mm:
        * platform/qt/WebCoreSystemInterface.h: Added.
        * platform/qt/WebCoreSystemInterface.mm: Added.
2011-05-25  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Eric Carlson.

        [Qt] Enable usage of QuickTime mediaplayer for the Qt port on Mac.
        https://bugs.webkit.org/show_bug.cgi?id=61279

        Enable the usage of QuickTime backend for the Qt port. It can be enabled by
        passing DEFINES+=USE_QTKIT=1 when calling build-webkit.

        * Api/qwebpage.cpp:
        (QWebPagePrivate::QWebPagePrivate):
        * QtWebKit.pro:
        * WebCoreSupport/FullScreenVideoQt.cpp:
        (WebCore::FullScreenVideoQt::enterFullScreenForNode):
        (WebCore::FullScreenVideoQt::requiresFullScreenForVideoPlayback):
        (WebCore::FullScreenVideoQt::isValid):
        * WebCoreSupport/WebSystemInterface.h: Added.
        * WebCoreSupport/WebSystemInterface.mm: Added.
        (InitWebCoreSystemInterface):

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

6 years agoUnreviewed; build fix for non-SnowLeopard builds.
Jer Noble [Mon, 16 May 2011 18:03:21 +0000 (18:03 +0000)]
Unreviewed; build fix for non-SnowLeopard builds.

* platform/graphics/mac/MediaPlayerPrivateQTKit.mm: Wrap definition
    of layerIsDescendentOf in a #if check.

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

6 years ago2011-05-13 Jer Noble <jer.noble@apple.com>
Jer Noble [Mon, 16 May 2011 17:50:54 +0000 (17:50 +0000)]
2011-05-13  Jer Noble  <jer.noble@apple.com>

        Reviewed by Simon Fraser.

        Video is blank, controller is misplaced on trailers.apple.com movie in fullscreen (with two screens)
        https://bugs.webkit.org/show_bug.cgi?id=60826

        Listen for a WebKitLayerHostChanged notification and, if the affected layer is an
        ancestor layer of the qtMovieLayer, tear down the layer and recreate it the
        next time setVisible(true) is called.

        * dom/Document.cpp:
        (WebCore::Document::webkitDidEnterFullScreenForElement):  Call setFullScreenRootLayer(0)
            before disabling animation on the full screen renderer.
        * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
        * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
        (WebCore::MediaPlayerPrivateQTKit::createQTMovie): Register an observer for the new
            WebKitLayerHostChanged notification.
        (WebCore::layerIsDescendentOf): Added.
        (WebCore::MediaPlayerPrivateQTKit::layerHostChanged): Added.  If the changed
            layer is an ancestor of the movie layer, tear down rendering and re-
            create the next time setVisible(true) is called.
        (-[WebCoreMovieObserver layerHostChanged:]):  Added ObjC listener wrapper.
2011-05-13  Jer Noble  <jer.noble@apple.com>

        Reviewed by Simon Fraser.

        Video is blank, controller is misplaced on trailers.apple.com movie in fullscreen (with two screens)
        https://bugs.webkit.org/show_bug.cgi?id=60826

        Emit a notification when moving a CALayer from the WebProcess's main
        layer host to a new context.  This allows listeners to invalidate their
        layers which may not support moving between different CAContexts (as is
        the case with QTMovieLayer).  In order to allow listeners to determine if they
        are affected, the notification will pass the root CALayer in a userInfo
        dictionary.

        In WebFullScreenManagerMac, move from storing a pointer to a non-refcounted
        class (GraphicsLayer) to a retainable class (PlatformLayer).

        * WebProcess/FullScreen/mac/WebFullScreenManagerMac.h:
        * WebProcess/FullScreen/mac/WebFullScreenManagerMac.mm:
        (WebKit::WebFullScreenManagerMac::WebFullScreenManagerMac): No need to initialize
            m_fullScreenRootLayer now that it is a RetainPtr<>.
        (WebKit::WebFullScreenManagerMac::setRootFullScreenLayer): Emit a notification
            after either creating or destroying the full screen layer host.
        (WebKit::WebFullScreenManagerMac::beginEnterFullScreenAnimation):
        (WebKit::WebFullScreenManagerMac::beginExitFullScreenAnimation):

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

6 years ago2011-05-18 Jeremy Noble <jer.noble@apple.com>
Jer Noble [Thu, 19 May 2011 23:17:00 +0000 (23:17 +0000)]
2011-05-18  Jeremy Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        Poster is not shown in Safari for video element with no playable source elements.
        https://bugs.webkit.org/show_bug.cgi?id=61109

        * media/video-src-invalid-poster-expected.txt: Added.
        * media/video-src-invalid-poster.html: Added.
2011-05-18  Jeremy Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        Poster is not shown in Safari for video element with no playable source elements.
        https://bugs.webkit.org/show_bug.cgi?id=61109

        Test: media/video-src-invalid-poster.html

        In the case where no video sources are playable, update the display state and
        renderer, allowing the poster image to display.

        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::waitForSourceChange):

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

6 years ago2011-05-14 Jeremy Noble <jer.noble@apple.com>
Jer Noble [Sat, 14 May 2011 17:29:14 +0000 (17:29 +0000)]
2011-05-14  Jeremy Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        Exiting full screen causes <video> element inline controls to become visible
        https://bugs.webkit.org/show_bug.cgi?id=60142

        * fullscreen/video-controls-override-expected.txt: Added.
        * fullscreen/video-controls-override.html: Added.
2011-05-14  Jeremy Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        Exiting full screen causes <video> element inline controls to become visible
        https://bugs.webkit.org/show_bug.cgi?id=60142

        Create a queue of elements who must be targeted with webkitfullscreenchange events. Instead of dispatching
        a single event with whatever the current value of m_fullScreenElement is (which may have been cleared, or
        changed since the timer was asked to fire), dispatch one event for each entry in the queue.

        Test: fullscreen/video-controls-override.html

        * dom/Document.cpp:
        (WebCore::Document::webkitDidEnterFullScreenForElement): Push current full screen element onto the
            webkitfullscreenchange event delay queue.
        (WebCore::Document::webkitDidExitFullScreenForElement): Ditto.
        (WebCore::Document::fullScreenElementRemoved): Ditto.
        (WebCore::Document::fullScreenChangeDelayTimerFired): Empty the queue, dispatching a
            webkitfullscreenchange event for each entry.
        * dom/Document.h:

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

6 years ago2011-05-05 Jer Noble <jer.noble@apple.com>
Jer Noble [Tue, 10 May 2011 22:38:52 +0000 (22:38 +0000)]
2011-05-05  Jer Noble  <jer.noble@apple.com>

        Reviewed by Maciej Stachowiak.

        Removing the full screen element via parent.innerHTML="" does not result in a webkitfullscreenchange event.
        https://bugs.webkit.org/show_bug.cgi?id=60278

        * fullscreen/full-screen-remove-children-expected.txt: Added.
        * fullscreen/full-screen-remove-children.html: Added.
        * fullscreen/full-screen-test.js: Fixed an exception when running in Safari.
2011-05-05  Jer Noble  <jer.noble@apple.com>

        Reviewed by Maciej Stachowiak.

        Removing the full screen element via parent.innerHTML="" does not result in a webkitfullscreenchange event.
        https://bugs.webkit.org/show_bug.cgi?id=60278

        Handle the removal of a full screen element from within Node::willRemove() instead
        of Document::nodeWillBeRemoved().  The new function Document::fullScreenElementWillBeRemoved() will
        be called by Node::willRemove() to handle those changes which used to occur in nodeWillBeRemoved().

        Test: fullscreen/full-screen-remove-children.html

        * dom/Document.cpp:
        (WebCore::Document::nodeWillBeRemoved): Removed the code checking for the full screen element.
        (WebCore::Document::fullScreenElementWillBeRemoved): Added, moved from nodeWillBeRemoved.
        * dom/Document.h:
        * dom/Node.cpp:
        (WebCore::Node::willRemove): Check to see if this is the current full screen element.

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

6 years ago2011-05-04 Philippe Normand <pnormand@igalia.com>
Philippe Normand [Wed, 11 May 2011 15:08:40 +0000 (15:08 +0000)]
2011-05-04  Philippe Normand  <pnormand@igalia.com>

        Reviewed by Martin Robinson.

        [Gtk+] deadlock in gstreamer video player when exiting fullscreen
        https://bugs.webkit.org/show_bug.cgi?id=58548

        Block data flow towards the pipeline branch to remove to avoid
        potential deadlocks during the PAUSED->READY transitions of the
        elements to remove.

        * platform/graphics/gstreamer/GStreamerGWorld.cpp:
        (WebCore::GStreamerGWorld::exitFullscreen):

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

6 years ago2011-05-11 Eric Carlson <eric.carlson@apple.com>
Eric Carlson [Wed, 11 May 2011 17:41:35 +0000 (17:41 +0000)]
2011-05-11  Eric Carlson  <eric.carlson@apple.com>

        Reviewed by Darin Adler.

        Video track sometimes fails to draw.
        https://bugs.webkit.org/show_bug.cgi?id=60635
        <rdar://problem/9281951>

        No new tests, covered by existing pixel tests.

        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::loadResource): Set display mode to "Unknown" to force a
            recalculation, and media engine notification, the next time the state machine runs.

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

6 years ago2011-05-09 Jeremy Noble <jer.noble@apple.com>
Jer Noble [Mon, 9 May 2011 23:50:28 +0000 (23:50 +0000)]
2011-05-09  Jeremy Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        Command-~/Exposé to another window while <video> is in full screen, breaks Safari, eventually leading to crash
        https://bugs.webkit.org/show_bug.cgi?id=60496

        When animating into and out of full screen, order out and back in the original webView window,
        disabling animations when necessary.  The exitFullscreen method was targeting the wrong window,
        as the webView is hosted in the full screen window when we ask for it's parent window.

        * WebView/WebFullScreenController.mm:
        (-[WebFullScreenController windowDidEnterFullscreen:]):
        (-[WebFullScreenController exitFullscreen]):
2011-05-09  Jeremy Noble  <jer.noble@apple.com>

        Reviewed by Darin Adler.

        Command-~/Exposé to another window while <video> is in full screen, breaks Safari, eventually leading to crash
        https://bugs.webkit.org/show_bug.cgi?id=60496

        When animating into and out of full screen, order out and back in the original webView window,
        disabling animations when necessary. The beganExitFullScreenAnimation method was targeting the wrong window,
        as the webView is hosted in the full screen window when we ask for it's parent window.

        * UIProcess/mac/WKFullScreenWindowController.mm:
        (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]):
        (-[WKFullScreenWindowController beganExitFullScreenAnimation]):

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

6 years ago2011-05-05 Eric Carlson <eric.carlson@apple.com>
Eric Carlson [Thu, 5 May 2011 18:17:23 +0000 (18:17 +0000)]
2011-05-05  Eric Carlson  <eric.carlson@apple.com>

        Reviewed by Adam Roben.

        The preload attribute of the video tag is not completely implemented
        https://bugs.webkit.org/show_bug.cgi?id=43673
        <rdar://problem/9369746>

        This change implements "preload=metadata" for the AVFoundation backend.
        Tested manually with manual-tests/media-elements/video-preload.html.

        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize m_havePreparedToPlay.
        (WebCore::HTMLMediaElement::prepareForLoad): Ditto.
        (WebCore::HTMLMediaElement::prepareToPlay): New, tell player to prepare to play.
        (WebCore::HTMLMediaElement::seek): Call prepareToPlay when preload is less than 'auto'
            because we need to have media data loaded to seek.
        (WebCore::HTMLMediaElement::updatePlayState): Call prepareToPlay.
        * html/HTMLMediaElement.h:

        * manual-tests/media-elements/video-preload.html: Make changing urls work.

        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
        (WebCore::MediaPlayerPrivateAVFoundation::MediaPlayerPrivateAVFoundation):  Remove
            m_videoFrameHasDrawn and m_delayingLoad as they are no longer used.
        (WebCore::MediaPlayerPrivateAVFoundation::resumeLoad): Removed.
        (WebCore::MediaPlayerPrivateAVFoundation::load): Don't initialize m_videoFrameHasDrawn.
            Move all preload logic to setPreload, call it from here.
        (WebCore::MediaPlayerPrivateAVFoundation::prepareToPlay): Move all preload logic to
            setPreload, call it.
        (WebCore::MediaPlayerPrivateAVFoundation::duration): Don't cache duration = 0, it is
            unlikely to be correct and isn't worth caching. Use invalidTime() function.
        (WebCore::MediaPlayerPrivateAVFoundation::seeking): Use invalidTime() function.
        (WebCore::MediaPlayerPrivateAVFoundation::setNaturalSize): Add logging.
        (WebCore::MediaPlayerPrivateAVFoundation::updateStates): Update for name change AVAssetStatus
            to AssetStatus. Always create a AVPlayerItem for live streams because they can't be inspected
            without one. Set networkState to 'idle' when the playback buffer is full because that is
            a signal that AVFoundation won't do any more IO. Set readyState to 'HAVE_CURRENT_DATA'
            when the first frame is available.
        (WebCore::MediaPlayerPrivateAVFoundation::metadataLoaded): Call tracksChanged so we cache
            width, height, hasVideo, etc.
        (WebCore::MediaPlayerPrivateAVFoundation::loadedTimeRangesChanged): Use invalidTime() function.
        (WebCore::MediaPlayerPrivateAVFoundation::timeChanged): Ditto.
        (WebCore::MediaPlayerPrivateAVFoundation::seekCompleted): Ditto.
        (WebCore::MediaPlayerPrivateAVFoundation::repaint): Don't set m_videoFrameHasDrawn, it is done
            in derived classes.
        (WebCore::MediaPlayerPrivateAVFoundation::setPreload): Centralize all logic about when to create
            AVAsset and AVPlayerItem here.
        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:

        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.h:
        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm:
        (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Initialize
            m_videoFrameHasDrawn.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::hasAvailableVideoFrame): New, renamed from
            videoLayerIsReadyToDisplay. Return true if we have a layer with frames available or
            if we have painted a frame to the context.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): New, create the AVAsset
            if necessary.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForCacheResource): Ditto.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): Restructure logic.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): New, create AVPlayerItem.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::beginLoadingMetadata): Correct logging.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::playerItemStatus): Return "buffer full" when
            the buffer is full.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::platformDuration): Get the duration from the
            AVAsset when we haven't allocated the AVPlayerItem yet so that we can return duration
            when we only have metadata.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::assetStatus): Update for name change.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::paint): Set m_videoFrameHasDrawn.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Get attributes from AVAsset
            when when we haven't allocated the AVPlayerItem yet so that we can report attributes
            when we only have metadata.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::sizeChanged): Guard against being called before
            we have allocated the AVPlayerItem.

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

6 years ago2011-06-03 Doreen Jiang <doreen.jiang@nokia.com>
commit-queue [Fri, 3 Jun 2011 17:03:21 +0000 (17:03 +0000)]
2011-06-03  Doreen Jiang  <doreen.jiang@nokia.com>

        Reviewed by Benjamin Poulain.

        [Qt]The minimum size of the select menu list is incorrect for qtwebkit
        https://bugs.webkit.org/show_bug.cgi?id=56752

        The test is to get the render tree of select menu lists with varying widths based on content.
        Some select list based tests are rebaselined because minimum width of RenderMenuList changes
        based on the content with this fix.

        * fast/forms/selectlist-minsize.html: Added.
        * platform/mac/fast/forms/selectlist-minsize-expected.txt: Added.
        * platform/qt/editing/pasteboard/4641033-expected.txt:
        * platform/qt/editing/pasteboard/4944770-1-expected.txt:
        * platform/qt/editing/pasteboard/4944770-2-expected.txt:
        * platform/qt/editing/selection/caret-before-select-expected.txt:
        * platform/qt/fast/forms/003-expected.txt:
        * platform/qt/fast/forms/004-expected.txt:
        * platform/qt/fast/forms/HTMLOptionElement_label06-expected.txt:
        * platform/qt/fast/forms/HTMLOptionElement_label07-expected.txt:
        * platform/qt/fast/forms/basic-selects-expected.txt:
        * platform/qt/fast/forms/menulist-deselect-update-expected.txt:
        * platform/qt/fast/forms/menulist-separator-painting-expected.txt:
        * platform/qt/fast/forms/menulist-style-color-expected.txt:
        * platform/qt/fast/forms/option-script-expected.txt:
        * platform/qt/fast/forms/select-background-none-expected.txt:
        * platform/qt/fast/forms/select-baseline-expected.txt:
        * platform/qt/fast/forms/select-dirty-parent-pref-widths-expected.txt:
        * platform/qt/fast/forms/select-empty-option-height-expected.txt:
        * platform/qt/fast/forms/select-size-expected.txt:
        * platform/qt/fast/forms/select-style-expected.txt:
        * platform/qt/fast/forms/selectlist-minsize-expected.txt: Added.
        * platform/qt/fast/invalid/014-expected.txt:
        * platform/qt/fast/replaced/replaced-breaking-expected.txt:
        * platform/qt/fast/replaced/replaced-breaking-mixture-expected.txt:
        * platform/qt/fast/replaced/three-selects-break-expected.txt:
        * platform/qt/tables/mozilla/bugs/bug29326-expected.txt:
        * platform/qt/tables/mozilla/core/margins-expected.txt:
2011-06-03  Doreen Jiang  <doreen.jiang@nokia.com>

        Reviewed by Benjamin Poulain.

        [Qt]The minimum size of the select menu list is incorrect for qtwebkit
        https://bugs.webkit.org/show_bug.cgi?id=56752

        The minimum width of the select-box is calculated to be as small as possible
        instead of hardcoded value (width of 7 characters) in minimumMenuListSize() function
        This will avoid overapping the select lists in popular websites.

        Test: fast/forms/selectlist-minsize.html

        * platform/qt/RenderThemeQt.cpp:
        (WebCore::RenderThemeQt::minimumMenuListSize):

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

6 years ago2011-06-02 Ryosuke Niwa <rniwa@webkit.org>
Ademar de Souza Reis Jr [Fri, 3 Jun 2011 15:51:57 +0000 (12:51 -0300)]
2011-06-02  Ryosuke Niwa  <rniwa@webkit.org>

        Reviewed by Eric Seidel.

        REGRESSION: inline style is lost when deleting line break between paragraphs with same style
        https://bugs.webkit.org/show_bug.cgi?id=61899

        Added a regression test to ensure WebKit preserves font family for a paragraph being merged
        to the previous paragraph when deleting a line break between two paragraphs with the same style.

        * editing/deleting/delete-line-break-between-paragraphs-with-same-style-expected.txt: Added.
        * editing/deleting/delete-line-break-between-paragraphs-with-same-style.html: Added.
2011-06-02  Ryosuke Niwa  <rniwa@webkit.org>

        Reviewed by Eric Seidel.

        REGRESSION: inline style is lost when deleting line break between paragraphs with same style
        https://bugs.webkit.org/show_bug.cgi?id=61899

        The bug was caused by ReplaceSelectionCommand::doApply's calling handleStyleSpansBeforeInsertion
        before insertionPos is adjusted by positionAvoidingPrecedingNodes and positionOutsideTabSpan.

        Fixed the bug by calling handleStyleSpansBeforeInsertion after the calls to these two functions.

        Test: editing/deleting/delete-line-break-between-paragraphs-with-same-style.html

        * editing/ReplaceSelectionCommand.cpp:
        (WebCore::ReplaceSelectionCommand::doApply):

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

Conflicts:

Source/WebCore/editing/ReplaceSelectionCommand.cpp

6 years ago2011-06-01 Ryosuke Niwa <rniwa@webkit.org>
Ryosuke Niwa [Thu, 2 Jun 2011 19:05:52 +0000 (19:05 +0000)]
2011-06-01  Ryosuke Niwa  <rniwa@webkit.org>

        Reviewed by Simon Fraser.

        REGRESSION: Text selection broken for text with line-height applied
        https://bugs.webkit.org/show_bug.cgi?id=54929

        The bug was caused by RenderText::positionForPoint's not considering the case where a point is
        above selectionTop and below lineTop of the first root inline box. Fixed the bug by considering
        any point between selectionTop and lineTop to be inside a root inline box. This condition is
        consistent with the condition we use to determine the bottom of a line.

        Test: editing/selection/hit-test-on-text-with-line-height.html

        * rendering/RenderBlock.cpp:
        (WebCore::RenderBlock::positionForPointWithInlineChildren): Fixed a condition to determine whether
        or not a point is above the first root line box. We need to check both selectionTop and logicalTop
        for the same reason explained above.
        * rendering/RenderText.cpp:
        (WebCore::RenderText::positionForPoint): See above.
2011-06-01  Ryosuke Niwa  <rniwa@webkit.org>

        Reviewed by Simon Fraser.

        REGRESSION: Text selection broken for text with line-height applied
        https://bugs.webkit.org/show_bug.cgi?id=54929

        Added a test to ensure WebKit can place caret in text with a line-height smaller than
        the height of the text.

        * editing/selection/hit-test-on-text-with-line-height-expected.txt: Added.
        * editing/selection/hit-test-on-text-with-line-height.html: Added.

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

6 years ago2011-06-02 Caio Marcelo de Oliveira Filho <caio.oliveira@openbossa.org>
Caio Marcelo de Oliveira Filho [Fri, 3 Jun 2011 01:44:54 +0000 (01:44 +0000)]
2011-06-02  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] Fix enum order in qwebpage.h public API header
        https://bugs.webkit.org/show_bug.cgi?id=61959

        Since qwebpage.h is a public header, we can't change the values of
        the enumerations. This patch moves the new enumeration to the end
        of the list. As a bonus, adds a missing entry in
        editorCommandWebActions table.

        * Api/qwebpage.cpp:
        * Api/qwebpage.h:

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

6 years ago2011-06-03 Alexis Menard <alexis.menard@openbossa.org>
Alexis Menard [Fri, 3 Jun 2011 12:04:22 +0000 (12:04 +0000)]
2011-06-03  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Benjamin Poulain.

        [Qt] Build fix of QtWebKit 2.2 when inside Qt tree with GCC 4.6.
        https://bugs.webkit.org/show_bug.cgi?id=61957

        When building inside the Qt source tree, qmake always append the mkspecs
        defines after ours. We have to workaround and make sure that we append
        our flags after the qmake variable used inside Qt. This workaround was provided
        by our qmake folks. We need to append in both case because qmake behave differently
        when called with -spec or via SUBDIR+=.

        * Source/WebKit.pri:
2011-06-03  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Benjamin Poulain.

        [Qt] Build fix of QtWebKit 2.2 when inside Qt tree with GCC 4.6.
        https://bugs.webkit.org/show_bug.cgi?id=61957

        When building inside the Qt source tree, qmake always append the mkspecs
        defines after ours. We have to workaround and make sure that we append
        our flags after the qmake variable used inside Qt. This workaround was provided
        by our qmake folks. We need to append in both case because qmake behave differently
        when called with -spec or via SUBDIR+=. This patch unbreak r87950 on Mac for Qt port.

        * JavaScriptCore.pro:

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

6 years ago2011-06-02 Alexis Menard <alexis.menard@openbossa.org>
Alexis Menard [Thu, 2 Jun 2011 20:37:58 +0000 (20:37 +0000)]
2011-06-02  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] Build fix of QtWebKit 2.2 when inside Qt tree with GCC 4.6.
        https://bugs.webkit.org/show_bug.cgi?id=61957

        When building inside the Qt source tree, qmake always append the mkspecs
        defines after ours. We have to workaround and make sure that we append
        our flags after the qmake variable used inside Qt. This workaround was provided
        by our qmake folks.

        * Source/WebKit.pri:
2011-06-02  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] Build fix of QtWebKit 2.2 when inside Qt tree with GCC 4.6.
        https://bugs.webkit.org/show_bug.cgi?id=61957

        When building inside the Qt source tree, qmake always append the mkspecs
        defines after ours. We have to workaround and make sure that we append
        our flags after the qmake variable used inside Qt. This workaround was provided
        by our qmake folks.

        * JavaScriptCore.pro:

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

6 years ago2011-06-02 Andreas Kling <kling@webkit.org>
Andreas Kling [Thu, 2 Jun 2011 14:00:38 +0000 (14:00 +0000)]
2011-06-02  Andreas Kling  <kling@webkit.org>

        Rubber-stamped by Simon Hausmann.

        Remove Qt's precompiled header hack as it was broken, and was not even
        used unless building WebKit inside a Qt tree.

        * WebKit_pch.h: Removed.
2011-06-02  Andreas Kling  <kling@webkit.org>

        Rubber-stamped by Simon Hausmann.

        Remove Qt's precompiled header hack as it was broken, and was not even
        used unless building WebKit inside a Qt tree.

        * WebCore.pri:

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

6 years ago2011-06-01 David Carson <dacarson@apple.com>
commit-queue [Wed, 1 Jun 2011 21:42:43 +0000 (21:42 +0000)]
2011-06-01  David Carson  <dacarson@apple.com>

        Reviewed by Antti Koivisto.

        Don't flatten frames that have a zero size.
        https://bugs.webkit.org/show_bug.cgi?id=61831

        This tests creates an iframe that has a width and height of zero
        and ensures that the iframe is not flattened to the size of the
        containing content.

        * fast/frames/flattening/iframe-flattening-fixed-width-and-height-zero-size.html: Added.
        * fast/frames/flattening/iframe-flattening-fixed-width-and-height-zero-size-expected.txt: Added.
2011-06-01  David Carson  <dacarson@apple.com>

        Reviewed by Antti Koivisto.

        https://bugs.webkit.org/show_bug.cgi?id=61831
        If width and height of an iframe is fixed and should not be visible, then
        it shouldn't be flattened.

        Test: fast/frames/flattening/iframe-flattening-fixed-width-and-height-zero-size.html

        * rendering/RenderIFrame.cpp:
        (WebCore::RenderIFrame::flattenFrame): add a check for a zero width or height

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

6 years ago2011-06-02 Aparna Nandyal <aparna.nand@wipro.com>
commit-queue [Thu, 2 Jun 2011 12:10:48 +0000 (12:10 +0000)]
2011-06-02  Aparna Nandyal  <aparna.nand@wipro.com>

        Reviewed by Andreas Kling.

        [Qt] Multiple drop events when doing DnD of images.
        https://bugs.webkit.org/show_bug.cgi?id=61504

        Duplicate entries of the url were getting added into drag data
        which is removed. The duplicate entries were causing the same image
        url to be copied twice. The code changes now match other webkit ports.

        * platform/qt/ClipboardQt.cpp:
        (WebCore::ClipboardQt::declareAndWriteDragImage):

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

6 years ago2011-06-01 Andreas Kling <kling@webkit.org>
Andreas Kling [Wed, 1 Jun 2011 12:39:46 +0000 (12:39 +0000)]
2011-06-01  Andreas Kling  <kling@webkit.org>

        Reviewed by Benjamin Poulain.

        REGRESSION: [Qt] QNetworkReply delivered by the unsupportedContent() signal does not contain downloaded data
        https://bugs.webkit.org/show_bug.cgi?id=49650

        Defer emission of QWebPage::unsupportedContent() until we're back in the event loop.
        This lets the QNAM backend finish with the reply without handing over ownership to the user code.

        No new tests since this doesn't fail for qrc:// or file:// URLs and our tests can't depend on http:// URLs.

        To correctly solve this issue, we need changes to Qt, tracked here:
        http://bugreports.qt.nokia.com/browse/QTBUG-18718

        * WebCoreSupport/FrameLoaderClientQt.cpp:
        (WebCore::FrameLoaderClientQt::setFrame):
        (WebCore::FrameLoaderClientQt::download):
        * WebCoreSupport/FrameLoaderClientQt.h:

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

6 years ago2011-06-02 Andreas Kling <kling@webkit.org>
andreas.kling@nokia.com [Thu, 2 Jun 2011 12:55:03 +0000 (12:55 +0000)]
2011-06-02  Andreas Kling  <kling@webkit.org>

        Unreviewed build fix.

        To support building namespaced Qt, we require that forward-declarations
        of Qt classes be wrapped in QT_BEGIN_NAMESPACE and QT_END_NAMESPACE.

        * WebCoreSupport/DumpRenderTreeSupportQt.h:

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

6 years ago2011-05-31 Oliver Hunt <oliver@apple.com>
Oliver Hunt [Wed, 1 Jun 2011 18:08:07 +0000 (18:08 +0000)]
2011-05-31  Oliver Hunt  <oliver@apple.com>

        Reviewed by Geoffrey Garen.

        Freezing a function and its prototype causes browser to crash.
        https://bugs.webkit.org/show_bug.cgi?id=61758

        Add test to ensure correct behaviour

        * fast/js/preventExtensions-expected.txt:
        * fast/js/script-tests/preventExtensions.js:
        (f):
2011-05-31  Oliver Hunt  <oliver@apple.com>

        Reviewed by Geoffrey Garen.

        Freezing a function and its prototype causes browser to crash.
        https://bugs.webkit.org/show_bug.cgi?id=61758

        Make JSObject::preventExtensions virtual so that we can override it
        and instantiate all lazy

        * JavaScriptCore.exp:
        * runtime/JSFunction.cpp:
        (JSC::createPrototypeProperty):
        (JSC::JSFunction::preventExtensions):
        (JSC::JSFunction::getOwnPropertySlot):
        * runtime/JSFunction.h:
        * runtime/JSObject.h:
        * runtime/JSObject.cpp:
        (JSC::JSObject::seal):
        (JSC::JSObject::seal):

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

6 years ago2011-06-01 Caio Marcelo de Oliveira Filho <caio.oliveira@openbossa.org>
Caio Marcelo de Oliveira Filho [Wed, 1 Jun 2011 16:58:35 +0000 (16:58 +0000)]
2011-06-01  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>

        Reviewed by Kenneth Rohde Christiansen.

        [Qt]Fix tst_QWebFrame::setUrlToInvalid() autotest after r84762
        https://bugs.webkit.org/show_bug.cgi?id=59345

        KURL and QUrl disagree whether certain URLs are valid or not. The regression here
        was caused by the fact that now KURL accepts "http:/example.com" (note only one
        slash) and our test case used a strange edge case that's transformed into a
        "one-slash" URL that now KURL can handle.

        QtWebKit approach in this case is to do a best effort and accept the QUrl if KURL
        can understand it. So I've updated the test to use a more meaningful example and
        show that an invalid URL gets converted to a valid URL if possible.

        * tests/qwebframe/tst_qwebframe.cpp:
        (tst_QWebFrame::setUrlToInvalid):

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

6 years ago2011-06-01 Caio Marcelo de Oliveira Filho <caio.oliveira@openbossa.org>
Caio Marcelo de Oliveira Filho [Wed, 1 Jun 2011 12:16:09 +0000 (12:16 +0000)]
2011-06-01  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>

        Reviewed by Tor Arne Vestbø.

        [Qt] Rewrite tst_QDeclarativeWebView::multipleWindows() to not depend on Grid internals
        https://bugs.webkit.org/show_bug.cgi?id=61739

        The skipped test was imported from Qt source repository, and used private headers
        to peek in the QML Grid element. This patch changes the QML used to expose the
        information we want to test: number of pages opened and the first page opened.

        * tests/qdeclarativewebview/resources/newwindows.html:
        Added <body> tags. We have no reason to not use them in the test.

        * tests/qdeclarativewebview/resources/newwindows.qml:
        Moved the timer out of the page component, used anchors for setting webview size,
        changed the way we count pages opened. Also changed coding style a bit.

        * tests/qdeclarativewebview/tst_qdeclarativewebview.cpp:
        (tst_QDeclarativeWebView::multipleWindows):
        We now look for properties with the information we want in the rootItem: pagesOpened and
        firstPageOpened.

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

6 years ago2011-05-31 Rafael Brandao <rafael.lobo@openbossa.org>
commit-queue [Wed, 1 Jun 2011 01:47:23 +0000 (01:47 +0000)]
2011-05-31  Rafael Brandao  <rafael.lobo@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] tst_QWebFrame::render() failing
        https://bugs.webkit.org/show_bug.cgi?id=60893

        Due a problem on QPicture (http://bugreports.qt.nokia.com/browse/QTBUG-19496),
        this test was calculating the final geometry incorrectly. As the order between
        a translate and a draw operation could be relevant for it, but not for the
        final rendered result, they were changed on ScrollbarThemeQt::paint.

        * platform/qt/ScrollbarThemeQt.cpp:
        (WebCore::ScrollbarThemeQt::paint):
2011-05-31  Rafael Brandao  <rafael.lobo@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] tst_QWebFrame::render() failing
        https://bugs.webkit.org/show_bug.cgi?id=60893

        The test was expecting the frame contents to be already loaded
        before rendering it into a QPicture. Renamed the test to fit
        its real purpose more accordingly.

        * tests/qwebframe/tst_qwebframe.cpp:
        (tst_QWebFrame::renderGeometry):

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

6 years ago2011-05-30 Caio Marcelo de Oliveira Filho <caio.oliveira@openbossa.org>
Caio Marcelo de Oliveira Filho [Mon, 30 May 2011 19:02:21 +0000 (19:02 +0000)]
2011-05-30  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>

        Reviewed by Andreas Kling.

        [Qt] Fix unnecessary wait in API autotest tst_QWebFrame::scrollbarsOff
        https://bugs.webkit.org/show_bug.cgi?id=61711

        The loadFinished() signal was emitted directly inside the call for setHtml, so
        the test was waiting the loadFinished() signal with a big timeout. Change this by
        a very small timeout and a verification with signal spy.

        In practice, setHtml() will either directly call loadFinished() or queue it to
        the next event loop run, and test will work for both situations.

        * tests/qwebframe/tst_qwebframe.cpp:
        (tst_QWebFrame::scrollbarsOff):

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

6 years ago2011-05-20 Csaba Osztrogonác <ossy@webkit.org>
Csaba Osztrogonác [Fri, 20 May 2011 14:29:17 +0000 (14:29 +0000)]
2011-05-20  Csaba Osztrogonác  <ossy@webkit.org>

        Reviewed by Benjamin Poulain.

        [Qt] tst_QWebElement::style() fails because QWebElement::InlineStyle doesn't work as expected
        https://bugs.webkit.org/show_bug.cgi?id=60372

        * tests/qwebelement/tst_qwebelement.cpp: Mark failing test case as expected fail.
        (tst_QWebElement::style):

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

6 years ago2011-05-20 Csaba Osztrogonác <ossy@webkit.org>
Csaba Osztrogonác [Fri, 20 May 2011 14:27:43 +0000 (14:27 +0000)]
2011-05-20  Csaba Osztrogonác  <ossy@webkit.org>

        Reviewed by Benjamin Poulain.

        [Qt] Fix tst_QDeclarativeWebView::basicProperties() and historyNav() autotests
        https://bugs.webkit.org/show_bug.cgi?id=61042

        * tests/qdeclarativewebview/tst_qdeclarativewebview.cpp: Mark failing test cases as expected fails.
        (tst_QDeclarativeWebView::basicProperties):
        (tst_QDeclarativeWebView::historyNav):

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

6 years ago[Qt] Fix tst_QWebPage::testOptionalJSObjects() autotest
Csaba Osztrogonác [Fri, 20 May 2011 14:19:21 +0000 (14:19 +0000)]
[Qt] Fix tst_QWebPage::testOptionalJSObjects() autotest
https://bugs.webkit.org/show_bug.cgi?id=61045

Reviewed by Benjamin Poulain.

* tests/qwebpage/tst_qwebpage.cpp:
(tst_QWebPage::testOptionalJSObjects): Mark failing test cases as expected fails.

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

6 years ago2011-05-20 Csaba Osztrogonác <ossy@webkit.org>
Csaba Osztrogonác [Fri, 20 May 2011 13:32:03 +0000 (13:32 +0000)]
2011-05-20  Csaba Osztrogonác  <ossy@webkit.org>

        Reviewed by Benjamin Poulain.

        [Qt]Fix tst_QWebFrame::setUrlToInvalid() autotest after r84762
        https://bugs.webkit.org/show_bug.cgi?id=59345

        * tests/qwebframe/tst_qwebframe.cpp:
        (tst_QWebFrame::setUrlToInvalid): Mark failing test cases as expected fails.

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

6 years ago2011-05-10 Ademar de Souza Reis Jr. <ademar.reis@openbossa.org>
Ademar de Souza Reis Junior [Tue, 10 May 2011 15:32:44 +0000 (15:32 +0000)]
2011-05-10  Ademar de Souza Reis Jr.  <ademar.reis@openbossa.org>

        Reviewed by Csaba Osztrogonác.

        [Qt] tst_QWebPage creates temporary files in the current working dir
        https://bugs.webkit.org/show_bug.cgi?id=60497

        tst_QWebPage was using QDir::currentPath when creating temporary dirs
        and leaving them after the test was run. I basically borrowed the fix
        from tst_QDeclarativeWebView.

        * tests/qwebpage/tst_qwebpage.cpp:
        (removeRecursive):
        (tst_QWebPage::tmpDirPath):
        (tst_QWebPage::cleanupFiles):
        (tst_QWebPage::database):
        (tst_QWebPage::multiplePageGroupsAndLocalStorage):

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

6 years ago2011-05-31 Berend-Jan Wever <skylined@chromium.org>
Ademar de Souza Reis Jr [Wed, 1 Jun 2011 17:11:25 +0000 (14:11 -0300)]
2011-05-31  Berend-Jan Wever  <skylined@chromium.org>

        Reviewed by Adam Barth.

        Add test to make sure an error in requestFileSystem or resolveLocalFileSystemURI
        when no error callback is supplied does not cause a NULL ptr.
        https://bugs.webkit.org/show_bug.cgi?id=49539

        * fast/filesystem/filesystem-no-callback-null-ptr-crash.html: Added.
        * fast/filesystem/filesystem-no-callback-null-ptr-crash-expected.txt: Added.
2011-05-31  B.J. Wever  <skylined@chromium.org>

        Reviewed by Adam Barth.

        requestFileSystem and resolveLocalFileSystemURI are not checking if
        errorCallback is NULL before scheduling a callback on error.
        https://bugs.webkit.org/show_bug.cgi?id=49539

        Test: fast/filesystem/filesystem-no-callback-null-ptr-crash.html

        * fileapi/DOMFileSystem.cpp:
        (WebCore::DOMFileSystem::scheduleCallback): Only call callback if
          one is supplied.

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

Conflicts:

Source/WebCore/fileapi/DOMFileSystem.h

6 years ago2011-05-31 Ademar de Souza Reis Jr <ademar.reis@openbossa.org>
Ademar de Souza Reis Junior [Wed, 1 Jun 2011 00:14:56 +0000 (00:14 +0000)]
2011-05-31  Ademar de Souza Reis Jr  <ademar.reis@openbossa.org>

        Reviewed by Simon Hausmann.

        [Qt] User-agent list of Qt test browsers is very outdated
        https://bugs.webkit.org/show_bug.cgi?id=61531

        The user can edit the user-agent manually, so there's no need to have
        a super complete and up to date list, but it's nice to have it
        minimally updated.

        * MiniBrowser/qt/useragentlist.txt:
        * QtTestBrowser/useragentlist.txt:

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

6 years ago2011-05-31 Abhishek Arya <inferno@chromium.org>
Abhishek Arya [Tue, 31 May 2011 16:51:09 +0000 (16:51 +0000)]
2011-05-31  Abhishek Arya  <inferno@chromium.org>

        Reviewed by Dimitri Glazkov.

        Convert raw ptr to RefPtr for documentElement.
        https://bugs.webkit.org/show_bug.cgi?id=61688

        Test: fast/dom/xml-parser-error-message-crash.svg

        * dom/XMLDocumentParser.cpp:
        (WebCore::XMLDocumentParser::insertErrorMessageBlock):
2011-05-31  Abhishek Arya  <inferno@chromium.org>

        Reviewed by Dimitri Glazkov.

        Test that we do not crash when a DOMNodeInsertedIntoDocument event
        is fired while generating a error message block in xml parsing.
        https://bugs.webkit.org/show_bug.cgi?id=61688

        * fast/dom/xml-parser-error-message-crash-expected.txt: Added.
        * fast/dom/xml-parser-error-message-crash.svg: Added.

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

6 years ago2011-05-31 Simon Fraser <simon.fraser@apple.com>
Simon Fraser [Tue, 31 May 2011 14:20:05 +0000 (14:20 +0000)]
2011-05-31  Simon Fraser  <simon.fraser@apple.com>

        Reviewed by Kenneth Rohde Christiansen.

        Frame flattening is broken with nested frames
        https://bugs.webkit.org/show_bug.cgi?id=61491

        * fast/frames/flattening/iframe-flattening-nested.html: Added.
        * fast/frames/flattening/resources/inner-frame.html: Added.
        * fast/frames/flattening/resources/intermediate-frame.html: Added.
        * platform/mac/fast/frames/flattening/iframe-flattening-nested-expected.png: Added.
        * platform/mac/fast/frames/flattening/iframe-flattening-nested-expected.txt: Added.
2011-05-31  Yael Aharon  <yael.aharon@nokia.com>

        Reviewed by Kenneth Rohde Christiansen.

        Frame flattening is broken with nested frames
        https://bugs.webkit.org/show_bug.cgi?id=61491

        After r77988, when frame flattening is enabled, performPostLayoutTasks() is called on a timer for iframes.
        This causes layout of nested iframes to sometimes happen asynchronously, but WebCore expects layout to always finish synchronously.
        Added a call to updateWidgetPosition() for cases that performPostLayoutTasks() is now happening asynchronously.

        Test: fast/frames/flattening/iframe-flattening-nested.html

        * page/FrameView.cpp:
        (WebCore::FrameView::layout):

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

6 years ago[Qt] Implement find feature for QtTestBrowser
Csaba Osztrogonác [Tue, 31 May 2011 13:32:46 +0000 (13:32 +0000)]
[Qt] Implement find feature for QtTestBrowser
https://bugs.webkit.org/show_bug.cgi?id=61425

Patch by Kristóf Kosztyó <Kosztyo.Kristof@stud.u-szeged.hu> on 2011-05-31
Reviewed by Csaba Osztrogonác.

Buildfix for --minimal and CONFIG+=qt_minimal build.

* QtTestBrowser/launcherwindow.cpp:
(LauncherWindow::LauncherWindow):
(LauncherWindow::createChrome):
* QtTestBrowser/launcherwindow.h:

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

6 years agoBuild fix after r86418
Adam Roben [Fri, 13 May 2011 14:38:00 +0000 (14:38 +0000)]
Build fix after r86418

* platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.h:
Made the destructor public so that this class can be used with
[Pass]OwnPtr.

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

6 years ago2011-05-13 Patrick Gansterer <paroga@webkit.org>
Patrick Gansterer [Fri, 13 May 2011 07:37:50 +0000 (07:37 +0000)]
2011-05-13  Patrick Gansterer  <paroga@webkit.org>

        Reviewed by Adam Barth.

        Enable OwnPtr strict mode in MediaPlayer
        https://bugs.webkit.org/show_bug.cgi?id=59466

        Let the CreateMediaEnginePlayer function return a PassOwnPtr instead of a raw pointer.
        Also fix the templete argument of OwnPtr for the m_private member variable.

        * platform/graphics/MediaPlayer.cpp:
        (WebCore::MediaPlayer::MediaPlayer):
        (WebCore::MediaPlayer::loadWithNextMediaEngine):
        * platform/graphics/MediaPlayer.h:
        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.h:
        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm:
        (WebCore::MediaPlayerPrivateAVFoundationObjC::create):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
        (WebCore::MediaPlayerPrivateGStreamer::create):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
        * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
        * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
        (WebCore::MediaPlayerPrivateQTKit::create):
        * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
        (WebCore::MediaPlayerPrivatePhonon::create):
        * platform/graphics/qt/MediaPlayerPrivatePhonon.h:
        * platform/graphics/qt/MediaPlayerPrivateQt.cpp:
        (WebCore::MediaPlayerPrivateQt::create):
        * platform/graphics/qt/MediaPlayerPrivateQt.h:
        * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
        (WebCore::MediaPlayerPrivateQuickTimeVisualContext::create):
        * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h:
        * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
        (WebCore::MediaPlayerPrivate::create):
        * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h:
        * platform/graphics/wince/MediaPlayerPrivateWinCE.h:
2011-05-13  Patrick Gansterer  <paroga@webkit.org>

        Reviewed by Adam Barth.

        Enable OwnPtr strict mode in MediaPlayer
        https://bugs.webkit.org/show_bug.cgi?id=59466

        Let the CreateMediaEnginePlayer function return a PassOwnPtr instead of a raw pointer.
        Also fix the templete argument of OwnPtr for the m_private member variable.

        * src/WebMediaPlayerClientImpl.cpp:
        (WebKit::WebMediaPlayerClientImpl::create):
        * src/WebMediaPlayerClientImpl.h:

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

6 years ago2011-05-12 Maciej Stachowiak <mjs@apple.com>
Patrick Gansterer [Thu, 12 May 2011 21:56:45 +0000 (21:56 +0000)]
2011-05-12  Maciej Stachowiak  <mjs@apple.com>

        Reviewed by Darin Adler.

        XMLDocumentParserLibxml2 should play nice with strict OwnPtrs
        https://bugs.webkit.org/show_bug.cgi?id=59394

        This portion of the change introduces a PassTraits template, which
        is used to enable takeFirst() to work for a Deque holding OwnPtrs,
        and optimize it for a Deque holding RefPtrs. In the future it can
        be deployed elsewhere to make our data structures work better with
        our smart pointers.

        * GNUmakefile.list.am:
        * JavaScriptCore.gypi:
        * JavaScriptCore.vcproj/WTF/WTF.vcproj:
        * JavaScriptCore.xcodeproj/project.pbxproj:
        * wtf/CMakeLists.txt:
        * wtf/Deque.h:
        (WTF::::takeFirst):
        * wtf/PassTraits.h: Added.
        (WTF::PassTraits::transfer):
2011-05-12  Maciej Stachowiak  <mjs@apple.com>

        Reviewed by Darin Adler.

        XMLDocumentParserLibxml2 should play nice with strict OwnPtrs
        https://bugs.webkit.org/show_bug.cgi?id=59394

        Properly fix this (formerly rolled out for breaking the build). I think the original
        failure had nothing to do with Deque<OwnPtr>, which in fact appears to work fine.

        * dom/XMLDocumentParserLibxml2.cpp:
        (WebCore::PendingCallbacks::~PendingCallbacks):
        (WebCore::PendingCallbacks::create):
        (WebCore::PendingCallbacks::appendStartElementNSCallback):
        (WebCore::PendingCallbacks::appendEndElementNSCallback):
        (WebCore::PendingCallbacks::appendCharactersCallback):
        (WebCore::PendingCallbacks::appendProcessingInstructionCallback):
        (WebCore::PendingCallbacks::appendCDATABlockCallback):
        (WebCore::PendingCallbacks::appendCommentCallback):
        (WebCore::PendingCallbacks::appendInternalSubsetCallback):
        (WebCore::PendingCallbacks::appendErrorCallback):
        (WebCore::PendingCallbacks::PendingCallbacks):
        (WebCore::XMLDocumentParser::XMLDocumentParser):

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

6 years ago2011-05-31 Oleg Romashin <oleg.romashin@nokia.com>
commit-queue [Tue, 31 May 2011 12:43:11 +0000 (12:43 +0000)]
2011-05-31  Oleg Romashin  <oleg.romashin@nokia.com>

        Reviewed by Benjamin Poulain.

        Fix compilation with debug enabled, m_lightSource.type is not valid anymore
        https://bugs.webkit.org/show_bug.cgi?id=61719

        * platform/graphics/filters/arm/FELightingNEON.h:
        (WebCore::FELighting::platformApplyNeon):

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

6 years ago2011-05-31 Kristóf Kosztyó <Kosztyo.Kristof@stud.u-szeged.hu>
commit-queue [Tue, 31 May 2011 10:42:01 +0000 (10:42 +0000)]
2011-05-31  Kristóf Kosztyó  <Kosztyo.Kristof@stud.u-szeged.hu>

        Reviewed by Csaba Osztrogonác.

        [Qt] Implement find feature for QtTestBrowser
        https://bugs.webkit.org/show_bug.cgi?id=61425

        * QtTestBrowser/launcherwindow.cpp:
        (LauncherWindow::LauncherWindow):
        (LauncherWindow::createChrome):
        (LauncherWindow::showFindBar):
        (LauncherWindow::find):
        * QtTestBrowser/launcherwindow.h:

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

6 years ago2011-05-12 Daniel Bates <dbates@rim.com>
Daniel Bates [Fri, 13 May 2011 00:25:01 +0000 (00:25 +0000)]
2011-05-12  Daniel Bates  <dbates@rim.com>

        Attempt to fix the build after changeset 86391<http://trac.webkit.org/changeset/86391>
        (https://bugs.webkit.org/show_bug.cgi?id=60681).

        * page/PluginHalter.cpp:
        (WebCore::PluginHalter::PluginHalter): Substitute m_client for client in ASSERT_ARG since client is now of type PassOwnPtr
        so it becomes 0 when assigned to another variable.

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

6 years ago2011-05-12 Patrick Gansterer <paroga@webkit.org>
Patrick Gansterer [Thu, 12 May 2011 23:06:09 +0000 (23:06 +0000)]
2011-05-12  Patrick Gansterer  <paroga@webkit.org>

        Reviewed by Adam Barth.

        Enable OwnPtr strict mode in PluginHalter
        https://bugs.webkit.org/show_bug.cgi?id=60681

        Pass PluginHalterClient as (Pass)OwnPtr to Page and PluginHalter.

        * WebCore.exp.in:
        * page/Page.cpp:
        (WebCore::Page::Page):
        (WebCore::Page::PageClients::PageClients):
        * page/Page.h:
        * page/PluginHalter.cpp:
        (WebCore::PluginHalter::PluginHalter):
        * page/PluginHalter.h:
2011-05-12  Patrick Gansterer  <paroga@webkit.org>

        Reviewed by Adam Barth.

        Enable OwnPtr strict mode in PluginHalter
        https://bugs.webkit.org/show_bug.cgi?id=60681

        * WebView/WebView.mm:
        (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]):
2011-05-12  Patrick Gansterer  <paroga@webkit.org>

        Reviewed by Adam Barth.

        Enable OwnPtr strict mode in PluginHalter
        https://bugs.webkit.org/show_bug.cgi?id=60681

        * WebView.cpp:
        (WebView::initWithFrame):

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

6 years ago Suggested by Simon Fraser. qtwebkit-2.2-week21
Alexey Proskuryakov [Sun, 29 May 2011 04:42:18 +0000 (04:42 +0000)]
    Suggested by Simon Fraser.

        REGRESSION (r85375): Load event is sometimes lost when multiple image elements use the same URL
        https://bugs.webkit.org/show_bug.cgi?id=61692
        <rdar://problem/9488628>

        * loader/ImageLoader.cpp: (WebCore::ImageLoader::notifyFinished): There was no need to use
        ASSERT_UNUSED here.

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

6 years ago Reviewed by Geoff Garen.
Alexey Proskuryakov [Sun, 29 May 2011 01:37:59 +0000 (01:37 +0000)]
    Reviewed by Geoff Garen.

        REGRESSION (r85375): Load event is sometimes lost when multiple image elements use the same URL
        https://bugs.webkit.org/show_bug.cgi?id=61692
        <rdar://problem/9488628>

        Test: fast/dom/gc-image-element-2.html

        Manually verified that tests from bug 59604 and from bug 40926 still pass.

        The problem here was that HTMLImageElement::hasPendingActivity() could return false when
        a load (or error) event was still expected to fire.

        * loader/cache/CachedResource.cpp:
        (WebCore::CachedResource::setRequest):
        * loader/cache/CachedResource.h:
        (WebCore::CachedResource::wasCanceled):
        (WebCore::CachedResource::errorOccurred):
        Track whether the load was canceled. We want to always notify clients of load outcome,
        as that's the only way they could make intelligent decisions.

        * dom/ScriptElement.cpp: (WebCore::ScriptElement::execute): Cached resource clients now
        get a notifyFinished call on cancellation. Handle this case, where we don't need the
        execute the script, but also don't need to fire an error event.

        * html/HTMLImageElement.cpp: Moved hasPendingActivity() to header, since it's just a single
        function call now.

        * html/HTMLImageElement.h: (WebCore::HTMLImageElement::hasPendingActivity): There is a large
        window between when CachedResource::isLoading() becomes false and events are queued.
        ImageLoader::haveFiredLoadEvent() is a much better indication of whether we are expecting
        an event to fire.

        * html/HTMLLinkElement.cpp: (WebCore::HTMLLinkElement::onloadTimerFired): Again, don't do
        anything on cancellation.

        * loader/ImageLoader.cpp:
        (WebCore::ImageEventSender::hasPendingEvents): Made it debug-only again, and fixed to
        give an accurate result while looping over the list of events to dispatch.
        (WebCore::ImageLoader::notifyFinished): Don't do anything when cancelled. We don't want to
        switch to a broken image icon, or to dispatch events.
        (WebCore::ImageEventSender::dispatchPendingEvents): Clear the current loader from dispatching
        list, as the event is no longer pending when it's being dispatched.

        * loader/ImageLoader.h: Removed unnecessary hasPendingLoadEvent(). We don't care whether one
        is already pending, we only care if one is expected at some time in the future, and
        !haveFiredLoadEvent() is our best idea of that.

        * dom/XMLDocumentParser.cpp: (WebCore::XMLDocumentParser::notifyFinished): Another place to
        handle cancellation.

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

6 years ago2011-05-23 Syed Idris Shah <syed.idris-shah@nokia.com>
commit-queue [Mon, 23 May 2011 08:07:04 +0000 (08:07 +0000)]
2011-05-23  Syed Idris Shah  <syed.idris-shah@nokia.com>

        Reviewed by Andreas Kling.

        GraphicsContext3DInternal object should be called for getAttachedShaders.
        [Qt] fast/canvas/webgl/gl-object-get-calls.html crash for Qt based webkit
        https://bugs.webkit.org/show_bug.cgi?id=61202

        LayoutTests/fast/canvas/webgl/gl-object-get-calls.html

        getAttachedShaders should be called on GraphicsContext3DInternal instance.
        It was left out by mistake.

        * platform/graphics/qt/GraphicsContext3DQt.cpp:
        (WebCore::GraphicsContext3D::getAttachedShaders): GraphicsContext3DInternal instance should be called.

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

6 years ago2011-05-27 Alexis Menard <alexis.menard@openbossa.org>
Alexis Menard [Fri, 27 May 2011 15:34:17 +0000 (15:34 +0000)]
2011-05-27  Alexis Menard  <alexis.menard@openbossa.org>

        Reviewed by Csaba Osztrogonác.

        [Qt] Fix tst_QGraphicsWebView::setPalette(inactiveBG) autotest
        https://bugs.webkit.org/show_bug.cgi?id=61044

        Make sure to set the active window on the application too.

        * tests/qgraphicswebview/tst_qgraphicswebview.cpp:
        (tst_QGraphicsWebView::setPalette):

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

6 years ago2011-05-26 MORITA Hajime <morrita@google.com>
MORITA Hajime [Fri, 27 May 2011 07:26:34 +0000 (07:26 +0000)]
2011-05-26  MORITA Hajime <morrita@google.com>

        Reviewed by Kent Tamura.

        WebCore::HTMLSummaryElement::isMainSummary crashes
        https://bugs.webkit.org/show_bug.cgi?id=61511

        * fast/html/details-summary-document-child-expected.txt: Added.
        * fast/html/details-summary-document-child.html: Added.
2011-05-26  MORITA Hajime  <morrita@google.com>

        Reviewed by Kent Tamura.

        WebCore::HTMLSummaryElement::isMainSummary ReadAV@NULL
        https://bugs.webkit.org/show_bug.cgi?id=61511

        Removed Unnecessary wrong cast to Elmement, which can be non-Element.

        Test: fast/html/details-summary-document-child.html

        * html/HTMLSummaryElement.cpp:
        (WebCore::HTMLSummaryElement::detailsElement):

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

6 years ago2011-05-26 Shane Stephens <shanestephens@google.com>
Ademar de Souza Reis Jr [Fri, 27 May 2011 18:01:30 +0000 (15:01 -0300)]
2011-05-26  Shane Stephens  <shanestephens@google.com>

        Reviewed by James Robinson.

        REGRESSION (r81992): layout triggered by position update fails to apply when transform is updated at same time
        https://bugs.webkit.org/show_bug.cgi?id=60689

        * transforms/2d/set-transform-and-top-expected.txt: Added.
        * transforms/2d/set-transform-and-top.html: Added.
2011-05-26  Shane Stephens  <shanestephens@google.com>

        Reviewed by James Robinson.

        REGRESSION (r81992): layout triggered by position update fails to apply when transform is updated at same time
        https://bugs.webkit.org/show_bug.cgi?id=60689

        When a transform is modified in a style, we were upgrading our understanding
        of the difference from PositionedMovementOnly to SimplifiedLayout.  However,
        if the position of the style is independently changed at the same time, both
        PositionedMovement and SimplifiedLayout passes are required.

        Test: transforms/2d/set-transform-and-top.html

        * rendering/RenderObject.cpp:
        Added checks for SimplifiedLayoutAndPositionedMovement - when encountered,
        set both PositionedMovement and SimplifiedLayout update flasgs.
        * rendering/style/RenderStyleConstants.h:
        Added a new StyleDifference enum value (SimplifiedLayoutAndPositionedMovement) for
        cases when both PositionedMovement and SimplifiedLayout are required.

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

Conflicts:

Source/WebCore/ChangeLog