[V8] unsafeHandleToCurrentWorldContext doesn't need to exist
https://bugs.webkit.org/show_bug.cgi?id=96191

Reviewed by Kentaro Hara.

Previously, we used this function when instantiating DOM wrappers. Now
we get the context from the creationContext, so we don't need access to
this unsafe handle. This patch inlines the function into its one other
caller.

* bindings/v8/ScriptController.cpp:
(WebCore::ScriptController::currentWorldContext):
* bindings/v8/ScriptController.h:
(ScriptController):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127976 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[V8] V8DOMWindowShell does not need to be RefCounted
https://bugs.webkit.org/show_bug.cgi?id=96192

Reviewed by Kentaro Hara.

V8DOMWindowShell holds a raw Frame pointer, which would point to
unallocated memory if any object that wasn't owned by the frame took a
reference to a V8DOMWindowShell. Thankfully, the only object that takes
a reference to the V8DOMWindowShell is ScriptController, which is owned
by the Frame.

This patch stops V8DOMWindowShell from being RefCounted so that no
other objects are tempted to take a reference to it in the future.

* bindings/v8/ScriptController.h:
(ScriptController):
* bindings/v8/V8DOMWindowShell.cpp:
(WebCore::V8DOMWindowShell::create):
* bindings/v8/V8DOMWindowShell.h:
(V8DOMWindowShell):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127977 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[V8] V8PerContextData holds m_context using a v8::Handle rather than a v8::Persistent
https://bugs.webkit.org/show_bug.cgi?id=96193

Reviewed by Kentaro Hara.

There are two types of handles in V8: Local and Persistent. We are now
permitted to keep Local handles in the heap because they get
deallocated when the C++ stack unwinds and v8::HandleScope objects are
destructed.

V8PerContextData holds its m_context using the non-specific v8::Handle
type. If we used a Local handle here, we'd have a memory safety
problem. Thankfully, we use a Persistent handle, which need to be
allocated and freed manually.

This patch makes the type of V8PerContextData::m_context more specific
to ensure that we never try to store a local handle in this variable.
This patch should not have any behavior change because we were already
storing a Persistent handle.

* bindings/v8/V8PerContextData.h:
(WebCore::V8PerContextData::create):
(WebCore::V8PerContextData::V8PerContextData):
(V8PerContextData):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127978 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[V8] convertEventTargetToV8Object doesn't need to be overloaded
https://bugs.webkit.org/show_bug.cgi?id=96195

Reviewed by Kentaro Hara.

WTF::getPtr solves this problem for us.

* bindings/scripts/CodeGeneratorV8.pm:
(NativeToJSValue):
* bindings/v8/V8DOMWrapper.h:
(V8DOMWrapper):


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

Adding expectations for two crashing tests and two regressions.

* platform/gtk/TestExpectations:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127980 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[EFL] Fix build break when MEDIA_STREAM is enabled.
https://bugs.webkit.org/show_bug.cgi?id=96063

Unreviewed. Fix build break when MEDIA_STREAM is enabled.


* CMakeLists.txt:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127981 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[EFL] Unskip test cases passing reliably on the bots
https://bugs.webkit.org/show_bug.cgi?id=96204

Unreviewed EFL gardening.

Unskip test cases that are passing reliably on the
EFL build bots.

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-09-09

* platform/efl-wk1/TestExpectations:
* platform/efl-wk2/TestExpectations:
* platform/efl/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127982 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[WK2] Fix PLATFORM(WIN) vs. OS(WINDOWS) in various files
https://bugs.webkit.org/show_bug.cgi?id=96178

Patch by Simon Hausmann <simon.hausmann@nokia.com> on 2012-09-09
Reviewed by Kenneth Rohde Christiansen.

PLATFORM(WIN) is used in various places, where it is safe to use OS(WINDOWS) to allow
the re-use of that code path in ports beyond Safari/Windows.

* Platform/CoreIPC/BinarySemaphore.h:
(BinarySemaphore):
* Platform/CoreIPC/Connection.h:
(Connection):
* Platform/SharedMemory.h:
(Handle):
(SharedMemory):
* Platform/WorkQueue.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127983 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Fix flicker due to introduction of the fence extension.
https://bugs.webkit.org/show_bug.cgi?id=96207

