profile/ivi/webkit-efl.git
12 years ago[Chromium] CTFontCopyTable of MacOSX10.5 SDK doesn't work for layout tables
bashi@chromium.org [Fri, 29 Jun 2012 02:37:43 +0000 (02:37 +0000)]
[Chromium] CTFontCopyTable of MacOSX10.5 SDK doesn't work for layout tables
https://bugs.webkit.org/show_bug.cgi?id=90235

Reviewed by Kent Tamura.

Use CGFontCopyTableForTag instead.

No new tests. css3/font-feature-settings-rendering.html should pass. I'll rebase expectations once bots get the result.

* platform/graphics/harfbuzz/ng/HarfBuzzFaceCoreText.cpp:
(WebCore::harfbuzzCoreTextGetTable):

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

12 years agonrwt: clean up how arguments are passed to workers
dpranke@chromium.org [Fri, 29 Jun 2012 02:37:04 +0000 (02:37 +0000)]
nrwt: clean up how arguments are passed to workers
https://bugs.webkit.org/show_bug.cgi?id=90126

Reviewed by Ojan Vafai.

The way arguments are passed to workers has been crufty. It
turns out it can be a lot cleaner via two things:
1) using a factory method instead of instantiating objects
directly in manager_worker_broker removes the need for passing
'worker arguments' to the broker.
2) it turns out that since mock hosts and test ports are purely
in-memory constructions, they can be pickled and passed to child
workers, meaning that the worker no longer needs hacky code to
pass the port in a special case or to guess what to do if we
don't have a host - all of the test-specific logic can move to
the test file, where we can stub out the mock host's
port_factory to return the same already-created port when it
needs to be shared.

This change also moves WorkerException to manager_worker_broker.py
where it belongs, and removes several useless tests that were
just a maintenance burden (and would've needed rewriting when we
change the rest of the broker implementation).

* Scripts/webkitpy/layout_tests/controllers/manager.py:
(Manager._run_tests.worker_factory):
(Manager._run_tests):
* Scripts/webkitpy/layout_tests/controllers/manager_worker_broker.py:
(get):
(WorkerException):
(AbstractWorker.__init__):
(_ManagerConnection.__init__):
(_ManagerConnection.start_worker):
(_InlineManager.__init__):
(_InlineManager.start_worker):
(_MultiProcessManager._can_pickle_host):
(_MultiProcessManager):
(_MultiProcessManager.start_worker):
(_WorkerConnection.__init__):
(_InlineWorkerConnection.__init__):
(_InlineWorkerConnection.join):
(_InlineWorkerConnection.run):
(_Process.run):
(_MultiProcessWorkerConnection.__init__):
(_MultiProcessWorkerConnection.start):
(_MultiProcessWorkerConnection):
(_MultiProcessWorkerConnection.run):
* Scripts/webkitpy/layout_tests/controllers/manager_worker_broker_unittest.py:
(_TestWorker.__init__):
(_TestWorker.run):
(_TestsMixin.test_name):
(_TestsMixin.test_cancel):
(_TestsMixin.test_done):
(_TestsMixin.test_unknown_message):
(InlineBrokerTests.setUp):
(MultiProcessBrokerTests.setUp):
* Scripts/webkitpy/layout_tests/controllers/worker.py:
(Worker.__init__):
(Worker.run):
* Scripts/webkitpy/layout_tests/controllers/worker_unittest.py: Removed.
* Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py:
(passing_run):
(logging_run):
(run_and_capture):
(MainTest.test_child_processes_2):
(MainTest.test_child_processes_min):
(MainTest.test_exception_raised):
(MainTest.test_keyboard_interrupt):
(MainTest.test_retrying_and_flaky_tests):
(MainTest.test_run_order__inline):

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

12 years agoAdd preventative assert in SVGTRefElement
pdr@google.com [Fri, 29 Jun 2012 02:36:06 +0000 (02:36 +0000)]
Add preventative assert in SVGTRefElement
https://bugs.webkit.org/show_bug.cgi?id=90203

Reviewed by Abhishek Arya.

SVGTRefElement::detachTarget() adds a pending resource via addPendingResource.
Due to some recent bugs in this area, an assert is being added to prevent
users from calling detachTarget when not in a document. Doing
so would create a bug such as in WK90042.

This assert will not fire currently because detachTarget is only called after
a DOMNodeRemovedFromDocumentEvent event fires, which only comes from
dispatchChildRemovalEvents when the node is in a document.

* svg/SVGTRefElement.cpp:
(WebCore::SVGTRefElement::detachTarget):

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

12 years agonrwt: don't try to catch worker exceptions in run_webkit_tests.__main__
dpranke@chromium.org [Fri, 29 Jun 2012 02:13:39 +0000 (02:13 +0000)]
nrwt: don't try to catch worker exceptions in run_webkit_tests.__main__
https://bugs.webkit.org/show_bug.cgi?id=90125

Reviewed by Ojan Vafai.

It turns out run_webkit_tests.py wasn't really using
WorkerException and the catch we had for it was pointless. I've
removed the symbol import and moved it to the integration tests
where it is needed. Eventually the definition of the exception
moves to the broker module, and so minimizing the number of
users of it is a good thing.

* Scripts/webkitpy/layout_tests/run_webkit_tests.py:
* Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py:
(MainTest.test_exception_raised):

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

12 years agoUnreviewed gardening.
mikelawther@chromium.org [Fri, 29 Jun 2012 02:09:54 +0000 (02:09 +0000)]
Unreviewed gardening.

Mark css3/calc/transitions.html flaky (http://webkit.org/b/90234)

* platform/chromium/TestExpectations:
* platform/mac/TestExpectations:

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

12 years agonrwt: clean up passing of log messages between processes
dpranke@chromium.org [Fri, 29 Jun 2012 01:59:40 +0000 (01:59 +0000)]
nrwt: clean up passing of log messages between processes
https://bugs.webkit.org/show_bug.cgi?id=90123

Reviewed by Ojan Vafai.

It turns out log messages are perfectly picklable by themselves
and contain the process id of the process that generated the
message, so if we just pass the record from the worker to the
manager and call logger.handle() in the manager, everything just
works :).

The change is covered by existing tests.

* Scripts/webkitpy/layout_tests/controllers/manager.py:
(Manager._log_messages):
* Scripts/webkitpy/layout_tests/controllers/worker.py:
(_WorkerLogHandler.emit):
* Scripts/webkitpy/layout_tests/views/metered_stream.py:
(MeteredStream.__init__):
(_LogHandler.emit):

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

12 years agoMake sure master umask is set correctly
wsiegrist@apple.com [Fri, 29 Jun 2012 01:56:41 +0000 (01:56 +0000)]
Make sure master umask is set correctly

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

12 years ago[Qt] Remove unnecessary AffineTransform calls
commit-queue@webkit.org [Fri, 29 Jun 2012 01:45:34 +0000 (01:45 +0000)]
[Qt] Remove unnecessary AffineTransform calls
https://bugs.webkit.org/show_bug.cgi?id=90178

Patch by Bruno de Oliveira Abinader <bruno.abinader@basyskom.com> on 2012-06-28
Reviewed by Noam Rosenthal.

Qt currently ignores the const AffineTransform& parameter on
Pattern::createPlatformPattern, so removing it from all its Qt calls and
changing the function signature if platform is Qt.

* platform/graphics/Pattern.h:
(Pattern):
* platform/graphics/qt/FontQt.cpp:
(WebCore::fillPenForContext):
(WebCore::strokePenForContext):
* platform/graphics/qt/FontQt4.cpp:
(WebCore::fillPenForContext):
(WebCore::strokePenForContext):
* platform/graphics/qt/GraphicsContextQt.cpp:
(WebCore::GraphicsContext::fillPath):
(WebCore::GraphicsContext::strokePath):
(WebCore::drawRepeatPattern):
* platform/graphics/qt/PatternQt.cpp:
(WebCore::Pattern::createPlatformPattern):

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

12 years agoadd a pylint wrapper for linting python code
dpranke@chromium.org [Fri, 29 Jun 2012 01:45:20 +0000 (01:45 +0000)]
add a pylint wrapper for linting python code
https://bugs.webkit.org/show_bug.cgi?id=90232

Reviewed by Adam Barth.

Currently we use 'pep8' to check python code in
check-webkit-style. pep8 is fast but simple; pylint is slower
but has much more robust linting capabilities and will catch
variable typos and all sorts of other things. Eventually we
should switch check-webkit-style to use this, but our code is
far from linting now so it needs to be cleaned up first.

This change adds the infrastructure and a wrapper so we can
start doing that.

* Scripts/lint-webkitpy: Added.
* Scripts/webkitpy/pylintrc: Added.
* Scripts/webkitpy/thirdparty/__init__.py:
(AutoinstallImportHook.find_module):
(AutoinstallImportHook._install_pylint):

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

12 years ago[Qt] When uploading an opaque image to a texture for TextureMapper, unnecessary alpha...
noam.rosenthal@nokia.com [Fri, 29 Jun 2012 01:42:32 +0000 (01:42 +0000)]
[Qt] When uploading an opaque image to a texture for TextureMapper, unnecessary alpha operations take place
https://bugs.webkit.org/show_bug.cgi?id=90229

Reviewed by Luiz Agostini.

For opaque web content in WebKit2, we use the RGB32 image format. When we special-case
it in GraphicsContext3DQt, we can avoid any alpha operations and perform a regular copy.

Covered existing API tests, as this code path is always used when rendering.

* platform/graphics/qt/GraphicsContext3DQt.cpp:
(WebCore::GraphicsContext3D::getImageData):

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

12 years ago[chromium] Compile chromium compositor implementation files into separate .lib
jamesr@google.com [Fri, 29 Jun 2012 01:30:33 +0000 (01:30 +0000)]
[chromium] Compile chromium compositor implementation files into separate .lib
https://bugs.webkit.org/show_bug.cgi?id=90233

Reviewed by Adam Barth.

* WebCore.gyp/WebCore.gyp:

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

12 years ago[GTK] Use WEBKITOUTPUTDIR to find fonts in DumpRenderTree
tony@chromium.org [Fri, 29 Jun 2012 01:18:34 +0000 (01:18 +0000)]
[GTK] Use WEBKITOUTPUTDIR to find fonts in DumpRenderTree
https://bugs.webkit.org/show_bug.cgi?id=90215

Reviewed by Martin Robinson.

* DumpRenderTree/gtk/DumpRenderTree.cpp:
(initializeFonts): Check for WEBKITOUTPUTDIR first.
* Scripts/webkitpy/layout_tests/port/gtk.py:
(GtkPort.setup_environ_for_server): Copy the environment variable to the child process.
* WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp:
(WTR::inititializeFontConfigSetting): Check for WEBKITOUTPUTDIR first.

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

12 years agoSwitch master ditto command to unzip since the new master does not have ditto.
wsiegrist@apple.com [Fri, 29 Jun 2012 01:18:18 +0000 (01:18 +0000)]
Switch master ditto command to unzip since the new master does not have ditto.

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

12 years agoderive ChromiumPort from WebKitPort in NRWT in order to support skipping tests if...
dpranke@chromium.org [Fri, 29 Jun 2012 01:14:24 +0000 (01:14 +0000)]
derive ChromiumPort from WebKitPort in NRWT in order to support skipping tests if symbols are missing
https://bugs.webkit.org/show_bug.cgi?id=89706

Reviewed by Ojan Vafai.

