Implement computePreferredLogicalWidths on RenderGrid
https://bugs.webkit.org/show_bug.cgi?id=92908

Reviewed by Ojan Vafai.

Source/WebCore:

This functions implements a primitive computePreferredLogicalWidths
so that we properly handle vertical writing modes.

Covered by fast/css-grid-layout/place-cell-by-index.html.

* rendering/RenderGrid.cpp:
(WebCore::RenderGrid::computePreferredLogicalWidths):
* rendering/RenderGrid.h:
Added computePreferredLogicalWidths.

LayoutTests:

* fast/css-grid-layout/place-cell-by-index-expected.txt:
Updated the expected file (everything passes now).
* fast/css-grid-layout/place-cell-by-index.html:
Removed some FIXMEs and added one about the expected offsets making
a wrong assumption. It's fine to keep this testing until we support
this part of the spec.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@124671 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed, rolling out r124668.
http://trac.webkit.org/changeset/124668
https://bugs.webkit.org/show_bug.cgi?id=93167

Broke Mac build (Requested by kbr_google on #webkit).

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

Source/WebCore:

* bindings/js/JSArrayBufferViewHelper.h:
(WebCore::setWebGLArrayWithTypedArrayArgument):
(WebCore::setWebGLArrayHelper):
(WebCore::constructArrayBufferViewWithTypedArrayArgument):
(WebCore::constructArrayBufferViewWithArrayBufferArgument):
(WebCore::constructArrayBufferView):
* bindings/v8/custom/V8ArrayBufferViewCustom.h:
(WebCore::constructWebGLArrayWithArrayBufferArgument):
(WebCore):
(WebCore::constructWebGLArray):
(WebCore::setWebGLArrayHelper):

LayoutTests:

* fast/canvas/webgl/array-set-invalid-arguments-expected.txt: Removed.
* fast/canvas/webgl/array-set-invalid-arguments.html: Removed.
* fast/canvas/webgl/array-set-out-of-bounds-expected.txt:
* fast/canvas/webgl/data-view-crash-expected.txt:
* fast/canvas/webgl/data-view-test-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@124672 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Double tap gesture should send dblclick event
https://bugs.webkit.org/show_bug.cgi?id=92412

Patch by Rick Byers <rbyers@chromium.org> on 2012-08-03
Reviewed by Adam Barth.

Source/WebCore:

Propagate the tap count from PlatformGestureEvent in the derived mouse
events.

Also fixes a crash with unexpected GestureDoubleTap events by just
supressing them early.  They will probably be removed soon anyway.

Test: fast/events/touch/gesture/gesture-dblclick.html

* page/EventHandler.cpp:
(WebCore::EventHandler::handleGestureEvent):
(WebCore::EventHandler::handleGestureTap):

Source/WebKit/chromium:

Tweak comment to more completely describe the (lame) overloaded use
of deltaX in WebGestureEvent, and add a FIXME with the bug to track
cleaning it up.
* public/WebInputEvent.h:
(WebGestureEvent):

Tools:

Enable EventSender to set the tap count on tap gesture events.  The
delta X/Y parameters were not actually being used anymore (used to be
used for radius information).

* DumpRenderTree/chromium/TestRunner/EventSender.cpp:
(EventSender::gestureEvent):

LayoutTests:

Adds test for derived mouse events generated by a sequence of two tap
events.  Modeled after gesture-click.html.
* fast/events/touch/gesture/gesture-dblclick-expected.txt: Added.
* fast/events/touch/gesture/gesture-dblclick.html: Added.
* platform/chromium/fast/events/touch/gesture/gesture-dblclick-expected.txt: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@124673 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Layout Test media/video-currentTime-set2.html is flakily crashing
https://bugs.webkit.org/show_bug.cgi?id=92852

Unreviewed, test expectation change only.

The DCHECK in question was removed in http://crrev.com/149452


* platform/chromium/TestExpectations:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@124674 268f45cc-cd09-0410-ab3c-d52691b4dbfc
IndexedDB: Core upgradeneeded logic
https://bugs.webkit.org/show_bug.cgi?id=92558

Reviewed by Ojan Vafai.

Source/WebCore:

This is the backend webkit logic needed for integer versions. The rest
is in https://bugs.webkit.org/show_bug.cgi?id=89505.

I tried to make use of the existing processPendingCalls and added two
more queues, pendingOpenWithVersionCalls and
pendingSecondHalfOpenWithVersionCalls. The "second half" refers to
how there are two events that need to be fired in response to an
open-with-version call. The "second half" queue holds the open
requests that should immediately follow the caller's upgradeneeded
handler.

No new tests, there are so many they are in their own patch:
https://bugs.webkit.org/show_bug.cgi?id=92560

Though this patch doesn't change any expected behavior anyway, lack of
regressions is what we're hoping for here.

* Modules/indexeddb/IDBBackingStore.h:
(IDBBackingStore):
* Modules/indexeddb/IDBCallbacks.h:
(WebCore::IDBCallbacks::onBlocked):
(WebCore::IDBCallbacks::onUpgradeNeeded):
* Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
(IDBDatabaseBackendImpl::PendingOpenCall):
(IDBDatabaseBackendImpl::PendingOpenWithVersionCall):
(WebCore::IDBDatabaseBackendImpl::PendingOpenWithVersionCall::create):
(WebCore::IDBDatabaseBackendImpl::PendingOpenWithVersionCall::callbacks):
(WebCore::IDBDatabaseBackendImpl::PendingOpenWithVersionCall::version):
(WebCore::IDBDatabaseBackendImpl::PendingOpenWithVersionCall::PendingOpenWithVersionCall):
(WebCore):
(WebCore::IDBDatabaseBackendImpl::IDBDatabaseBackendImpl):
(WebCore::IDBDatabaseBackendImpl::openInternal):
(WebCore::IDBDatabaseBackendImpl::metadata):
(WebCore::IDBDatabaseBackendImpl::setVersion):
(WebCore::IDBDatabaseBackendImpl::setIntVersionInternal):
(WebCore::IDBDatabaseBackendImpl::transactionFinished):
(WebCore::IDBDatabaseBackendImpl::transactionFinishedAndEventsFired):
When an upgradeneeded event is fired in response to an
open-with-version call, the version change transaction must receive its
complete event before processPendingCalls fires a success event at
IDBOpenDBRequest. In the future this should probably be changed
instead to transactionFinishedAndAbortFired and
transactionFinishedAndCompleteFired so that we'll know to fire a
success or error event at IDBOpenDBRequest. Currently, instead of
firing error when there's an abort, we don't fire anything.

(WebCore::IDBDatabaseBackendImpl::processPendingCalls):
Now that this is called after a connection is opened, we unfortunately
lose the invariant that there is only one existing connection when this
is called, but nothing inside this function actually relied on that.
Additionally, the secondHalfOpen calls only ever need to be serviced
in one place: right after a version change transaction completes, so
it could be moved out of here.

(WebCore::IDBDatabaseBackendImpl::registerFrontendCallbacks):
Now that setVersion and deleteDatabase calls are queued up behind
secondHalfOpen calls, we have to service those queues when
secondHalfOpen calls complete, which is here.  So call
processPendingCalls().

(WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
(WebCore::IDBDatabaseBackendImpl::openConnectionWithVersion):
(WebCore::IDBDatabaseBackendImpl::deleteDatabase):
(WebCore::IDBDatabaseBackendImpl::close):
* Modules/indexeddb/IDBDatabaseBackendImpl.h:
(IDBDatabaseBackendImpl):
* Modules/indexeddb/IDBDatabaseCallbacks.h:
(WebCore::IDBDatabaseCallbacks::onVersionChange):
* Modules/indexeddb/IDBFactoryBackendImpl.cpp:
(WebCore::IDBFactoryBackendImpl::open):
This is refactored some so that the call to openConection{WithVersion}
happens once, at the end.

* Modules/indexeddb/IDBLevelDBBackingStore.cpp:
(WebCore::IDBLevelDBBackingStore::getIDBDatabaseMetaData):
(WebCore::IDBLevelDBBackingStore::createIDBDatabaseMetaData):
(WebCore::IDBLevelDBBackingStore::updateIDBDatabaseIntVersion):
(WebCore):
(WebCore::IDBLevelDBBackingStore::deleteDatabase):
* Modules/indexeddb/IDBLevelDBBackingStore.h:
(IDBLevelDBBackingStore):
* Modules/indexeddb/IDBTransactionBackendImpl.cpp:
(WebCore::IDBTransactionBackendImpl::commit):
See above comments about transactionFinishedAndEventsFired. I tried
moving the call to transactionFinished after the events were fired but
that failed some asserts. But changing those asserts is still an
alternative to splitting up transactionFinished as is done here.

Source/WebKit/chromium:

Update overridden methods to match new signatures.

* tests/IDBAbortOnCorruptTest.cpp:
(WebCore::FailingBackingStore::createIDBDatabaseMetaData):
* tests/IDBFakeBackingStore.h:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@124675 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Chrome-Android] - Prepare apk tests for switch to checked in SDK.
https://bugs.webkit.org/show_bug.cgi?id=92931

Patch by Yaron Friedman <yfriedman@chromium.org> on 2012-08-03
Reviewed by Adam Barth.

Source/WebKit/chromium:

Pass Android-specific gyp variables to the native test generator
avoiding any dependencies on environment variables during build time.

* WebKitUnitTests.gyp:

Tools:

Pass Android-specific gyp variables to the native test generator,
avoiding any dependencies on environment variables during build time.

* DumpRenderTree/DumpRenderTree.gyp/DumpRenderTree.gyp:
* TestWebKitAPI/TestWebKitAPI.gyp/TestWebKitAPI.gyp:

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