Reviewed by George Staikos.

Don't immediately add fence to garbage list, so it is destroyed
after only one swap, for a set of tiles just because one tile in
the set gets a new fence, the old fence may still not be signalled
and before rendering the other tiles in the set we have to wait for it.

* WebKitSupport/BackingStoreTile.cpp:
(BlackBerry::WebKit::Fence::~Fence):
(WebKit):
* WebKitSupport/BackingStoreTile.h:
(WebKit):
(Fence):
* WebKitSupport/SurfacePool.cpp:
(BlackBerry::WebKit::SurfacePool::initialize):
(BlackBerry::WebKit::SurfacePool::notifyBuffersComposited):
(WebKit):
(BlackBerry::WebKit::SurfacePool::destroyPlatformSync):
* WebKitSupport/SurfacePool.h:
(SurfacePool):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127984 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[EFL][WK2] Gardening to make the bot green
https://bugs.webkit.org/show_bug.cgi?id=96208

Unreviewed EFL gardening.

Update TestExpectations to make the EFL WK2 bot green.

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-09-09

* platform/efl-wk2/TestExpectations:
* platform/efl-wk2/fast/events/mouseup-from-button2-expected.txt: Added. Test
needs baseline for wk2 (better output).

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127985 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Qt] Add missing files to the WebKit2 build on Windows
https://bugs.webkit.org/show_bug.cgi?id=96177

Reviewed by Kenneth Rohde Christiansen.

For the build on Windows we can re-use existing functionality from the Safari/Windows
build, such as the IPC implementation.

* Target.pri:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127986 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Rolled out <http://trac.webkit.org/changeset/127939> because it broke
fast/js/named-function-expression.html.

    Refactored bytecode generator initialization to support moving captured vars around
    https://bugs.webkit.org/show_bug.cgi?id=96159

    Reviewed by Gavin Barraclough.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127987 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[WK2] expose element rect for color input type
https://bugs.webkit.org/show_bug.cgi?id=91664

Reviewed by Simon Hausmann.

Source/WebKit2:

In the same way we do for select elements already. This allows placing the picker
in a sensible location.

* UIProcess/API/efl/PageClientImpl.cpp: Update the function's signature.
(WebKit::PageClientImpl::createColorChooserProxy): Ditto.
* UIProcess/API/efl/PageClientImpl.h: Ditto.
(PageClientImpl):
* UIProcess/API/gtk/PageClientImpl.cpp:
(WebKit::PageClientImpl::createColorChooserProxy): Ditto.
* UIProcess/API/gtk/PageClientImpl.h: Ditto.
(PageClientImpl):
* UIProcess/API/mac/PageClientImpl.h: Ditto.
(PageClientImpl):
* UIProcess/API/mac/PageClientImpl.mm:
(WebKit::PageClientImpl::createColorChooserProxy): Ditto.
* UIProcess/API/qt/raw/qrawwebview.cpp:
(QRawWebViewPrivate::createColorChooserProxy): Ditto.
* UIProcess/API/qt/raw/qrawwebview_p_p.h: Ditto.
(QRawWebViewPrivate):
* UIProcess/PageClient.h: Ditto.
(PageClient):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::showColorChooser): Compute the rect mapped to the current view's transform.
* UIProcess/WebPageProxy.h:
(WebPageProxy):
* UIProcess/WebPageProxy.messages.in:
* UIProcess/qt/QtPageClient.cpp:
(WebKit::QtPageClient::createColorChooserProxy):
* UIProcess/qt/QtPageClient.h:
(QtPageClient):
* UIProcess/qt/WebColorChooserProxyQt.cpp:
(ColorChooserContextObject):
(WebKit::ColorChooserContextObject::ColorChooserContextObject):
(WebKit::ColorChooserContextObject::elementRect):
(WebKit::ColorChooserContextObject::accept):
(WebKit::WebColorChooserProxyQt::WebColorChooserProxyQt):
* UIProcess/qt/WebColorChooserProxyQt.h:
(WebKit::WebColorChooserProxyQt::create):
(WebColorChooserProxyQt):
* UIProcess/win/WebView.cpp:
(WebKit::WebView::createColorChooserProxy): Update the function's signature.
* UIProcess/win/WebView.h:
(WebView): Ditto.
* WebProcess/WebCoreSupport/WebColorChooser.cpp:
(WebKit::WebColorChooser::WebColorChooser):