Try again to land the change first landed in r121363. This patch
adds a bunch more tests and reworks the handling of
port-specific default values for --pixel-tests and --time-out-ms
to be more consistent (adding a default_pixel_tests() method,
pushing the webkit default_timeout_ms() value up into base.py,
and overriding it properly in the chromium and apple mac ports.

Also change the logic in
run_webkit_tests._setup_derived_options() to not second-guess
what the port wants the timeout value to be for debug builds;
computing this in two different places led to several bugs.

This change also changes the Chromium unittest ports to derive
from ChromiumPortTestCase instead of PortTestCase, so that we
ensure that we're running the same tests on all port variants
more easily. There's more cleanup that can be done here, but
this is good enough for now

* Scripts/webkitpy/layout_tests/port/base.py:
(Port.default_pixel_tests):
(Port):
(Port.default_timeout_ms):
* Scripts/webkitpy/layout_tests/port/chromium.py:
(ChromiumPort):
(ChromiumPort.__init__):
(ChromiumPort.default_pixel_tests):
(ChromiumPort.default_timeout_ms):
(ChromiumPort.driver_name):
(ChromiumPort._driver_class):
(ChromiumPort._missing_symbol_to_skipped_tests):
(ChromiumPort.skipped_layout_tests):
(ChromiumPort.setup_test_run):
(ChromiumPort._path_to_image_diff):
(ChromiumPort._convert_path):
* Scripts/webkitpy/layout_tests/port/chromium_android_unittest.py:
(ChromiumAndroidPortTest):
(ChromiumAndroidPortTest.test_expectations_files):
* Scripts/webkitpy/layout_tests/port/chromium_linux.py:
(ChromiumLinuxPort._modules_to_search_for_symbols):
* Scripts/webkitpy/layout_tests/port/chromium_linux_unittest.py:
(ChromiumLinuxPortTest):
* Scripts/webkitpy/layout_tests/port/chromium_mac.py:
(ChromiumMacPort._modules_to_search_for_symbols):
* Scripts/webkitpy/layout_tests/port/chromium_mac_unittest.py:
(ChromiumMacPortTest):
* Scripts/webkitpy/layout_tests/port/chromium_port_testcase.py:
split off from chromium_unittest.
* Scripts/webkitpy/layout_tests/port/chromium_win.py:
(ChromiumWinPort._modules_to_search_for_symbols):
* Scripts/webkitpy/layout_tests/port/chromium_win_unittest.py:
(ChromiumWinTest):
* Scripts/webkitpy/layout_tests/port/mac.py:
(MacPort.default_timeout_ms):
* Scripts/webkitpy/layout_tests/port/mac_unittest.py:
(MacTest.test_default_timeout_ms):
* Scripts/webkitpy/layout_tests/port/mock_drt.py:
(MockDRTPort.start_http_server):
* Scripts/webkitpy/layout_tests/port/port_testcase.py:
(PortTestCase.test_default_timeout_ms):
(PortTestCase):
(PortTestCase.test_default_pixel_tests):
* Scripts/webkitpy/layout_tests/port/test.py:
(TestPort.default_pixel_tests):
* Scripts/webkitpy/layout_tests/port/webkit.py:
(WebKitPort._modules_to_search_for_symbols):
(WebKitPort):
(WebKitPort._symbols_string):
(WebKitPort._skipped_tests_for_unsupported_features):
* Scripts/webkitpy/layout_tests/port/webkit_unittest.py:
(TestWebKitPort._symbols_string):
(TestWebKitPort._tests_for_disabled_features):
* Scripts/webkitpy/layout_tests/run_webkit_tests.py:
(_set_up_derived_options):

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

12 years ago[V8] NodeList wrappers are not kept alive as needed
arv@chromium.org [Fri, 29 Jun 2012 01:13:44 +0000 (01:13 +0000)]
[V8] NodeList wrappers are not kept alive as needed
https://bugs.webkit.org/show_bug.cgi?id=90194

Reviewed by Ojan Vafai.

Source/WebCore:

We need to add custom reachability code for DynamicNodeLists. If the owner of
a DynamicNodeList is reachable then the DynamicNodeList must also be reachable.

Test: fast/dom/NodeList/nodelist-reachable.html

* bindings/v8/custom/V8NodeListCustom.cpp:
(WebCore::V8NodeList::visitDOMWrapper): AddImplicitReferences from the owner wrapper.
(WebCore):
* dom/NodeList.idl:

LayoutTests:

* fast/dom/NodeList/nodelist-reachable-expected.txt: Added.
* fast/dom/NodeList/nodelist-reachable.html: Added.
* platform/chromium/fast/dom/NodeList/nodelist-reachable-expected.txt: Added.

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

12 years agoAdd a test for a 'user-modify' css property of distributed nodes.
hayato@chromium.org [Fri, 29 Jun 2012 00:59:37 +0000 (00:59 +0000)]
Add a test for a 'user-modify' css property of distributed nodes.
https://bugs.webkit.org/show_bug.cgi?id=90197

Reviewed by Ryosuke Niwa.

* fast/dom/shadow/user-modify-inheritance-expected.txt:
* fast/dom/shadow/user-modify-inheritance.html:

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

12 years agoframeborder="no" on frameset is ignored if border attribute set
commit-queue@webkit.org [Fri, 29 Jun 2012 00:55:47 +0000 (00:55 +0000)]
frameborder="no" on frameset is ignored if border attribute set
https://bugs.webkit.org/show_bug.cgi?id=17767

Patch by Elliott Sprehn <esprehn@gmail.com> on 2012-06-28
Reviewed by Tony Chang.

Source/WebCore:

Fixes <frameset> frameborder and border handling. Previously we'd
override the frameborder=no setting if border was set. We also
treated frameborder="anything" the same as frameborder=0 since we
we just converted it to a number so frameborder=yes was incorrectly
treated the same as frameborder=no.

Tests: fast/frames/frameset-frameborder-boolean-values.html
       fast/frames/frameset-frameborder-inheritance.html
       fast/frames/frameset-frameborder-overrides-border.html

* html/HTMLFrameSetElement.cpp: Proper parsing of yes,no,1,0 values.
(WebCore::HTMLFrameSetElement::parseAttribute):
* html/HTMLFrameSetElement.h:
(WebCore::HTMLFrameSetElement::border): Border should be 0 if frameborder=no.

LayoutTests:

Add lots of tests for <frameset> frameborder and border handling.

* fast/frames/frameset-frameborder-boolean-values-expected.txt: Added.
* fast/frames/frameset-frameborder-boolean-values.html: Added.
* fast/frames/frameset-frameborder-inheritance-expected.txt: Added.
* fast/frames/frameset-frameborder-inheritance.html: Added.
* fast/frames/frameset-frameborder-overrides-border-expected.txt: Added.
* fast/frames/frameset-frameborder-overrides-border.html: Added.

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

12 years agorun-bindings-tests should return non-zero exit code on test failure
jsbell@chromium.org [Fri, 29 Jun 2012 00:47:49 +0000 (00:47 +0000)]
run-bindings-tests should return non-zero exit code on test failure
https://bugs.webkit.org/show_bug.cgi?id=90205

Reviewed by Adam Barth.

* Scripts/run-bindings-tests:
(main):

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

12 years agoIndexedDB: Implement IDBTransaction internal active flag
jsbell@chromium.org [Fri, 29 Jun 2012 00:38:08 +0000 (00:38 +0000)]
IndexedDB: Implement IDBTransaction internal active flag
https://bugs.webkit.org/show_bug.cgi?id=89379

Reviewed by Tony Chang.

Source/WebCore:

IDB transactions should only be "active" during IDB success/error callbacks;
attempts to make new requests otherwise (e.g. in a setTimeout callback)
should fail even if the transaction has not yet finished. Implement this logic,
and the closely related requirement that transactions are deactivated when
the context they were created in returns to the event loop, and finally that
when so deactivated they should commit rather than abort (as previously
implemented) if no requests have been filed.

Tests: storage/indexeddb/transaction-active-flag.html
       storage/indexeddb/transaction-complete-with-js-recursion-cross-frame.html
       storage/indexeddb/transaction-complete-with-js-recursion.html
       storage/indexeddb/transaction-complete-workers.html

* Modules/indexeddb/IDBPendingTransactionMonitor.cpp: Simplify API.
(WebCore::transactions):
(WebCore::IDBPendingTransactionMonitor::addNewTransaction):
(WebCore::IDBPendingTransactionMonitor::deactivateNewTransactions):
* Modules/indexeddb/IDBPendingTransactionMonitor.h:
(WebCore):
(IDBPendingTransactionMonitor):
* Modules/indexeddb/IDBRequest.cpp: Unregisters from transaction when done,
not on destruction. No longer responsible for working with the pending monitor.
(WebCore::IDBRequest::IDBRequest):
(WebCore::IDBRequest::~IDBRequest):
(WebCore::IDBRequest::markEarlyDeath):
(WebCore::IDBRequest::resetReadyState):
(WebCore::IDBRequest::onSuccess):
(WebCore::IDBRequest::dispatchEvent): Set active flag on transaction during callback.
* Modules/indexeddb/IDBTransaction.cpp: Use state enum to better track lifecycle, and
take ownership of relationship with pending monitor.
(WebCore::IDBTransaction::IDBTransaction): Special cases for version change
transactions.
(WebCore::IDBTransaction::~IDBTransaction):
(WebCore::IDBTransaction::error):
(WebCore::IDBTransaction::setError):
(WebCore::IDBTransaction::objectStore):
(WebCore::IDBTransaction::objectStoreCreated):
(WebCore::IDBTransaction::objectStoreDeleted):
(WebCore::IDBTransaction::setActive): Let IDBRequest and IDBPendingTransactionMonitor
toggle the active state. Needs some smarts because (1) state may move to Finishing during
the request's dispatch phase due to an implicit/explicit abort, and (2) a monitor call
will only trigger a commit if the transaction hasn't had any requests filed.
(WebCore):
(WebCore::IDBTransaction::abort):
(WebCore::IDBTransaction::registerRequest):
(WebCore::IDBTransaction::unregisterRequest):
(WebCore::IDBTransaction::onAbort):
(WebCore::IDBTransaction::onComplete):
(WebCore::IDBTransaction::hasPendingActivity):
(WebCore::IDBTransaction::dispatchEvent):
(WebCore::IDBTransaction::canSuspend):
(WebCore::IDBTransaction::enqueueEvent):
* Modules/indexeddb/IDBTransaction.h:
(WebCore::IDBTransaction::isFinished):
(IDBTransaction):
* Modules/indexeddb/IDBTransactionBackendImpl.cpp:
(WebCore::IDBTransactionBackendImpl::commit): Allow explicit commit() calls from the front end
if no requests have been filed.
* Modules/indexeddb/IDBTransactionBackendInterface.h:
(IDBTransactionBackendInterface): Expose commit() method.
* bindings/js/JSMainThreadExecState.cpp:
(WebCore::JSMainThreadExecState::didLeaveScriptContext): Change target function name.
* bindings/v8/V8RecursionScope.cpp:
(WebCore::V8RecursionScope::didLeaveScriptContext): Change target function name.

Source/WebKit/chromium:

To match the IDB spec, transactions that have had no requests
filed against them should commit, not abort. This requires plumbing
through the commit() call from front-end to back-end.

* src/IDBTransactionBackendProxy.cpp:
(WebKit::IDBTransactionBackendProxy::commit):
(WebKit):
* src/IDBTransactionBackendProxy.h:
(IDBTransactionBackendProxy):
* src/WebIDBTransactionImpl.cpp:
(WebKit::WebIDBTransactionImpl::commit):
(WebKit):
* src/WebIDBTransactionImpl.h:

LayoutTests:

* storage/indexeddb/resources/transaction-active-flag.js: Added.
* storage/indexeddb/resources/transaction-basics.js:
(completeCallback): Empty transactions now commit rather than abort.
(emptyCompleteCallback):
* storage/indexeddb/resources/transaction-complete-workers.js: Renamed from LayoutTests/storage/indexeddb/resources/transaction-abort-workers.js.
* storage/indexeddb/structured-clone.html: Assumed empty transactions aborted.
* storage/indexeddb/transaction-active-flag-expected.txt: Added.
* storage/indexeddb/transaction-active-flag.html: Added.
* storage/indexeddb/transaction-basics-expected.txt:
* storage/indexeddb/transaction-complete-with-js-recursion-cross-frame-expected.txt: Renamed from LayoutTests/storage/indexeddb/transaction-abort-with-js-recursion-cross-frame-expected.txt.
* storage/indexeddb/transaction-complete-with-js-recursion-cross-frame.html: Renamed from LayoutTests/storage/indexeddb/transaction-abort-with-js-recursion-cross-frame.html.
* storage/indexeddb/transaction-complete-with-js-recursion-expected.txt: Renamed from LayoutTests/storage/indexeddb/transaction-abort-with-js-recursion-expected.txt.
* storage/indexeddb/transaction-complete-with-js-recursion.html: Renamed from LayoutTests/storage/indexeddb/transaction-abort-with-js-recursion.html.
* storage/indexeddb/transaction-complete-workers-expected.txt: Renamed from LayoutTests/storage/indexeddb/transaction-abort-workers-expected.txt.
* storage/indexeddb/transaction-complete-workers.html: Renamed from LayoutTests/storage/indexeddb/transaction-abort-workers.html.
* storage/indexeddb/tutorial.html: Assumed empty transactions aborted.

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

12 years agoPrevent crash in animate resource handling
pdr@google.com [Fri, 29 Jun 2012 00:13:07 +0000 (00:13 +0000)]
Prevent crash in animate resource handling
https://bugs.webkit.org/show_bug.cgi?id=90042

Reviewed by Abhishek Arya.

Source/WebCore:

This patch adds a check that we are in a document before registering animation
resources and creating a target element in SVGSMILElement. This prevents a crash where
we would register resources and create the target when we were not in a document
but fail to deregister / reset the target when we were removed from a document.
In failing to reset the target, we can crash when trying to deregister resources that
were not created after being inserted into a document and then removed.

The existence of m_targetResources and registered animation resources is now
tied to being in a document.

Test: svg/custom/animate-reference-crash.html

* svg/animation/SVGSMILElement.cpp:
(WebCore::SVGSMILElement::targetElement):

LayoutTests:

* svg/custom/animate-reference-crash-expected.txt: Added.
* svg/custom/animate-reference-crash.html: Added.

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

12 years agoUpdate buildbot config for new hardware.
wsiegrist@apple.com [Fri, 29 Jun 2012 00:06:01 +0000 (00:06 +0000)]
Update buildbot config for new hardware.

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

12 years ago[chromium] Reset the device scale factor to 1 before each test is run
abarth@webkit.org [Fri, 29 Jun 2012 00:01:46 +0000 (00:01 +0000)]
[chromium] Reset the device scale factor to 1 before each test is run
https://bugs.webkit.org/show_bug.cgi?id=90212

Patch by Terry Anderson <tdanderson@chromium.org> on 2012-06-28
Reviewed by Adam Barth.

Some tests change the device scale factor, so this needs to be reset to
1.0 at the start of each test to avoid test flakiness.

* DumpRenderTree/chromium/LayoutTestController.cpp:
(LayoutTestController::reset):

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

12 years agoIndexedDB: IDBDatabase should have a close pending field.
jsbell@chromium.org [Thu, 28 Jun 2012 23:48:31 +0000 (23:48 +0000)]
IndexedDB: IDBDatabase should have a close pending field.
https://bugs.webkit.org/show_bug.cgi?id=71129

Reviewed by Tony Chang.

Source/WebCore:

Handle the IDB spec case that "versionchange" events should not be fired
against connections that have the internal "closePending" flag set but
are not yet closed due to running transactions.

Test: storage/indexeddb/database-closepending-flag.html

* Modules/indexeddb/IDBDatabase.cpp:
(WebCore::IDBDatabase::onVersionChange):

LayoutTests:

* storage/indexeddb/database-closepending-flag-expected.txt: Added.
* storage/indexeddb/database-closepending-flag.html: Added.
* storage/indexeddb/resources/database-closepending-flag.js: Added.
(test):
(openConnection.request.onsuccess.request.onsuccess):
(openConnection.request.onsuccess):
(openConnection):
(testIDBDatabaseName):
(testIDBDatabaseObjectStoreNames.request.onsuccess.request.onsuccess.transaction.oncomplete):
(testIDBDatabaseObjectStoreNames.request.onsuccess.request.onsuccess):
(testIDBDatabaseObjectStoreNames.request.onsuccess):
(testIDBDatabaseObjectStoreNames):
(testIDBDatabaseTransaction):
(testVersionChangeTransactionSteps.request.onsuccess.request.onsuccess.request.onblocked):
(testVersionChangeTransactionSteps.request.onsuccess.request.onsuccess.request.onsuccess.transaction.oncomplete):
(testVersionChangeTransactionSteps.request.onsuccess.request.onsuccess.request.onsuccess):
(testVersionChangeTransactionSteps.request.onsuccess.request.onsuccess):
(testDatabaseDeletion.request.onsuccess.request.onblocked):
(testDatabaseDeletion.request.onsuccess.request.onsuccess):

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

12 years agoReplace a BUG_OJAN with a proper tracking bug and unskip two
ojan@chromium.org [Thu, 28 Jun 2012 23:38:59 +0000 (23:38 +0000)]
Replace a BUG_OJAN with a proper tracking bug and unskip two
tests in preparation for rebaselining them.
* platform/chromium/TestExpectations:

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

12 years ago[chromium] Split WebScrollbar into WebPluginScrollbar and WebScrollbar
enne@google.com [Thu, 28 Jun 2012 23:27:45 +0000 (23:27 +0000)]
[chromium] Split WebScrollbar into WebPluginScrollbar and WebScrollbar
https://bugs.webkit.org/show_bug.cgi?id=90117

Reviewed by James Robinson.

Source/Platform:

Move WebScrollbar from client API to Platform.

* Platform.gypi:
* chromium/public/WebScrollbar.h: Copied from Source/WebKit/chromium/public/WebPluginScrollbarClient.h.
(WebKit):
(WebScrollbar):
(WebKit::WebScrollbar::~WebScrollbar):

Source/WebCore:

Make WebCore also depend on Platform.

* WebCore.gyp/WebCore.gyp:

Source/WebKit/chromium:

Convert WebScrollbar/WebScrollbarClient/WebScrollbarImpl to be
WebPluginScrollbar, WebPluginScrollbarClient, and
WebPluginScrollbarImpl. Modify ScrollbarGroup
to use this instead.

WebScrollbar is now the base interface for a pre-existing scrollbar
that is accessed in a const manner. It also provides all of the common
WebKit ScrollTypes.h enums. WebPluginScrollbar is now a scrollbar that
has been externally created and is externally modified in terms of its
position, invalidation, and painting.

This is a pre-refactoring for adding Web versions of ScrollbarTheme
into the Platform directory which will operate on WebScrollbar, but
that don't need all of what WebPluginScrollbar provides.

As WebScrollbar is moved to Platform, WebKit.gyp now must depend on
Platform as well.

* WebKit.gyp:
* public/WebPluginScrollbar.h:
(WebKit):
(WebPluginScrollbar):
(WebKit::WebPluginScrollbar::~WebPluginScrollbar):
* public/WebPluginScrollbarClient.h:
(WebKit):
(WebPluginScrollbarClient):
* public/WebScrollbar.h: Removed.
* public/WebScrollbarClient.h: Removed.
* src/AssertMatchingEnums.cpp:
* src/ScrollbarGroup.cpp:
(WebKit::ScrollbarGroup::scrollbarCreated):
(WebKit::ScrollbarGroup::scrollbarDestroyed):
(WebKit::ScrollbarGroup::scrollSize):
(WebKit::ScrollbarGroup::scrollPosition):
(WebKit::ScrollbarGroup::contentsSize):
* src/ScrollbarGroup.h:
(WebKit):
(ScrollbarGroup):
* src/WebPluginScrollbarImpl.cpp: Renamed from Source/WebKit/chromium/src/WebScrollbarImpl.cpp.
(WebKit):
(WebKit::WebPluginScrollbar::createForPlugin):
(WebKit::WebPluginScrollbar::defaultThickness):
(WebKit::WebPluginScrollbarImpl::WebPluginScrollbarImpl):
(WebKit::WebPluginScrollbarImpl::~WebPluginScrollbarImpl):
(WebKit::WebPluginScrollbarImpl::setScrollOffset):
(WebKit::WebPluginScrollbarImpl::invalidateScrollbarRect):
(WebKit::WebPluginScrollbarImpl::getTickmarks):
(WebKit::WebPluginScrollbarImpl::convertFromContainingViewToScrollbar):
(WebKit::WebPluginScrollbarImpl::scrollbarStyleChanged):
(WebKit::WebPluginScrollbarImpl::isOverlay):
(WebKit::WebPluginScrollbarImpl::value):
(WebKit::WebPluginScrollbarImpl::setLocation):
(WebKit::WebPluginScrollbarImpl::setValue):
(WebKit::WebPluginScrollbarImpl::setDocumentSize):
(WebKit::WebPluginScrollbarImpl::scroll):
(WebKit::WebPluginScrollbarImpl::paint):
(WebKit::WebPluginScrollbarImpl::handleInputEvent):
(WebKit::WebPluginScrollbarImpl::onMouseDown):
(WebKit::WebPluginScrollbarImpl::onMouseUp):
(WebKit::WebPluginScrollbarImpl::onMouseMove):
(WebKit::WebPluginScrollbarImpl::onMouseLeave):
(WebKit::WebPluginScrollbarImpl::onMouseWheel):
(WebKit::WebPluginScrollbarImpl::onKeyDown):
* src/WebPluginScrollbarImpl.h: Added.
(WebCore):
(WebKit):
(WebPluginScrollbarImpl):
(WebKit::WebPluginScrollbarImpl::scrollOffset):
(WebKit::WebPluginScrollbarImpl::scrollbar):
* src/WebScrollbarImpl.h: Removed.

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

12 years ago[chromium] Mark a test as failing on Linux debug
hclam@chromium.org [Thu, 28 Jun 2012 23:25:35 +0000 (23:25 +0000)]
[chromium] Mark a test as failing on Linux debug

fast/forms/select/select-state-restore.html is failing on Linux debug because of timeout.

Not reviewed.

* platform/chromium/TestExpectations:

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

12 years agoRebaselines after http://trac.webkit.org/changeset/119507.
ojan@chromium.org [Thu, 28 Jun 2012 23:21:56 +0000 (23:21 +0000)]
Rebaselines after trac.webkit.org/changeset/119507.
These were all done using "webkit-patch rebaseline-expectations".

* platform/chromium-mac-leopard/tables/mozilla/bugs/bug131020-expected.png:
* platform/chromium-mac-snowleopard/tables/mozilla/bugs/bug131020-expected.png:
* platform/chromium-mac/tables/mozilla/bugs/bug131020-expected.png:
* platform/chromium-mac/tables/mozilla/bugs/bug131020-expected.txt:
* platform/chromium-win/tables/mozilla/bugs/bug131020-expected.png:
* platform/chromium/TestExpectations:
* platform/efl/TestExpectations:
* platform/efl/tables/mozilla/bugs/bug131020-expected.txt: Copied from LayoutTests/tables/mozilla/bugs/bug131020-expected.txt.
* platform/gtk/TestExpectations:
* platform/gtk/tables/mozilla/bugs/bug131020-expected.txt: Renamed from LayoutTests/tables/mozilla/bugs/bug131020-expected.txt.
* platform/mac/TestExpectations:
* platform/mac/tables/mozilla/bugs/bug131020-expected.txt:
* platform/qt/TestExpectations:
* platform/qt/tables/mozilla/bugs/bug131020-expected.txt:
* platform/win/TestExpectations:

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

12 years ago[Chromium] On Android, we should be able to ask the embedder what intents exist in...
abarth@webkit.org [Thu, 28 Jun 2012 23:20:52 +0000 (23:20 +0000)]
[Chromium] On Android, we should be able to ask the embedder what intents exist in a region of the page
https://bugs.webkit.org/show_bug.cgi?id=90210

Reviewed by Dimitri Glazkov.

This patch introduces a function that asks the embedder to analyze the
region around a hit test result for interesting content, like phone
numbers, email addresses, or physical addresses. The embedder then
responds with the "most interesting" content, together with an intent
URL for enacting the intent embodied by that content.

This function will be used in a subsequent patch to detect content
after touch events.

* WebKit.gyp:
* public/WebContentDetectionResult.h: Added.
(WebKit):
(WebContentDetectionResult):
(WebKit::WebContentDetectionResult::WebContentDetectionResult):
(WebKit::WebContentDetectionResult::isValid):
(WebKit::WebContentDetectionResult::range):
(WebKit::WebContentDetectionResult::string):
(WebKit::WebContentDetectionResult::intent):
* public/WebViewClient.h:
(WebViewClient):
(WebKit::WebViewClient::detechContentAround):

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

12 years ago<https://bugs.webkit.org/show_bug.cgi?id=90216>
sullivan@apple.com [Thu, 28 Jun 2012 23:12:48 +0000 (23:12 +0000)]
<https://bugs.webkit.org/show_bug.cgi?id=90216>
<rdar://problem/11766518>
Undo handling in WebKit2 is not robust against some page-closing code paths

Reviewed by Enrica Casucci.

* UIProcess/API/mac/PageClientImpl.h:
Declared public function viewWillMoveToAnotherWindow().

* UIProcess/API/mac/PageClientImpl.mm:
(WebKit::PageClientImpl::viewWillMoveToAnotherWindow):
New function, calls clearAllEditCommands() to remove any Undo actions from the stack.
This guarantees that no Undo actions will be abandoned when the PageClientImpl is dealloc'ed.

* UIProcess/API/mac/WKView.mm:
(-[WKView viewWillMoveToWindow:]):
Now informs PageClientImpl via new function PageClientImpl::viewWillMoveToAnotherWindow().

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

12 years agoCompositeShadowTreeWalker should use InsertionPoint::hasDistribution() instead of...
hayato@chromium.org [Thu, 28 Jun 2012 23:05:59 +0000 (23:05 +0000)]
CompositeShadowTreeWalker should use InsertionPoint::hasDistribution() instead of InsertionPoint::isActive().
https://bugs.webkit.org/show_bug.cgi?id=89177

Reviewed by Dimitri Glazkov.

Source/WebCore:

Prevents ComposedShadowTreeWalker from escaping out of an
insertion point (which has distributed nodes) from a non-used
fallback element in the insertion point.  Such a fallback element
should be treated as in an orphaned subtree.

ComposedShadowTreeParentWalker will be also fixed in a follow-up patch.

Test: fast/dom/shadow/composed-shadow-tree-walker.html

* dom/ComposedShadowTreeWalker.cpp:
(WebCore::ComposedShadowTreeWalker::traverseNodeEscapingFallbackContents):

LayoutTests:

* fast/dom/shadow/composed-shadow-tree-walker-expected.txt:
* fast/dom/shadow/composed-shadow-tree-walker.html:

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

12 years agoAdding a commenting utility to record BytecodeGenerator comments
commit-queue@webkit.org [Thu, 28 Jun 2012 23:03:07 +0000 (23:03 +0000)]
Adding a commenting utility to record BytecodeGenerator comments
with opcodes that are emitted.  Presently, the comments can only
be constant strings.  Adding comments for opcodes is optional.
If a comment is added, the comment will be printed following the
opcode when CodeBlock::dump() is called.

This utility is disabled by default, and is only meant for VM
development purposes.  It should not be enabled for product builds.

To enable this utility, set ENABLE_BYTECODE_COMMENTS in CodeBlock.h
to 1.

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

Patch by Mark Lam <mark.lam@apple.com> on 2012-06-28
Reviewed by Geoffrey Garen.

* GNUmakefile.list.am:
* JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
* JavaScriptCore.xcodeproj/project.pbxproj:
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::dumpBytecodeCommentAndNewLine): Dumps the comment.
(JSC):
(JSC::CodeBlock::printUnaryOp): Add comment dumps.
(JSC::CodeBlock::printBinaryOp): Add comment dumps.
(JSC::CodeBlock::printConditionalJump): Add comment dumps.
(JSC::CodeBlock::printCallOp): Add comment dumps.
(JSC::CodeBlock::printPutByIdOp): Add comment dumps.
(JSC::CodeBlock::dump): Add comment dumps.
(JSC::CodeBlock::CodeBlock):
(JSC::CodeBlock::commentForBytecodeOffset):
    Finds the comment for an opcode if available.
(JSC::CodeBlock::dumpBytecodeComments):
    For debugging whether comments are collected.
    It is not being called anywhere.
* bytecode/CodeBlock.h:
(CodeBlock):
(JSC::CodeBlock::bytecodeComments):
* bytecode/Comment.h: Added.
(JSC):
(Comment):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::BytecodeGenerator):
(JSC::BytecodeGenerator::emitOpcode): Calls emitComment().
(JSC):
(JSC::BytecodeGenerator::emitComment): Adds comment to CodeBlock.
(JSC::BytecodeGenerator::prependComment):
    Registers a comment for emitComemnt() to use later.
* bytecompiler/BytecodeGenerator.h:
(BytecodeGenerator):
(JSC::BytecodeGenerator::emitComment):
(JSC::BytecodeGenerator::prependComment):
    These are inlined versions of these functions that nullify them
    when ENABLE_BYTECODE_COMMENTS is 0.
(JSC::BytecodeGenerator::comments):

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

12 years agoFix a typo in the change log per review comment.
rniwa@webkit.org [Thu, 28 Jun 2012 23:02:23 +0000 (23:02 +0000)]
Fix a typo in the change log per review comment.

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

12 years agoCleanup HTMLFormCollection
rniwa@webkit.org [Thu, 28 Jun 2012 23:01:06 +0000 (23:01 +0000)]
Cleanup HTMLFormCollection
https://bugs.webkit.org/show_bug.cgi?id=90111

Reviewed by Andreas Kling.

Source/WebCore:

Got rid of getNamedItem and enamed getNamedFormItem to firstNamedItem and got rid of duplicateNumber argument since
it's always 0. Also made it a static local function. In addition, removed nextItem() since it's not used anywhere.

WebKit API Test: WebKit1.HTMLFormCollectionNamedItemTest

* html/HTMLFormCollection.cpp:
(WebCore::firstNamedItem):
(WebCore):
(WebCore::HTMLFormCollection::namedItem):
* html/HTMLFormCollection.h:
(HTMLFormCollection):

Tools:

Add a WebKit API test using copy-paste design pattern per kling's request.

* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/mac/HTMLFormCollectionNamedItem.html: Added.
* TestWebKitAPI/Tests/mac/HTMLFormCollectionNamedItem.mm: Added.
(-[HTMLFormCollectionNamedItemTest webView:didFinishLoadForFrame:]):
(TestWebKitAPI):
(TestWebKitAPI::TEST):

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

12 years agoIndexedDB: Hook up render-side key ASSERTing for get()
commit-queue@webkit.org [Thu, 28 Jun 2012 22:57:08 +0000 (22:57 +0000)]
IndexedDB: Hook up render-side key ASSERTing for get()
https://bugs.webkit.org/show_bug.cgi?id=90001

Patch by Alec Flett <alecflett@chromium.org> on 2012-06-28
Reviewed by Tony Chang.

Source/WebCore:

Hook up the new onSuccess and add it to the interface. For now,
simply assert that the right value is set. Add the same assertion
logic in the value-construction logic when the cursor advances.

No new tests, existing tests verify this refactor is correct.

* Modules/indexeddb/IDBCallbacks.h:
(IDBCallbacks):
* Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
(WebCore::IDBObjectStoreBackendImpl::getInternal):
* Modules/indexeddb/IDBRequest.cpp:
(WebCore):
(WebCore::IDBRequest::onSuccess):
* Modules/indexeddb/IDBRequest.h:
* bindings/v8/IDBBindingUtilities.cpp:
(WebCore::createIDBKeyFromSerializedValueAndKeyPath):
* inspector/InspectorIndexedDBAgent.cpp:
(WebCore):

Source/WebKit/chromium:

Hook up Chromium WebKit API to new onSuccess handler.

* src/WebIDBCallbacksImpl.cpp:
(WebKit::WebIDBCallbacksImpl::onSuccess):
* tests/IDBAbortOnCorruptTest.cpp:
(WebCore::MockIDBCallbacks::onSuccess):
* tests/IDBDatabaseBackendTest.cpp:

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

12 years ago[mac] WKTR windows still don't stay off screen sometimes
timothy_horton@apple.com [Thu, 28 Jun 2012 22:45:18 +0000 (22:45 +0000)]
[mac] WKTR windows still don't stay off screen sometimes
https://bugs.webkit.org/show_bug.cgi?id=90214
<rdar://problem/11760263>