Tools:

Update the QML logic in MiniBrowser to take advantage of this.
The picker size is now hardcoded and we try to place it below the
input element if possible.

* MiniBrowser/qt/qml/ColorChooser.qml:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127988 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[EFL] Mark fast/innerHTML/innerHTML-iframe.html as flaky
https://bugs.webkit.org/show_bug.cgi?id=96209

Unreviewed EFL gardening.

Mark fast/innerHTML/innerHTML-iframe.html as flaky for
both WK1 and WK2 EFL.

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-09-09

* platform/efl-wk2/TestExpectations:
* platform/efl/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127989 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[EFL][WK2] Mark sputnik/Conformance/07_Lexical_Conventions/7.4_Comments/S7.4_A5.html as flaky
https://bugs.webkit.org/show_bug.cgi?id=96210

Unreviewed EFL gardening.

Mark additional sputnik test as flaky on WK2 EFL build bot.

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-09-09

* platform/efl-wk2/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127990 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Make the String initialization on the function side of String::number()
https://bugs.webkit.org/show_bug.cgi?id=95940

Reviewed by Benjamin Poulain.

Source/JavaScriptCore:

* JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:

Source/WebKit2:

* win/WebKit2.def:
* win/WebKit2CFLite.def:

Source/WTF:

Un-Inline String::number() to make the String initialization done on the function side
instead of being on the caller side.

* GNUmakefile.list.am:
* WTF.gypi:
* WTF.pro:
* WTF.vcproj/WTF.vcproj:
* WTF.xcodeproj/project.pbxproj:
* wtf/CMakeLists.txt:
* wtf/text/IntegerToStringConversion.cpp: Removed.
* wtf/text/IntegerToStringConversion.h:
(WTF::numberToStringImpl):
(WTF::numberToStringSigned):
(WTF::numberToStringUnsigned):
* wtf/text/WTFString.cpp:
(WTF::String::number):
* wtf/text/WTFString.h:

Tools:

* TestWebKitAPI/Tests/WTF/IntegerToStringConversion.cpp:
(testBoundaries):
(testNumbers):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127991 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed, rolling out r127963.
http://trac.webkit.org/changeset/127963
https://bugs.webkit.org/show_bug.cgi?id=96173

Inappropriately modified test, and not just expectations,
without review. Will land changes to expectations only, and then
upload a patch to modify the test for review.

* accessibility/transformed-element-expected.txt:
* platform/mac/accessibility/image-map2-expected.txt:
* platform/mac/accessibility/internal-link-anchors2-expected.txt:
* platform/mac/accessibility/table-detection-expected.txt:
* platform/mac/accessibility/table-one-cell-expected.txt:
* platform/mac/accessibility/update-children-when-aria-role-changes.html:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127992 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed.\n\nRebaselining 5 mac accessibility tests, skipping one.\n\nhttps://bugs.webkit.org/show_bug.cgi?id=96173

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127993 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Use WebCompositorSupport creation functions in GraphicsLayerChromiumTest
https://bugs.webkit.org/show_bug.cgi?id=96212

Reviewed by Adrienne Walker.

The static ::create()s the test references currently are going away soon.

* tests/GraphicsLayerChromiumTest.cpp:
(WebKit::GraphicsLayerChromiumTest::GraphicsLayerChromiumTest):
(WebKit::TEST_F):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127994 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] webkit_platform should only be linked into the webkit target
https://bugs.webkit.org/show_bug.cgi?id=96213

Reviewed by Adrienne Walker.

The Platform.gyp:webkit_platform target provides the implementation of several WEBKIT_EXPORTed symbols. It only
makes sense as a target of WebKit.gyp:webkit, other targets shouldn't directly depend on it.

Source/WebCore:

* WebCore.gyp/WebCore.gyp:

Source/WebKit/chromium:

* WebKit.gyp:

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