Reviewed by Simon Fraser.

In some cases, the system itself will consult [WebKitTestRunnerWindow frame], so we should refrain from
overriding it and instead provide a different method to use when we want the web-facing "fake" window origin
(for PlatformWebView::windowFrame()).

* WebKitTestRunner/mac/PlatformWebViewMac.mm:
(-[WebKitTestRunnerWindow frameRespectingFakeOrigin]):
(WTR::PlatformWebView::windowFrame):

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

12 years ago[GTK] Add unit tests for GtkInputMethodFilter
mrobinson@webkit.org [Thu, 28 Jun 2012 22:34:25 +0000 (22:34 +0000)]
[GTK] Add unit tests for GtkInputMethodFilter
https://bugs.webkit.org/show_bug.cgi?id=88698

Reviewed by Carlos Garcia Campos.

Add unit tests for GtkInputMethodFilter in the WebCore platform layer.
This change adds the TestGtk test suite which will be used for all non-API
layer GTK unit tests.

* TestWebKitAPI/GNUmakefile.am: Update the build to include the new tests.
* TestWebKitAPI/Tests/gtk/InputMethodFilter.cpp: Added.
(TestWebKitAPI::PlatformWebView::PlatformWebView): Remove the call to gtk_init here
as it's now in main.cpp.
* TestWebKitAPI/gtk/main.cpp: Change the g_type_init call to gtk_init, because now
a majority of all unit tests depend on GTK+ being initialized.

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

12 years agoAdd support for DEPTH_STENCIL to WEBGL_depth_texture
commit-queue@webkit.org [Thu, 28 Jun 2012 21:55:12 +0000 (21:55 +0000)]
Add support for DEPTH_STENCIL to WEBGL_depth_texture
https://bugs.webkit.org/show_bug.cgi?id=90109

Patch by Gregg Tavares <gman@google.com> on 2012-06-28
Reviewed by Kenneth Russell.

Source/WebCore:

* html/canvas/WebGLDepthTexture.idl:
* html/canvas/WebGLFramebuffer.cpp:
* html/canvas/WebGLRenderingContext.cpp:
(WebCore):
(WebCore::WebGLRenderingContext::validateTexFuncFormatAndType):

LayoutTests:

* fast/canvas/webgl/webgl-depth-texture-expected.txt:
* fast/canvas/webgl/webgl-depth-texture.html:

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

12 years ago[chromium] Move chromium compositor implementation files into separate section in...
commit-queue@webkit.org [Thu, 28 Jun 2012 21:51:36 +0000 (21:51 +0000)]
[chromium] Move chromium compositor implementation files into separate section in WebCore.gypi
https://bugs.webkit.org/show_bug.cgi?id=90201

Patch by James Robinson <jamesr@chromium.org> on 2012-06-28
Reviewed by Adam Barth.

This moves the chromium compositor implementation files to a separate gyp variable to make future changes
easier. The files still all link into webcore_platform.lib, as before.

* WebCore.gyp/WebCore.gyp:
* WebCore.gypi:

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

12 years agoUnreviewed. Rolled DEPS.
commit-queue@webkit.org [Thu, 28 Jun 2012 21:43:49 +0000 (21:43 +0000)]
Unreviewed.  Rolled DEPS.

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

* DEPS:

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

12 years ago[chromium] rebaseline svg text layouts?
schenney@chromium.org [Thu, 28 Jun 2012 21:30:44 +0000 (21:30 +0000)]
[chromium] rebaseline svg text layouts?
https://bugs.webkit.org/show_bug.cgi?id=89936

Unreviewed Chromium test expectations update.

The SVG tests for this bug all seem OK, so they are being rebaselined.
The other content is less clear, so it is being left for an expert.

* platform/chromium-win-xp/svg/W3C-SVG-1.1-SE/text-intro-05-t-expected.txt: Added.
* platform/chromium-win-xp/svg/W3C-SVG-1.1/animate-elem-52-t-expected.png: Added.
* platform/chromium-win-xp/svg/W3C-SVG-1.1/filters-conv-01-f-expected.png: Added.
* platform/chromium-win-xp/svg/W3C-SVG-1.1/masking-intro-01-f-expected.png: Added.
* platform/chromium-win-xp/svg/W3C-SVG-1.1/text-intro-05-t-expected.txt: Added.
* platform/chromium-win-xp/svg/custom/js-late-gradient-and-object-creation-expected.png: Added.
* platform/chromium-win-xp/svg/text/text-intro-05-t-expected.txt: Added.
* platform/chromium-win-xp/svg/zoom/page/zoom-foreignObject-expected.png: Added.
* platform/chromium/TestExpectations:

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

12 years ago[chromium] Mark a test as slow.
hclam@chromium.org [Thu, 28 Jun 2012 21:26:31 +0000 (21:26 +0000)]
[chromium] Mark a test as slow.
https://bugs.webkit.org/show_bug.cgi?id=90207

fast/forms/select/select-state-restore.html is a slow test on debug builds.
Not reviewed.

* platform/chromium/TestExpectations:

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

12 years agoUnreviewed, rolling out r121463.
hclam@chromium.org [Thu, 28 Jun 2012 21:10:12 +0000 (21:10 +0000)]
Unreviewed, rolling out r121463.
http://trac.webkit.org/changeset/121463
https://bugs.webkit.org/show_bug.cgi?id=90094

Broke Windows build.

* WebKit.gypi:
* WebKitUnitTests.gyp:
* public/WebDOMMessageEvent.h:
* tests/AssociatedURLLoaderTest.cpp:
(WebKit::AssociatedURLLoaderTest::AssociatedURLLoaderTest):
(WebKit::AssociatedURLLoaderTest::SetUp):
(WebKit::AssociatedURLLoaderTest::CheckMethodFails):
(WebKit::AssociatedURLLoaderTest::CheckHeaderFails):
(WebKit::AssociatedURLLoaderTest::CheckAccessControlHeaders):
(WebKit::TEST_F):
* tests/EventListenerTest.cpp:
* tests/FrameTestHelpers.cpp:
(WebKit::FrameTestHelpers::registerMockedURLLoad):
(FrameTestHelpers):
(WebKit::FrameTestHelpers::loadFrame):
* tests/FrameTestHelpers.h:
(FrameTestHelpers):
* tests/ListenerLeakTest.cpp:
(WebKit::ListenerLeakTest::RunTest):
* tests/PopupMenuTest.cpp:
(WebKit::SelectPopupMenuTest::registerMockedURLLoad):
(WebKit::SelectPopupMenuTest::loadFrame):
(WebKit::TEST_F):
* tests/RunAllTests.cpp:
* tests/URLTestHelpers.cpp: Removed.
* tests/URLTestHelpers.h: Removed.
* tests/WebFrameTest.cpp:
(WebKit::WebFrameTest::registerMockedHttpURLLoad):
(WebKit::WebFrameTest::registerMockedChromeURLLoad):
(WebKit::TEST_F):
* tests/WebPageNewSerializerTest.cpp:
(WebKit::WebPageNewSerializeTest::registerMockedURLLoad):
(WebPageNewSerializeTest):
(WebKit::WebPageNewSerializeTest::setUpCSSTestPage):
(WebKit::WebPageNewSerializeTest::loadURLInTopFrame):
(WebKit::WebPageNewSerializeTest::resourceVectorContains):
(WebKit::TEST_F):
* tests/WebPageSerializerTest.cpp:
(WebKit::WebPageSerializerTest::registerMockedURLLoad):
(WebKit::WebPageSerializerTest::loadURLInTopFrame):
(WebKit::WebPageSerializerTest::webVectorContains):
(WebKit::TEST_F):
* tests/WebViewTest.cpp:
(WebKit::TEST_F):
(WebKit::WebViewTest::testAutoResize):
(WebKit::WebViewTest::testTextInputType):

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

12 years ago[EFL] Enable support for HTML5 datalist
commit-queue@webkit.org [Thu, 28 Jun 2012 21:02:30 +0000 (21:02 +0000)]
[EFL] Enable support for HTML5 datalist
https://bugs.webkit.org/show_bug.cgi?id=90157

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-06-28
Reviewed by Martin Robinson.

.:

Turn on DATALIST flag by default on EFL port to
support HTML5 datalist tag.

* Source/cmake/OptionsEfl.cmake:

Tools:

Turn on DATALIST flag by default on EFL port to
support HTML5 datalist tag.

* Scripts/webkitperl/FeatureList.pm:

LayoutTests:

* platform/efl/Skipped: Unskip fast/forms/datalist tests now that
the DATALIST flag is turned on by default on EFL port.
* platform/efl/fast/forms/datalist/input-list-expected.txt: Added.
We need platform-specific result because we don't support datalist
UI for any element yet. This should be progressively added later
on and the expected result will evolve.

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

12 years ago[EFL] Use Eina_Module API instead of dlopen in PluginPackageEfl
commit-queue@webkit.org [Thu, 28 Jun 2012 20:56:29 +0000 (20:56 +0000)]
[EFL] Use Eina_Module API instead of dlopen in PluginPackageEfl
https://bugs.webkit.org/show_bug.cgi?id=89972

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-06-28
Reviewed by Antonio Gomes.

Use convenience helpers in Eina_Module to load plugins instead
of POSIX dlopen().

No new tests, behavior has not changed.

* platform/FileSystem.h:
(WebCore):
* platform/efl/FileSystemEfl.cpp:
(WebCore::unloadModule):
* plugins/efl/PluginPackageEfl.cpp:
(WebCore::PluginPackage::load):

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

12 years ago32bit DFG incorrectly claims an fpr is fillable even if it has not been proven double
oliver@apple.com [Thu, 28 Jun 2012 20:54:06 +0000 (20:54 +0000)]
32bit DFG incorrectly claims an fpr is fillable even if it has not been proven double
https://bugs.webkit.org/show_bug.cgi?id=90127

Reviewed by Filip Pizlo.

The 32-bit version of fillSpeculateDouble doesn't handle Number->fpr loads
correctly.  This patch fixes this by killing the fill info in the GenerationInfo
when the spillFormat doesn't guarantee the value is a double.

* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::fillSpeculateDouble):

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

12 years ago[WinCairo] Unreviewed build correction. Add two missing macro
bfulgham@webkit.org [Thu, 28 Jun 2012 20:47:17 +0000 (20:47 +0000)]
[WinCairo] Unreviewed build correction.  Add two missing macro
declarations to vsprops file.

* win/tools/vsprops/FeatureDefinesCairo.vsprops: Add missing
ENABLE_HIGH_DPI_CANVAS and ENABLE_REQUEST_ANIMATION_FRAME macros.

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

12 years agoEnable CSS grid layout LayoutTests on platform Mac
tony@chromium.org [Thu, 28 Jun 2012 20:37:36 +0000 (20:37 +0000)]
Enable CSS grid layout LayoutTests on platform Mac
https://bugs.webkit.org/show_bug.cgi?id=90113

Reviewed by Ojan Vafai.

Tools:

* DumpRenderTree/mac/DumpRenderTree.mm:
(resetDefaultsToConsistentValues): Reset the value to NO between tests.

LayoutTests:

Use 1 instead of true, since that's what WebView.mm expects.

* fast/css-grid-layout/containing-block-grids.html:
* fast/css-grid-layout/display-grid-set-get.html:
* fast/css-grid-layout/floating-empty-grids.html:
* fast/css-grid-layout/grid-columns-rows-get-set-multiple.html:
* fast/css-grid-layout/grid-columns-rows-get-set.html:
* fast/css-grid-layout/grid-item-column-row-get-set.html:
* platform/mac/Skipped: Unskip tests.

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

12 years ago[chromium] Use WEBKIT_IMPLEMENTATION == 1 for webkit_unit_tests
shawnsingh@chromium.org [Thu, 28 Jun 2012 20:34:47 +0000 (20:34 +0000)]
[chromium] Use WEBKIT_IMPLEMENTATION == 1 for webkit_unit_tests
https://bugs.webkit.org/show_bug.cgi?id=90094

Reviewed by Adam Barth.

This patch adds the WEBKIT_IMPLEMENTATION = 1 define to
WebKitUnitTests.gyp. To get it to compile correctly, some string
and URL code was refactored and fixed.

* WebKit.gypi:
* WebKitUnitTests.gyp:
* public/WebDOMMessageEvent.h:
(WebKit::WebDOMMessageEvent::WebDOMMessageEvent):
* tests/AssociatedURLLoaderTest.cpp:
* tests/EventListenerTest.cpp:
* tests/FrameTestHelpers.cpp:
(WebKit::FrameTestHelpers::loadFrame):
* tests/FrameTestHelpers.h:
* tests/ListenerLeakTest.cpp:
(WebKit::ListenerLeakTest::RunTest):
* tests/PopupMenuTest.cpp:
* tests/RunAllTests.cpp:
* tests/URLTestHelpers.cpp: Added.
(URLTestHelpers):
(WebKit::URLTestHelpers::registerMockedURLFromBaseURL):
(WebKit::URLTestHelpers::registerMockedURLLoad):
* tests/URLTestHelpers.h: Copied from Source/WebKit/chromium/public/WebDOMMessageEvent.h.
(WebKit):
(URLTestHelpers):
(WebKit::URLTestHelpers::toKURL):
* tests/WebFrameTest.cpp:
* tests/WebPageNewSerializerTest.cpp:
* tests/WebPageSerializerTest.cpp:
* tests/WebViewTest.cpp:

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

12 years ago[Qt] Fix TextureMapper rendering of GraphicsSurface on Mac
commit-queue@webkit.org [Thu, 28 Jun 2012 20:33:59 +0000 (20:33 +0000)]
[Qt] Fix TextureMapper rendering of GraphicsSurface on Mac
https://bugs.webkit.org/show_bug.cgi?id=90154

Patch by Jocelyn Turcotte <turcotte.j@gmail.com> on 2012-06-28
Reviewed by Noam Rosenthal.

Fix a regression introduced in r120608.
texture2DRect takes texel coordinates, unlike texture2D which needs normalized coordinates.

Pass an additional textureSize uniform and multiply it by the normalized coordinates.

* platform/graphics/texmap/TextureMapperGL.cpp:
(WebCore::TextureMapperGL::drawTextureRectangleARB):
* platform/graphics/texmap/TextureMapperShaderManager.cpp:
(WebCore::TextureMapperShaderProgram::TextureMapperShaderProgram):
(WebCore::TextureMapperShaderProgramRectSimple::TextureMapperShaderProgramRectSimple):
* platform/graphics/texmap/TextureMapperShaderManager.h:
(WebCore::TextureMapperShaderProgram::textureSizeLocation):
(TextureMapperShaderProgram):

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

12 years agoImprove compositing logging output
simon.fraser@apple.com [Thu, 28 Jun 2012 20:28:42 +0000 (20:28 +0000)]
Improve compositing logging output
https://bugs.webkit.org/show_bug.cgi?id=90199

Reviewed by Tim Horton (w00t!).

Improve the compositing logging channel output in a few
useful ways:
1. Report memory use, rather than megapixels
2. Show element class names

* platform/graphics/GraphicsLayer.cpp:
(WebCore::GraphicsLayer::backingStoreMemoryEstimate):
* platform/graphics/GraphicsLayer.h:
(GraphicsLayer):
* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::GraphicsLayerCA::backingStoreMemoryEstimate):
* platform/graphics/ca/GraphicsLayerCA.h:
(GraphicsLayerCA):
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::nameForLayer):
(WebCore::RenderLayerBacking::backingStoreMemoryEstimate):
* rendering/RenderLayerBacking.h:
(RenderLayerBacking):
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::RenderLayerCompositor):
(WebCore::RenderLayerCompositor::updateCompositingLayers):
(WebCore::RenderLayerCompositor::logLayerInfo):
(WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
* rendering/RenderLayerCompositor.h:
(RenderLayerCompositor):

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

12 years ago[BlackBerry] Add watchlist options for Blackberry and editing.
mifenton@rim.com [Thu, 28 Jun 2012 20:27:24 +0000 (20:27 +0000)]
[BlackBerry] Add watchlist options for Blackberry and editing.
https://bugs.webkit.org/show_bug.cgi?id=90193

Unreviewed.

Add BlackBerry and Editing watchlist and monitor them.

* Scripts/webkitpy/common/config/watchlist:

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

12 years agoUnreviewed gardening.
senorblanco@chromium.org [Thu, 28 Jun 2012 20:22:57 +0000 (20:22 +0000)]
Unreviewed gardening.

Remove a duplicate expectation.

* platform/chromium/TestExpectations:

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

12 years ago[chromium] Fix up more includes in compositor code
jamesr@google.com [Thu, 28 Jun 2012 20:19:52 +0000 (20:19 +0000)]
[chromium] Fix up more includes in compositor code
https://bugs.webkit.org/show_bug.cgi?id=90200

Reviewed by Adrienne Walker.

Adds includes we are using and removes ones that we aren't using.

* platform/graphics/chromium/CanvasLayerTextureUpdater.cpp:
* platform/graphics/chromium/ContentLayerChromium.cpp:
* platform/graphics/chromium/ProgramBinding.cpp:
* platform/graphics/chromium/RenderSurfaceChromium.cpp:
* platform/graphics/chromium/cc/CCGraphicsContext.h:
* platform/graphics/chromium/cc/CCRenderSurface.h:
(WebCore):
* platform/graphics/chromium/cc/CCRenderSurfaceFilters.cpp:

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

12 years ago[chromium] svg/custom/clip-path-referencing-use2.svg fails in "drt mode" in DRT
schenney@chromium.org [Thu, 28 Jun 2012 20:13:08 +0000 (20:13 +0000)]
[chromium] svg/custom/clip-path-referencing-use2.svg fails in "drt mode" in DRT
https://bugs.webkit.org/show_bug.cgi?id=85085

Unreviewed Chromium expectations update.

NRWT is not printing the stdout from this test, which is not really
enough to warrant keeping the expectations incorrect. The bug stays
open.

* platform/chromium-mac/svg/custom/clip-path-referencing-use2-expected.txt:
* platform/chromium-win/svg/custom/clip-path-referencing-use2-expected.txt:
* platform/chromium/TestExpectations:

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

12 years ago[CSSRegions]Rename NamedFlow::contentNodes to NamedFlow::getContent()
commit-queue@webkit.org [Thu, 28 Jun 2012 20:02:07 +0000 (20:02 +0000)]
[CSSRegions]Rename NamedFlow::contentNodes to NamedFlow::getContent()
https://bugs.webkit.org/show_bug.cgi?id=90163

Patch by Andrei Onea <onea@adobe.com> on 2012-06-28
Reviewed by Andreas Kling.

Source/WebCore:

Latest CSS Regions spec defines the NamedFlow interface as having a function named getContent,
rather than an attribute named contentNodes.
http://www.w3.org/TR/css3-regions/#the-namedflow-interface

Test: fast/regions/webkit-named-flow-get-content.html

* dom/WebKitNamedFlow.cpp:
(WebCore::WebKitNamedFlow::getContent):
* dom/WebKitNamedFlow.h:
(WebKitNamedFlow):
* dom/WebKitNamedFlow.idl:

LayoutTests:

Changed test for NameFlow::contentNodes to reflect new spec, which uses
NameFlow::getContent().

* fast/regions/webkit-named-flow-content-nodes-expected.txt: Removed.
* fast/regions/webkit-named-flow-get-content-expected.txt: Added.
* fast/regions/webkit-named-flow-get-content.html: Renamed from LayoutTests/fast/regions/webkit-named-flow-content-nodes.html.

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

12 years agoUnreviewed, upgrade myself to a reviewer!
timothy_horton@apple.com [Thu, 28 Jun 2012 19:56:36 +0000 (19:56 +0000)]
Unreviewed, upgrade myself to a reviewer!

http://www.webkit.org/blog/2082/tim-horton-is-now-a-webkit-reviewer/

* Scripts/webkitpy/common/config/committers.py:

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

12 years agoREGRESSION(r121232): named properties on document and window may return wrong object
rniwa@webkit.org [Thu, 28 Jun 2012 19:48:29 +0000 (19:48 +0000)]
REGRESSION(r121232): named properties on document and window may return wrong object
https://bugs.webkit.org/show_bug.cgi?id=90133

Reviewed by Andreas Kling.

Source/WebCore:

Fixed the bug. Also replaced hasAnyItem by isEmpty (hasAnyItem() is equivalent to !isEmpty()).

Test: fast/dom/HTMLDocument/named-item-multiple-match.html

* bindings/js/JSHTMLDocumentCustom.cpp:
(WebCore::JSHTMLDocument::nameGetter):
* bindings/v8/custom/V8DOMWindowCustom.cpp:
(WebCore::V8DOMWindow::namedPropertyGetter):
* bindings/v8/custom/V8HTMLDocumentCustom.cpp:
(WebCore::V8HTMLDocument::GetNamedProperty):
* html/HTMLCollection.h:
(WebCore::HTMLCollection::isEmpty):
(WebCore::HTMLCollection::hasExactlyOneItem):

LayoutTests:

Add a regression test.

* fast/dom/HTMLDocument/named-item-multiple-match-expected.txt: Added.
* fast/dom/HTMLDocument/named-item-multiple-match.html: Added.

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

12 years ago[Chromium] Chromium's LayoutTestController is missing setBackingScaleFactor
commit-queue@webkit.org [Thu, 28 Jun 2012 19:45:09 +0000 (19:45 +0000)]
[Chromium] Chromium's LayoutTestController is missing setBackingScaleFactor
https://bugs.webkit.org/show_bug.cgi?id=83635

Patch by Terry Anderson <tdanderson@chromium.org> on 2012-06-28
Reviewed by Adam Barth.

Added InvokeCallbackTask, a new derived class of MethodTask. When
setBackingScaleFactor is called, a call to setDeviceScaleFactor in
WebView is made and then postTask is used to invoke the callback
function specified in testRunner.setBackingScaleFactor.

* DumpRenderTree/chromium/LayoutTestController.cpp:
(LayoutTestController::LayoutTestController):
(InvokeCallbackTask):
(InvokeCallbackTask::InvokeCallbackTask):
(InvokeCallbackTask::runIfValid):
(LayoutTestController::setBackingScaleFactor):
* DumpRenderTree/chromium/LayoutTestController.h:
(LayoutTestController):

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

12 years ago[Skia] Computing the resampling mode ignores scale applied to the canvas
commit-queue@webkit.org [Thu, 28 Jun 2012 19:37:20 +0000 (19:37 +0000)]
[Skia] Computing the resampling mode ignores scale applied to the canvas
https://bugs.webkit.org/show_bug.cgi?id=72073

Patch by Zeev Lieber <zlieber@chromium.org> on 2012-06-28
Reviewed by Stephen White.

Source/WebCore:

Re-basing earlier patch by Daniel Sievers; updated tests.

Take into account canvas scale when computing image resampling mode.

When drawing a bitmap and computing the best resampling mode based
on the requested scale, take into account CSS scale and page scale
that are applied to the canvas. This allows for single-pass scaling
in potentially better quality (RESAMPLE_AWESOME) and also takes
better advantage of the scaled image cache in that codepath.

Existing tests updated to expect different resampling method (and
therefore a different image) whenever canvas scaling changes.

* platform/graphics/skia/ImageSkia.cpp:
(WebCore::paintSkBitmap):

LayoutTests:

Updated tests to expect different image when resampling method changed.

* platform/chromium-linux/fast/borders/border-image-scale-transform-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-dirLTR-anchorEnd-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-dirLTR-anchorMiddle-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-dirLTR-anchorStart-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-dirNone-anchorEnd-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-dirNone-anchorMiddle-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-dirNone-anchorStart-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-dirRTL-anchorEnd-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-dirRTL-anchorMiddle-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-dirRTL-anchorStart-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-inherited-dirLTR-anchorEnd-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-inherited-dirLTR-anchorMiddle-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-inherited-dirLTR-anchorStart-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-inherited-dirRTL-anchorEnd-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-inherited-dirRTL-anchorMiddle-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-inherited-dirRTL-anchorStart-expected.png:
* platform/chromium-linux/svg/W3C-I18N/text-anchor-no-markup-expected.png:
* platform/chromium-linux/svg/W3C-SVG-1.1/render-groups-01-b-expected.png:
* platform/chromium-linux/svg/W3C-SVG-1.1/render-groups-03-t-expected.png:
* platform/chromium-linux/svg/W3C-SVG-1.1/struct-symbol-01-b-expected.png:
* platform/chromium-linux/svg/carto.net/scrollbar-expected.png:
* platform/chromium-linux/svg/custom/image-small-width-height-expected.png:
* platform/chromium-linux/svg/custom/scrolling-embedded-svg-file-image-repaint-problem-expected.png:
* platform/chromium-linux/transitions/cross-fade-background-image-expected.png:
* platform/chromium/TestExpectations:

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

12 years ago[chromium] Change WebViewImpl::textInputInfo to use root editable element.
commit-queue@webkit.org [Thu, 28 Jun 2012 19:35:39 +0000 (19:35 +0000)]
[chromium] Change WebViewImpl::textInputInfo to use root editable element.
https://bugs.webkit.org/show_bug.cgi?id=90179

Patch by Oli Lan <olilan@chromium.org> on 2012-06-28
Reviewed by Adam Barth.

WebViewImpl::textInputInfo currently returns text value and offsets relative to the
focused node. For contenteditable nodes, this may not give the expected result.

This patch changes the method to return value and offsets for the root editable element.
This also allows the implementation to be simplified somewhat.

This also ensures that the offsets returned will use the same basis as the recently added
method Editor::setSelectionOffsets (and WebViewImpl::setEditableSelectionOffsets).

Testing for textInputInfo has been added to WebViewTest.

* src/WebViewImpl.cpp:
(WebKit::WebViewImpl::textInputInfo):
* tests/WebViewTest.cpp:
(WebKit::TEST_F):

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

12 years ago[chromium] Should schedule a commit when dropping contents textures
commit-queue@webkit.org [Thu, 28 Jun 2012 19:27:47 +0000 (19:27 +0000)]
[chromium] Should schedule a commit when dropping contents textures
https://bugs.webkit.org/show_bug.cgi?id=90031

Patch by James Robinson <jamesr@chromium.org> on 2012-06-28
Reviewed by Adrienne Walker.

Source/WebCore:

If we're dropping contents textures on the impl thread, we need to schedule a commit to pick up new contents at
the next commit opportunity. Also adds some traces to make debugging issues like this easier.

* platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
(WebCore::CCLayerTreeHostImpl::commitComplete):
(WebCore::CCLayerTreeHostImpl::canDraw):
(WebCore::CCLayerTreeHostImpl::releaseContentsTextures):
* platform/graphics/chromium/cc/CCScheduler.cpp:
(WebCore::CCScheduler::processScheduledActions):

Source/WebKit/chromium:

Adds a somewhat vacuous test unit test for committing when releasing textures.

* tests/CCLayerTreeHostImplTest.cpp:

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

12 years ago[WK2] Add C API to inspect a Web Intent service
commit-queue@webkit.org [Thu, 28 Jun 2012 19:20:28 +0000 (19:20 +0000)]
[WK2] Add C API to inspect a Web Intent service
https://bugs.webkit.org/show_bug.cgi?id=89276

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-06-28
Reviewed by Anders Carlsson.

Add C API for Web intent service so that it can be queried
on client side.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* UIProcess/API/C/WKIntentServiceInfo.cpp: Added.
(WKIntentServiceInfoGetTypeID):
(WKIntentServiceInfoCopyAction):
(WKIntentServiceInfoCopyType):
(WKIntentServiceInfoCopyHref):
(WKIntentServiceInfoCopyTitle):
(WKIntentServiceInfoCopyDisposition):
* UIProcess/API/C/WKIntentServiceInfo.h: Added.

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

12 years agoThreadingWin: Silence GCC compiler warnings
commit-queue@webkit.org [Thu, 28 Jun 2012 19:15:31 +0000 (19:15 +0000)]
ThreadingWin: Silence GCC compiler warnings
https://bugs.webkit.org/show_bug.cgi?id=89491

Patch by Kalev Lember <kalevlember@gmail.com> on 2012-06-28
Reviewed by Adam Roben.

* wtf/ThreadingWin.cpp:
(WTF::createThreadInternal):
(WTF::PlatformCondition::timedWait):
(WTF::PlatformCondition::signal): Fix unused-but-set-variable
warnings.

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

12 years agoMake rebaseline-test and rebaseline-expectations work for non-Chromium ports
ojan@chromium.org [Thu, 28 Jun 2012 19:03:06 +0000 (19:03 +0000)]
Make rebaseline-test and rebaseline-expectations work for non-Chromium ports
https://bugs.webkit.org/show_bug.cgi?id=90186

Reviewed by Adam Barth.

This makes rebaselining work for all ports that have a TestExpectations file
in the tree. I didn't test other ports.

This doesn't address 100% of the problem. The rebaseline code puts the expectations
in the most specific directory and relies on optimize-baselines to merge baselines
appropriately. This only works if every platform directory has an equivalent bot
that runs the tests, which is not true for most ports.

* Scripts/webkitpy/common/net/buildbot/buildbot.py:
(Builder._revision_and_build_for_filename):
Some bots have filenames that aren't revision/build number pairs
e.g. they are random junk like aQhxvx. Handle this gracefully.
(Builder._fetch_revision_to_build_map):
(Builder._file_info_list_to_revision_to_build_list):
* Scripts/webkitpy/common/net/buildbot/buildbot_unittest.py:
(BuilderTest.test_build_and_revision_for_filename):
(BuilderTest.test_file_info_list_to_revision_to_build_list):
* Scripts/webkitpy/layout_tests/port/builders.py:
Update the list of builders. This list needs to be kept up
to date for the rebaseline tool to work.
* Scripts/webkitpy/tool/commands/rebaseline.py:
(RebaselineTest._results_url):
(RebaselineExpectations._run_webkit_patch):
(RebaselineExpectations._rebaseline_port):
* Scripts/webkitpy/tool/commands/rebaseline_unittest.py:
Qt port uses qmake to determine the right version. Systems without qmake correctly fallback
to a specific version.

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

12 years agoDon't malloc RenderGeometryMap steps individually
antti@apple.com [Thu, 28 Jun 2012 18:58:21 +0000 (18:58 +0000)]
Don't malloc RenderGeometryMap steps individually
https://bugs.webkit.org/show_bug.cgi?id=90074

Reviewed by Simon Fraser.

Mallocs and frees for steps under RenderGeometryMap::pus/popMappingsToAncestor can total ~2% of the profile when animating transforms.

* rendering/RenderGeometryMap.cpp:
(WebCore):
(WebCore::RenderGeometryMap::absolutePoint):
(WebCore::RenderGeometryMap::absoluteRect):
(WebCore::RenderGeometryMap::mapToAbsolute):
(WebCore::RenderGeometryMap::push):
(WebCore::RenderGeometryMap::pushView):
(WebCore::RenderGeometryMap::popMappingsToAncestor):
* rendering/RenderGeometryMap.h:
(WebCore):
(WebCore::RenderGeometryMapStep::RenderGeometryMapStep):

    Move to header.

(RenderGeometryMapStep):
(RenderGeometryMap):

    Make the step vector hold RenderGeometryMapSteps instead of RenderGeometryMapStep*'s.

(WTF):

    Give RenderGeometryMapSteps SimpleClassVectorTraits. This is needed for dealing with OwnPtr in the struct (and makes it faster too).
    The type is simple enought to move by memcpy.

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

12 years ago[GTK] Remove Windows support from plugins/gtk/
commit-queue@webkit.org [Thu, 28 Jun 2012 18:15:17 +0000 (18:15 +0000)]
[GTK] Remove Windows support from plugins/gtk/
https://bugs.webkit.org/show_bug.cgi?id=89501

Patch by Kalev Lember <kalevlember@gmail.com> on 2012-06-28
Reviewed by Martin Robinson.

The GTK+ port now uses plugins/gtk/ on Windows, which leaves
PluginPackageGtk.cpp and PluginViewGtk.cpp solely for XP_UNIX platforms.

* plugins/gtk/PluginPackageGtk.cpp:
(WebCore::PluginPackage::fetchInfo):
(WebCore::webkitgtkXError):
(WebCore::PluginPackage::load):
* plugins/gtk/PluginViewGtk.cpp:
(WebCore::getRootWindow):
(WebCore::PluginView::updatePluginWidget):
(WebCore::PluginView::paint):
(WebCore::PluginView::handleKeyboardEvent):
(WebCore::setXCrossingEventSpecificFields):
(WebCore::PluginView::handleMouseEvent):
(WebCore::PluginView::handleFocusOutEvent):
(WebCore::PluginView::setNPWindowIfNeeded):
(WebCore::PluginView::platformGetValueStatic):
(WebCore::PluginView::platformGetValue):
(WebCore::getPluginDisplay):
(WebCore::getVisualAndColormap):
(WebCore::PluginView::platformStart):
(WebCore::PluginView::platformDestroy):

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

12 years agoChange FrameView::scrollContentsFastPath to use m_fixedObjects
simon.fraser@apple.com [Thu, 28 Jun 2012 18:08:46 +0000 (18:08 +0000)]
Change FrameView::scrollContentsFastPath to use m_fixedObjects
https://bugs.webkit.org/show_bug.cgi?id=90045

Reviewed by James Robinson.

FrameView now has a hash set of fixed-position objects, so use
that instead of RenderBlock::positionedObjects(); we'll avoid traversing
through absolutely positioned objects, and this will work better for sticky
positioning in future.

No behavior change, so no new tests.

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

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

12 years agoSplit flex into flex-grow/flex-shrink/flex-basis
tony@chromium.org [Thu, 28 Jun 2012 18:06:09 +0000 (18:06 +0000)]
Split flex into flex-grow/flex-shrink/flex-basis
https://bugs.webkit.org/show_bug.cgi?id=86525

Reviewed by Ojan Vafai.

Source/WebCore:

Split flex into 3 separate properties per the spec:
http://dev.w3.org/csswg/css3-flexbox/#flex-components

Tests: css3/flexbox/flex-longhand-parsing.html
       css3/flexbox/flex-property-parsing.html: Updated test results.

* css/CSSComputedStyleDeclaration.cpp:
(WebCore): -webkit-flex is no longer enumerable.
(WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Add new css property names and use
getCSSPropertyValuesForShorthandProperties for WebkitFlex. Also sort flex propery names.
* css/CSSParser.cpp:
(WebCore::isValidKeywordPropertyAndValue): Fix indent.
(WebCore::CSSParser::parseValue): Add parsing for new properties and handle -webkit-flex: none.
(WebCore::CSSParser::parseFlex): Switch to new names (positive -> grow, negative -> shrink,
preferred size -> basis) and assign to longhand properties.
* css/CSSParser.h:
* css/CSSProperty.cpp:
(WebCore::CSSProperty::isInheritedProperty): Add new properties.
* css/CSSPropertyNames.in: Add new properties.
* css/StyleBuilder.cpp:
(WebCore::StyleBuilder::StyleBuilder): Delete special handling of applying flex and just use shorthand handlers.
* css/StylePropertySet.cpp:
(WebCore::StylePropertySet::getPropertyValue): Add new shorthand.
(WebCore::StylePropertySet::asText):
* css/StylePropertyShorthand.cpp:
(WebCore::webkitFlexShorthand): Add new shorthand.
(WebCore::shorthandForProperty):
* css/StylePropertyShorthand.h:
* css/StyleResolver.cpp:
(WebCore::StyleResolver::collectMatchingRulesForList): Add to list of properties applied by StyleBuilder.
Handle initial and inherit for flex.

LayoutTests:

If -webkit-flex is set to none, when the user reads the value back out, it is
now 0 0 auto. 'none' is for convenience, not an actual value.

* css3/flexbox/flex-longhand-parsing-expected.txt:
* css3/flexbox/flex-longhand-parsing.html: Test flex-grow, flex-shrink and flex-basis.
* css3/flexbox/flex-property-parsing-expected.txt:
* css3/flexbox/flex-property-parsing.html: Update results for 'none'.
* fast/css/getComputedStyle/computed-style-expected.txt:
* fast/css/getComputedStyle/computed-style-without-renderer-expected.txt:
* fast/css/getComputedStyle/resources/property-names.js: Remove -webkit-flex since it's no longer enumerable.
* svg/css/getComputedStyle-basic-expected.txt:

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

12 years ago[GTK][Win]: Fix plugin drawing to an offscreen buffer
commit-queue@webkit.org [Thu, 28 Jun 2012 18:00:42 +0000 (18:00 +0000)]
[GTK][Win]: Fix plugin drawing to an offscreen buffer
https://bugs.webkit.org/show_bug.cgi?id=89499

Patch by Kalev Lember <kalevlember@gmail.com> on 2012-06-28
Reviewed by Brent Fulgham.

Take into account that the GTK+ port draws to a backing store and adjust
the target rectangle calculation accordingly.

* plugins/win/PluginViewWin.cpp:
(WebCore::PluginView::paint):
(WebCore::PluginView::setNPWindowRect):

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

12 years ago[WK2] platform/mac/editing/spelling/autocorrection-blockquote-crash.html fails.
kling@webkit.org [Thu, 28 Jun 2012 17:14:23 +0000 (17:14 +0000)]
[WK2] platform/mac/editing/spelling/autocorrection-blockquote-crash.html fails.
<http://webkit.org/b/90156>

Skip this test on mac-wk2 for now.

* platform/mac-wk2/Skipped:

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

12 years agoOptimize Dromaeo/dom-attr.html by speeding up Element::getAttribute()
haraken@chromium.org [Thu, 28 Jun 2012 17:07:01 +0000 (17:07 +0000)]
Optimize Dromaeo/dom-attr.html by speeding up Element::getAttribute()
https://bugs.webkit.org/show_bug.cgi?id=90174

Reviewed by Adam Barth.

This patch improves performance of Dromaeo/dom-attr.html by 4.0%.
The patch improves performance of getAttribute() and JavaScript
property setter for DOM objects (e.g. 'div.foo = 123').
The performance improvement becomes larger, as the number of
attributes defined on the DOM object increases.

Without the patch in Chromium/Linux (runs/s)
7679.4, 7739.7, 7634.0, 7726.4, 7663.9

With the patch in Chromium/Linux (runs/s)
7977.7, 8032.2, 8112.8, 7948.1, 7924.5

This patch just changes a type of 'name' of Element::getAttribute(String& name)
from String& to AtomicString&.

The key observation is that AtomicString(String& x) is faster than
operator==(String& x, AtomicString& y). AtomicString(String& x) calculates
a hash of a given String and adds it to a hash table. The calculation
complexity is O(the length of x). On the other hand,
operator==(String& x, AtomicString& y) compares a String and an AtomicString by
StringImpl::equal(StringImpl*, StringImpl*), the calculation complexity of
which is O(2 * min(the length of x, the length of y)).
In addition, the comparison logic is more complicated than the logic
of calculating the hash. Consequently, AtomicString(String& x) is
faster than operator==(String& x, AtomicString& y).

Keeping that in mind, let's estimate the performance of
Element::getAttribute("class") for <div id="A" lang="B" title="C" class="D" dir="E">.
Here "id", "lang", "title", "class" and "dir" are stored as AtomicStrings
in QualifiedName::localName(). Initially, "class" in Element::getAttribute("class")
is a String.

If we use Element::getAttribute(String& name) (i.e. without the patch),
ElementAttributeData::getAttributeItemIndex() executes four
operator==(String&, AtomicString&) by the time it finds the "class" attribute:

(1) if ("class" == "id")       // operator==(String&, AtomicString&)
(2) if ("class" == "lang")     // operator==(String&, AtomicString&)
(3) if ("class" == "title")    // operator==(String&, AtomicString&)
(4) if ("class" == "class")    // operator==(String&, AtomicString&)

On the other hand, if we use Element::getAttribute(AtomicString& name)
(i.e. with the patch), ElementAttributeData::getAttributeItemIndex()
executes one AtomicString(String&) and four operator==(AtomicString&, AtomicString&)
by the time it finds the "class" attribute:

(1) AtomicString("class")      // AtomicString(String&)
(2) if ("class" == "id")       // operator==(AtomicString&, AtomicString&)
(3) if ("class" == "lang")     // operator==(AtomicString&, AtomicString&)
(4) if ("class" == "title")    // operator==(AtomicString&, AtomicString&)
(5) if ("class" == "class")    // operator==(AtomicString&, AtomicString&)

Considering that the overhead of operator==(AtomicString&, AtomicString&) is close
to 0 since it is just a pointer comparison, the latter approach is faster than
the former approach.

Performance improvement will be large for elements that have multiple attributes,
but it is faster even for elements that have only one attribute.
For exmaple, Dromaeo/dom-attr.html tests getAttribute() for an element that has
only one attribute, the result shows 4.0% improvement.

Another example optimized by this patch is 'div.foo = 123', where foo is not
an attribute of div. In this case, before 123 is set, JavaScript calls back
Element::getAttribute() to check whether 'foo' is defined on div by
scanning all the attributes of div.

No tests. No change in behavior.

* dom/Element.cpp:
(WebCore::Element::getAttribute):
* dom/Element.h:
(Element):
(WebCore::Element::getAttributeItemIndex):
* dom/ElementAttributeData.cpp:
(WebCore::ElementAttributeData::getAttributeItemIndexSlowCase):
* dom/ElementAttributeData.h:
(ElementAttributeData):
(WebCore::ElementAttributeData::getAttributeItem):
(WebCore::ElementAttributeData::getAttributeItemIndex):

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

12 years agoSpeech JavaScript API: Don't dispatch end event after ActiveDOMObject::stop()
hans@chromium.org [Thu, 28 Jun 2012 16:52:40 +0000 (16:52 +0000)]
Speech JavaScript API: Don't dispatch end event after ActiveDOMObject::stop()
https://bugs.webkit.org/show_bug.cgi?id=90176

Reviewed by Adam Barth.

Source/WebCore:

It is probably not safe to dispatch an event on an object that has
been ActiveDOMObject::stop()'ed.

This used to happen in the navigate-away.html test, which I believe
then caused speechgrammar-basics.html (which was typically run
afterwards, by the same worker), to crash flakily. See Bug 89717.

Test: speechgrammar-basics.html should no longer be flaky.

* Modules/speech/SpeechRecognition.cpp:
(WebCore::SpeechRecognition::didEnd):
(WebCore::SpeechRecognition::stop):
(WebCore::SpeechRecognition::SpeechRecognition):
* Modules/speech/SpeechRecognition.h:

LayoutTests:

speechgrammar-basics.html should no longer be flaky.

* platform/chromium/TestExpectations:

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

12 years ago[GTK] [WK2] Memory leak in ResourceHandleSoup.cpp
commit-queue@webkit.org [Thu, 28 Jun 2012 16:43:23 +0000 (16:43 +0000)]
[GTK] [WK2] Memory leak in ResourceHandleSoup.cpp
https://bugs.webkit.org/show_bug.cgi?id=90168

Patch by Sudarsana Nagineni <sudarsana.nagineni@linux.intel.com> on 2012-06-28
Reviewed by Martin Robinson.

Fixed a memory leak in WebCoreSynchronousLoader by using adoptGRef
instead of just getting new reference of GMainLoop.

No new tests. No change in behavior.

* platform/network/soup/ResourceHandleSoup.cpp:
(WebCore::WebCoreSynchronousLoader::WebCoreSynchronousLoader):

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

12 years ago[chromium] Do not multiply bounds by contentsScale in TiledLayerChromium and CanvasLa...
danakj@chromium.org [Thu, 28 Jun 2012 16:35:33 +0000 (16:35 +0000)]
[chromium] Do not multiply bounds by contentsScale in TiledLayerChromium and CanvasLayerTextureUpdater
https://bugs.webkit.org/show_bug.cgi?id=90103

Reviewed by Adrienne Walker.

Source/WebCore:

Non-integer scale factors can scale the bounds of a layer such that
different rounding is applied to the width and height in the content
bounds. We should never multiply bounds by contentsScale in order to
work correctly with non-integer scale factors. Instead, always use the
contentBounds/bounds ratio for width and height independently.

Tests: TiledLayerChromiumTest.nonIntegerContentsScaleIsNotDistortedDuringPaint
       TiledLayerChromiumTest.nonIntegerContentsScaleIsNotDistortedDuringInvalidation

* platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.cpp:
(WebCore::BitmapCanvasLayerTextureUpdater::prepareToUpdate):
* platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.h:
(BitmapCanvasLayerTextureUpdater):
* platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.cpp:
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::prepareToUpdate):
* platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.h:
(BitmapSkPictureCanvasLayerTextureUpdater):
* platform/graphics/chromium/CanvasLayerTextureUpdater.cpp:
(WebCore::CanvasLayerTextureUpdater::paintContents):
* platform/graphics/chromium/CanvasLayerTextureUpdater.h:
(CanvasLayerTextureUpdater):
* platform/graphics/chromium/LayerTextureUpdater.h:
(WebCore::LayerTextureUpdater::prepareToUpdate):
* platform/graphics/chromium/ScrollbarLayerChromium.cpp:
(WebCore::ScrollbarLayerChromium::updatePart):
* platform/graphics/chromium/SkPictureCanvasLayerTextureUpdater.cpp:
(WebCore::SkPictureCanvasLayerTextureUpdater::prepareToUpdate):
* platform/graphics/chromium/SkPictureCanvasLayerTextureUpdater.h:
(SkPictureCanvasLayerTextureUpdater):
* platform/graphics/chromium/TiledLayerChromium.cpp:
(WebCore::TiledLayerChromium::setNeedsDisplayRect):
(WebCore::TiledLayerChromium::updateTiles):

Source/WebKit/chromium:

* tests/CCTiledLayerTestCommon.cpp:
(WebKitTests::FakeLayerTextureUpdater::prepareToUpdate):
* tests/CCTiledLayerTestCommon.h:
(FakeTiledLayerChromium):
* tests/TiledLayerChromiumTest.cpp:

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

12 years ago[Qt] Make GC's fill{Rounded}Rect use optimized shadow blur code
commit-queue@webkit.org [Thu, 28 Jun 2012 16:14:54 +0000 (16:14 +0000)]
[Qt] Make GC's fill{Rounded}Rect use optimized shadow blur code
https://bugs.webkit.org/show_bug.cgi?id=90082

Patch by Bruno de Oliveira Abinader <bruno.abinader@basyskom.com> on 2012-06-28
Reviewed by Noam Rosenthal.

ShadowBlur::drawRectShadow makes use of optimized tiles-based drawPattern, which
is not present when using {begin/end}shadowLayer.

* platform/graphics/qt/GraphicsContextQt.cpp:
(WebCore::GraphicsContext::fillRect):
(WebCore::GraphicsContext::fillRoundedRect):
(WebCore::GraphicsContext::pushTransparencyLayerInternal):

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

12 years ago[chromium] Introduce way to reload a page using the original request URL
commit-queue@webkit.org [Thu, 28 Jun 2012 16:05:43 +0000 (16:05 +0000)]
[chromium] Introduce way to reload a page using the original request URL
https://bugs.webkit.org/show_bug.cgi?id=89788

Patch by Dan Alcantara <dfalcantara@chromium.org> on 2012-06-28
Reviewed by Adam Barth.

Adds a new reload method for cases where we need to override the URL
when reloading a page. This is needed for situations where a server
redirects navigation based on information that may have changed since
the last time the page was loaded.

User agents, for example, can cause a server to redirect to the mobile
version of a page.  Changing to the desktop version by switching user agents
requires loading a URL from before the redirect occurred.

Also adds a unit test to confirm that scroll position and page scale are
saved when the reload occurs.

* public/WebFrame.h:
(WebFrame):
* src/WebFrameImpl.cpp:
(WebKit::WebFrameImpl::reloadWithGivenURL):
(WebKit):
* src/WebFrameImpl.h:
(WebFrameImpl):
* src/WebViewImpl.cpp:
(WebKit::WebViewImpl::WebViewImpl):
(WebKit::WebViewImpl::setClearPageScaleFactorOnLoad):
(WebKit):
(WebKit::WebViewImpl::didCommitLoad):
* src/WebViewImpl.h:
(WebViewImpl):

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

12 years agoWeb Inspector: Provide context menu 'Delete all watch expressions.'
commit-queue@webkit.org [Thu, 28 Jun 2012 15:43:36 +0000 (15:43 +0000)]
Web Inspector: Provide context menu 'Delete all watch expressions.'
https://bugs.webkit.org/show_bug.cgi?id=89735

Patch by Rahul Tiwari <rahultiwari.cse.iitr@gmail.com> on 2012-06-28
Reviewed by Yury Semikhatsky.

Added context menu delete and delete all watch expressions.

No new tests required as its a minor UI related change.

* English.lproj/localizedStrings.js:
* inspector/front-end/WatchExpressionsSidebarPane.js:
(WebInspector.WatchExpressionsSection.prototype.updateExpression):
(WebInspector.WatchExpressionsSection.prototype._deleteAllExpressions):
(WebInspector.WatchExpressionsSection.prototype.findAddedTreeElement):
(WebInspector.WatchExpressionTreeElement.prototype.update):
(WebInspector.WatchExpressionTreeElement.prototype._contextMenu):
(WebInspector.WatchExpressionTreeElement.prototype._deleteAllButtonClicked):

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

12 years agom_cssVariablesEnabled member is not initialized in Page Settings
commit-queue@webkit.org [Thu, 28 Jun 2012 15:33:11 +0000 (15:33 +0000)]
m_cssVariablesEnabled member is not initialized in Page Settings
https://bugs.webkit.org/show_bug.cgi?id=90147

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-06-28
Reviewed by Simon Hausmann.

Properly initialize the m_cssVariablesEnabled member in Page
Settings.

No new tests, no behavior change.

* page/Settings.cpp:
(WebCore::Settings::Settings):

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

12 years ago[Qt][NRWT] Fix baseline and skipped file search path.
ossy@webkit.org [Thu, 28 Jun 2012 14:43:16 +0000 (14:43 +0000)]
[Qt][NRWT] Fix baseline and skipped file search path.
https://bugs.webkit.org/show_bug.cgi?id=89882

Unreviewed trivial typo fix after r121430.

* Scripts/webkitpy/layout_tests/port/qt_unittest.py:
(QtPortTest._assert_search_path):
(QtPortTest._assert_skipped_path):

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

12 years ago[Qt][NRWT] Fix baseline and skipped file search path.
ossy@webkit.org [Thu, 28 Jun 2012 14:33:11 +0000 (14:33 +0000)]
[Qt][NRWT] Fix baseline and skipped file search path.
https://bugs.webkit.org/show_bug.cgi?id=89882

Patch by János Badics <jbadics@inf.u-szeged.hu> on 2012-06-28
Reviewed by Csaba Osztrogonác.

* Scripts/webkitpy/layout_tests/port/qt.py:
(QtPort._search_paths):
(QtPort):
(QtPort.baseline_search_path):
(QtPort._skipped_file_search_paths):
* Scripts/webkitpy/layout_tests/port/qt_unittest.py:
(QtPortTest):
(QtPortTest._assert_skipped_path):
(QtPortTest.test_baseline_search_path):
(QtPortTest.test_skipped_file_search_path):

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

12 years ago[Qt] inspector/styles/inject-stylesheet.html makes 4 tests flakey (TEXT PASS)
apavlov@chromium.org [Thu, 28 Jun 2012 14:27:27 +0000 (14:27 +0000)]
[Qt] inspector/styles/inject-stylesheet.html makes 4 tests flakey (TEXT PASS)
https://bugs.webkit.org/show_bug.cgi?id=90167

Reviewed by Csaba Osztrogonác.

Source/WebKit/qt:

* WebCoreSupport/DumpRenderTreeSupportQt.cpp:
(DumpRenderTreeSupportQt::removeUserStyleSheets):
* WebCoreSupport/DumpRenderTreeSupportQt.h:

Tools:

DRT should remove user stylesheets from the page group when resetting before running another test.

* DumpRenderTree/qt/DumpRenderTreeQt.cpp:
(WebCore::DumpRenderTree::resetToConsistentStateBeforeTesting):

LayoutTests:

Unskip the previously offensive test.

* platform/qt/Skipped:

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

12 years ago[WK2] New fast/events/drag-display-none-element.html fails
ossy@webkit.org [Thu, 28 Jun 2012 14:10:12 +0000 (14:10 +0000)]
[WK2] New fast/events/drag-display-none-element.html fails
https://bugs.webkit.org/show_bug.cgi?id=90177

Unreviewed gardening, skip the new failing test.

* platform/wk2/Skipped:

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

12 years ago[Qt] css3/filters/huge-region-composited.html makes css3/filters/huge-region.html...
ossy@webkit.org [Thu, 28 Jun 2012 13:16:42 +0000 (13:16 +0000)]
[Qt] css3/filters/huge-region-composited.html makes css3/filters/huge-region.html crash
https://bugs.webkit.org/show_bug.cgi?id=90165

[Qt] inspector/styles/inject-stylesheet.html makes 4 tests flakey (TEXT PASS)
https://bugs.webkit.org/show_bug.cgi?id=90167

Unreviewed gardening, skip the guilty tests.

* platform/qt/Skipped:

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

12 years ago[Qt][DRT] Reset AcceleratedCompositingEnabled between tests
ossy@webkit.org [Thu, 28 Jun 2012 13:07:38 +0000 (13:07 +0000)]
[Qt][DRT] Reset AcceleratedCompositingEnabled between tests
https://bugs.webkit.org/show_bug.cgi?id=90164

Reviewed by Simon Hausmann.

* DumpRenderTree/qt/DumpRenderTreeQt.cpp:
(WebCore::WebPage::resetSettings):

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

12 years ago[Qt] Restore original value of mock scrollbars between tests
ossy@webkit.org [Thu, 28 Jun 2012 11:39:31 +0000 (11:39 +0000)]
[Qt] Restore original value of mock scrollbars between tests
https://bugs.webkit.org/show_bug.cgi?id=90155

Reviewed by Simon Hausmann.

Source/WebKit/qt:

* WebCoreSupport/DumpRenderTreeSupportQt.cpp:
(DumpRenderTreeSupportQt::setMockScrollbarsEnabled):
* WebCoreSupport/DumpRenderTreeSupportQt.h:

Tools:

* DumpRenderTree/qt/DumpRenderTreeQt.cpp:
(WebCore::WebPage::resetSettings):
* DumpRenderTree/qt/LayoutTestControllerQt.cpp:
(LayoutTestController::setMockScrollbarsEnabled):
* DumpRenderTree/qt/LayoutTestControllerQt.h:
(LayoutTestController):

LayoutTests:

* platform/qt/Skipped: Unskip tests which doesn't break anything now.

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

12 years ago[EFL] Gardening after r121388
commit-queue@webkit.org [Thu, 28 Jun 2012 09:57:20 +0000 (09:57 +0000)]
[EFL] Gardening after r121388
https://bugs.webkit.org/show_bug.cgi?id=90145

Unreviewed EFL gardening. The new fast/events/drag-display-none-element.html
test added in r121388 does not pass on EFL port because of missing drag'n'drop support.

Patch by Mikhail Pozdnyakov <mikhail.pozdnyakov@intel.com> on 2012-06-28

* platform/efl/TestExpectations:

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

12 years ago[Qt] plugin is loaded to the web process via MainResourceLoader::substituteMIMETypeFr...
kbalazs@webkit.org [Thu, 28 Jun 2012 09:36:04 +0000 (09:36 +0000)]
[Qt] plugin is loaded to the web process via MainResourceLoader::substituteMIMETypeFromPluginDatabase
https://bugs.webkit.org/show_bug.cgi?id=86489

Reviewed by Simon Hausmann.

Removed the substituteMIMETypeFromPluginDatabase quirk from
MainResourceLoader. It would be possible to fix it in a way
that is compatible with WebKit2, but given that it was a Qt
only fix, and that it's not clear that we still need it, and
it's not even work currently, I decided to remove it. At least
it is -1 platform ifdef in common code.

Just removed a non-tested quirk, no test needed.

* loader/MainResourceLoader.cpp:
(WebCore::MainResourceLoader::didReceiveResponse):

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

12 years ago<http://webkit.org/b/90096> Building within Xcode sometimes does a full rebuild after...
mrowe@apple.com [Thu, 28 Jun 2012 09:30:28 +0000 (09:30 +0000)]
<webkit.org/b/90096> Building within Xcode sometimes does a full rebuild after building via build-webkit

We need to ensure that build-webkit uses the same setting for SHARED_PRECOMPS_DIR
as what Xcode itself will use when building, otherwise switching between the two
can result in the precompiled headers being rebuilt and thus the entire world
rebuilding.

Reviewed by Dan Bernstein.

* Scripts/webkitdirs.pm:
(determineBaseProductDir):

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

12 years ago[V8] Optimize Integer::New() by caching persistent handles for small integers
haraken@chromium.org [Thu, 28 Jun 2012 08:51:58 +0000 (08:51 +0000)]
[V8] Optimize Integer::New() by caching persistent handles for small integers
https://bugs.webkit.org/show_bug.cgi?id=90043

Reviewed by Adam Barth.

The patch improves performance of Dromaeo/dom-query.html by 3.6%,
and Bindings/scroll-top.html by 17.3%.

The performance results in my Chromium/Linux:

[Dromaeo/dom-query.html]
796310.4 runs/s => 824745.4 runs/s (+3.6%)

[Bindings/scroll-top.html]
204.68 runs/s => 240.15 runs/s (+17.3%)

This patch introduces V8BindingPerIsolateData::IntegerCache (just like
V8BindingPerIsolateData::StringCache) to cache persistent handles
for small integers.

No new tests. No change in behavior.

* bindings/v8/V8Binding.h: Implemented v8Integer() and v8UnsignedInteger(),
which returns cached persistent handles for integers smaller than 64.
(WebCore):
(IntegerCache):
(WebCore::IntegerCache::IntegerCache):
(WebCore::IntegerCache::v8Integer):
(WebCore::IntegerCache::v8UnsignedInteger):
(WebCore::V8BindingPerIsolateData::integerCache):
(V8BindingPerIsolateData):
(WebCore::v8Integer):
(WebCore::v8UnsignedInteger):
* bindings/v8/V8Binding.cpp:
(WebCore):
(WebCore::IntegerCache::createSmallIntegers):
* bindings/v8/WorkerScriptController.cpp:
(~WorkerScriptController): ~V8BindingPerIsolateData() should be called before
isolate->Exit(), since ~V8BindingPerIsolateData() calls V8 APIs that requires
the current isolate.

* bindings/scripts/CodeGeneratorV8.pm: Replaced Integer::New() and Integer::NewFromUnsigned()
with v8Integer() and v8UnsignedInteger().
(GenerateNormalAttrGetter):
(NativeToJSValue):

* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp: Updated run-bindings-tests results.
(WebCore::TestActiveDOMObjectV8Internal::excitingAttrAttrGetter):
* bindings/scripts/test/V8/V8TestObj.cpp: Ditto.
(WebCore::TestObjV8Internal::readOnlyIntAttrAttrGetter):
(WebCore::TestObjV8Internal::shortAttrAttrGetter):
(WebCore::TestObjV8Internal::unsignedShortAttrAttrGetter):
(WebCore::TestObjV8Internal::intAttrAttrGetter):
(WebCore::TestObjV8Internal::reflectedIntegralAttrAttrGetter):
(WebCore::TestObjV8Internal::reflectedUnsignedIntegralAttrAttrGetter):
(WebCore::TestObjV8Internal::reflectedCustomIntegralAttrAttrGetter):
(WebCore::TestObjV8Internal::attrWithGetterExceptionAttrGetter):
(WebCore::TestObjV8Internal::attrWithSetterExceptionAttrGetter):
(WebCore::TestObjV8Internal::withScriptStateAttributeAttrGetter):
(WebCore::TestObjV8Internal::conditionalAttr1AttrGetter):
(WebCore::TestObjV8Internal::conditionalAttr2AttrGetter):
(WebCore::TestObjV8Internal::conditionalAttr3AttrGetter):
(WebCore::TestObjV8Internal::enabledAtRuntimeAttr1AttrGetter):
(WebCore::TestObjV8Internal::enabledAtRuntimeAttr2AttrGetter):
(WebCore::TestObjV8Internal::enabledAtContextAttr1AttrGetter):
(WebCore::TestObjV8Internal::enabledAtContextAttr2AttrGetter):
(WebCore::TestObjV8Internal::strawberryAttrGetter):
(WebCore::TestObjV8Internal::descriptionAttrGetter):
(WebCore::TestObjV8Internal::idAttrGetter):
(WebCore::TestObjV8Internal::intMethodCallback):
(WebCore::TestObjV8Internal::intMethodWithArgsCallback):
(WebCore::TestObjV8Internal::classMethodWithOptionalCallback):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp: Ditto.
(WebCore::TestSerializedScriptValueInterfaceV8Internal::portsAttrGetter):

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

12 years agoClassify form control states by their owner forms
tkent@chromium.org [Thu, 28 Jun 2012 08:48:20 +0000 (08:48 +0000)]
Classify form control states by their owner forms
https://bugs.webkit.org/show_bug.cgi?id=89950

Reviewed by Hajime Morita.

Source/JavaScriptCore:

* JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
Expose WTF::StringBuilder::canShrink()

Source/WebCore:

To improve robustness of the form state restore feature, we classify
form control states by their owner forms. Owner forms are identified by
their action URLs and index numbers in forms with the same action URLs.

Implementation approach:
Extend FormElementKey class to have "formKey" string, which is a
combination of the action URL and an index number, or a fixed string for
no form owner.
FormKeyGenerator class is responsible to generate the "formKey" strings

Test: fast/forms/state-restore-per-form.html

* html/FormController.cpp:
(FormKeyGenerator):
(WebCore::FormKeyGenerator::create): A factory function.
(WebCore::FormKeyGenerator::FormKeyGenerator): A private constructor.
(WebCore::createKey):
A helper for formKey(). This makes strings like "<action URL> #<index>".
(WebCore::FormKeyGenerator::formKey):
Returns a formKey for the specified HTMLFormElement*.
(WebCore::FormKeyGenerator::willDeleteForm):
Unregister HTMLFormElement*. This function is necessary because form
restore feature works during parsing and a script might delete form
elements.
(WebCore::formStateSignature): Bump the version.
(WebCore::FormController::formElementsState):
Records a formKey string for each of control state.
(WebCore::FormController::setStateForNewFormElements):
Loads formKeys from stateVector, and uses them for FormElementKey.
(WebCore::FormController::takeStateForFormElement):
- Construct and destruct FormKeyGenerator if needed.
- Passing a formKey for the specified form control to FormElementKey.
(WebCore::FormController::willDeleteForm):
Delegate to FormKeyGenerator::willDeleteForm.

(WebCore::FormElementKey::FormElementKey): Add formKey argument and member.
(WebCore::FormElementKey::operator=): ditto.
(WebCore::FormElementKey::ref): ditto.
(WebCore::FormElementKey::deref): ditto.
* html/FormController.h:
(FormElementKey): Add formKey argument and member.
(FormController): Add a FormKeyGenerator member which is used during restoring.

* html/HTMLFormElement.cpp:
(WebCore::HTMLFormElement::~HTMLFormElement): Notify the death to FormController.

LayoutTests:

* fast/forms/resources/state-restore-per-form-back.html: Added.
* fast/forms/state-restore-per-form-expected.txt:
Added. This contains some FAIL lines. They are expected and will
be fixed in webkit.org/b/89962.
* fast/forms/state-restore-per-form.html: Added.
* fast/forms/state-restore-broken-state-expected.txt:
Updated for the serialization format change.

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

12 years ago[Chromium] Test expectation update
tkent@chromium.org [Thu, 28 Jun 2012 08:44:50 +0000 (08:44 +0000)]
[Chromium] Test expectation update

* platform/chromium/TestExpectations:
platform/chromium/accessibility/add-to-menu-list-crashes.html is passing.

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

12 years agoUnreviewed GTK gardening, removing crash expectation for the
zandobersek@gmail.com [Thu, 28 Jun 2012 08:39:26 +0000 (08:39 +0000)]
Unreviewed GTK gardening, removing crash expectation for the
fast/workers/worker-context-gc.html test as the offending revision
was rolled out in r121417.

* platform/gtk/TestExpectations:

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

12 years agoUnreviewed, rolling out r121395.
zandobersek@gmail.com [Thu, 28 Jun 2012 08:34:47 +0000 (08:34 +0000)]
Unreviewed, rolling out r121395.
http://trac.webkit.org/changeset/121395
https://bugs.webkit.org/show_bug.cgi?id=90143

Patch causes crashes in fast/workers/worker-context-gc.html
(Requested by zdobersek on #webkit).

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

Source/WebCore:

* Modules/indexeddb/IDBFactory.cpp:
(WebCore::IDBFactory::open):
* workers/DedicatedWorkerThread.cpp:
(WebCore::DedicatedWorkerThread::create):
(WebCore::DedicatedWorkerThread::DedicatedWorkerThread):
* workers/DedicatedWorkerThread.h:
(DedicatedWorkerThread):
* workers/DefaultSharedWorkerRepository.cpp:
(SharedWorkerProxy):
(WebCore::DefaultSharedWorkerRepository::workerScriptLoaded):
* workers/SharedWorkerThread.cpp:
(WebCore::SharedWorkerThread::create):
(WebCore::SharedWorkerThread::SharedWorkerThread):
* workers/SharedWorkerThread.h:
(SharedWorkerThread):
* workers/WorkerMessagingProxy.cpp:
(WebCore::WorkerMessagingProxy::startWorkerContext):
* workers/WorkerThread.cpp:
(WebCore::WorkerThreadStartupData::create):
(WorkerThreadStartupData):
(WebCore::WorkerThreadStartupData::WorkerThreadStartupData):
(WebCore::WorkerThread::WorkerThread):
* workers/WorkerThread.h:
(WorkerThread):

Source/WebKit/chromium:

* src/WebSharedWorkerImpl.cpp:
(WebKit::WebSharedWorkerImpl::startWorkerContext):
* src/WebWorkerClientImpl.cpp:
(WebKit::WebWorkerClientImpl::startWorkerContext):

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

12 years ago[Qt] KURL assert at fast/loader/opaque-base-url.html
kbalazs@webkit.org [Thu, 28 Jun 2012 07:46:54 +0000 (07:46 +0000)]
[Qt] KURL assert at fast/loader/opaque-base-url.html
https://bugs.webkit.org/show_bug.cgi?id=89468

Reviewed by Simon Hausmann.

Don't use the KURL(ParsedURLStringTag, const String&) constructor.
We cannot be sure that the url in encode was valid and even if it
was the message could have been corrupted.
* Shared/qt/WebCoreArgumentCodersQt.cpp:
(CoreIPC::::encode):
(CoreIPC::::decode):

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

12 years ago[Platform] Implement functions for localized time format information
yosin@chromium.org [Thu, 28 Jun 2012 07:30:11 +0000 (07:30 +0000)]
[Platform] Implement functions for localized time format information
https://bugs.webkit.org/show_bug.cgi?id=89965

Reviewed by Kent Tamura.

Source/WebCore:

This patch introduces three functions for time format:
  1. localizedTimeFormatText()
  2. localizedShortTimeFormatText()
  2. timeAMPMLabels()
for input type "time" if ENABLE(INPUT_TYPE_TIME_MULTIPLE_FIELDS) is true.

Having both localizedTimeFormat and localizedShortTimeFormat is for
displaying only two fields hour and minute when step >= 60. There is
no way to remove second field from "h:m:s" pattern string. We don't
know whether ":" after "m" belongs minute or second field.

Test: WebKit/chromium/tests/LocalizedDateICUTest.cpp

* platform/text/LocaleICU.cpp:
(WebCore::LocaleICU::LocaleICU):
(WebCore::createFallbackAMPMLabels): Added.
(WebCore::LocaleICU::initializeDateTimeFormat):  Added.
(WebCore::LocaleICU::localizedTimeFormatText):  Added.
(WebCore::LocaleICU::localizedShortTimeFormatText):  Added.
(WebCore::LocaleICU::timeAMPMLabels):  Added.
* platform/text/LocaleICU.h:
(LocaleICU):
* platform/text/LocalizedDate.h:
* platform/text/LocalizedDateICU.cpp:
(WebCore::localizedTimeFormatText):  Added.
(WebCore::localizedShortTimeFormatText):  Added.
(WebCore::timeAMPMLabels):  Added.

Source/WebKit/chromium:

This patch adds new test LocalizedDateICUTest if ENABLE(INPUT_TYPE_TIME_MULTIPLE_FIELDS)
is true.

* WebKit.gypi:
* tests/LocalizedDateICUTest.cpp: Added.
(LocalizedDateICUTest):
(Labels):
(LocalizedDateICUTest::Labels::Labels):
(LocalizedDateICUTest::Labels::operator==):
(LocalizedDateICUTest::Labels::toString):
(LocalizedDateICUTest::labels):
(LocalizedDateICUTest::localizedDateFormatText):
(LocalizedDateICUTest::localizedShortDateFormatText):
(LocalizedDateICUTest::timeAMPMLabels):
(operator<<):
(TEST_F):

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

12 years ago[Qt] Unreviewed gardening, skip a new test to hide an annoying bug
ossy@webkit.org [Thu, 28 Jun 2012 07:25:27 +0000 (07:25 +0000)]
[Qt] Unreviewed gardening, skip a new test to hide an annoying bug
https://bugs.webkit.org/show_bug.cgi?id=87680 (and paint the bot green)

* platform/qt/Skipped:

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

12 years agoUnreviewed GTK gardening, adding a crash expectation for the
zandobersek@gmail.com [Thu, 28 Jun 2012 07:17:42 +0000 (07:17 +0000)]
Unreviewed GTK gardening, adding a crash expectation for the
fast/workers/worker-context-gc.html test that started crashing after r121395.

* platform/gtk/TestExpectations:

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

12 years agoPerformance: Optimize Dromaeo/dom-query.html by caching NodeRareData on Document
haraken@chromium.org [Thu, 28 Jun 2012 06:29:27 +0000 (06:29 +0000)]
Performance: Optimize Dromaeo/dom-query.html by caching NodeRareData on Document
https://bugs.webkit.org/show_bug.cgi?id=90059

Reviewed by Ryosuke Niwa.

This patch improves performance of document.getElementsBy*().
e.g. the patch makes Dromaeo/dom-query.html 5.4% faster.

Dromaeo/dom-query.html without the patch (Chromium/Linux):
784714 runs/s, 765947 runs/s, 803109 runs/s, 804450 runs/s

Dromaeo/dom-query.html with the patch (Chromium/Linux):
839245 runs/s, 829867 runs/s, 811032 runs/s, 847486 runs/s

Based on the assumption that document.getElementsByClassName(),
document.getElementsByTagName() and document.getElementsByName()
would be used frequently in the real world, this patch implements
a fast path for Document methods that require to access NodeRareData.
Specifically, this patch caches a pointer to NodeRareData on Document,
by which Document can access NodeRareData without looking up a HashMap.

The only performance concern is the overhead of the isDocumentNode() check
that this patch added to Node::ensureRareData. However, I could not
observe any performance regression caused by the overhead.

No tests. No change in behavior.

* dom/Document.cpp:
(WebCore::Document::Document):
(WebCore::Document::setCachedRareData): I didn't inline this method,
since the inlining slightly regressed performance for some reason.
(WebCore):
* dom/Document.h:
(WebCore):
(WebCore::Document::cachedRareData):
(Document):
(~Document): Moved 'm_document = 0' to the tail of the destructor,
since isDocumentNode() has to return true in clearRareData() that is called
in ~Document().
* dom/Node.cpp:
(WebCore::Node::ensureRareData):
(~Node): Moved the assertion into clearRareData().

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

12 years agoUnreviewed. Fix the build without TEXTURE_MAPPER_GL.
carlosgc@webkit.org [Thu, 28 Jun 2012 06:24:56 +0000 (06:24 +0000)]
Unreviewed. Fix the build without TEXTURE_MAPPER_GL.

* WebProcess/WebPage/gtk/LayerTreeHostGtk.cpp:
* WebProcess/WebPage/gtk/LayerTreeHostGtk.h:
* WebProcess/WebPage/gtk/WebPageGtk.cpp:
(WebKit::WebPage::platformInitialize):

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

12 years ago[BlackBerry] 0-length response with no content-type shouldn't download
mary.wu@torchmobile.com.cn [Thu, 28 Jun 2012 06:09:50 +0000 (06:09 +0000)]
[BlackBerry] 0-length response with no content-type shouldn't download
https://bugs.webkit.org/show_bug.cgi?id=89860

Reviewed by Rob Buis.

RIM PR# 168419

For 0-length response, if we can't get its mimetype from the filename,
we set the mimetype to "text/plain" instead of "application/octet-stream",
so it won't go to download.

Reviewed internally by Charles Wei.

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

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