StringImpl created from literal should be BufferInternal
https://bugs.webkit.org/show_bug.cgi?id=92940

Reviewed by Anders Carlsson.

Source/WTF: 

The ownership of string created from literal should be BufferInternal so that
StringImpl never tries to delete the characters.

The ownership was accidentaly set to BufferOwned in r123689.

* wtf/text/StringImpl.cpp:
(WTF::StringImpl::createFromLiteral): Update to use the new constructor.
* wtf/text/StringImpl.h:
(WTF::StringImpl::StringImpl):
Add a new constructor making the construction from literal explicit.
Add the flag s_hashFlagHasTerminatingNullCharacter since the data has the terminating
null character.

Tools: 

Add tests for the contruction of strings from literal.

* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/WTF/AtomicString.cpp: Added.
(TestWebKitAPI):
(TestWebKitAPI::TEST):
* TestWebKitAPI/Tests/WTF/StringImpl.cpp: Added.
(TestWebKitAPI):
(TestWebKitAPI::TEST):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@124611 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium mac] DumpRenderTree compile fails with warning/error in LayoutTestHelper.mm with 10.7sdk
https://bugs.webkit.org/show_bug.cgi?id=92820

Reviewed by Jochen Eisinger.

When building with the 10.7 SDK, use newer functions to switch color
profiles. Note that these newer functions aren't available on 10.6,
but we don't intend to ship DRT to users, and no bots that currently
build with the 10.7 SDK ship their binaries to 10.6 testers.

The new code was copied from Apple's DRT/mac/LayoutTestHelper.m.

* DumpRenderTree/chromium/LayoutTestHelper.mm:
(installLayoutTestColorProfile):
(restoreUserColorProfile):
(saveCurrentColorProfile):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@124612 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed build fix for GTK after r124479.

.:

* Source/autotools/symbols.filter: Removed unneeded symbol.

Source/WebKit2:

* UIProcess/WebInspectorProxy.cpp:
(WebKit): Moved static const definitions from header file.
* UIProcess/WebInspectorProxy.h:
(WebInspectorProxy): Don't give values to static const members
here.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@124613 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK][jhbuild] Switch to GStreamer 0.11 build
https://bugs.webkit.org/show_bug.cgi?id=91727

Reviewed by Gustavo Noronha Silva.

Source/WebCore:

Add a new function to encapsulate the GStreamer API removal of
GST_OBJECT_IS_FLOATING in the upcoming 1.0 release. Use of this
macro can now be replaced by calling the g_object_is_floating
function.

* platform/graphics/gstreamer/GRefPtrGStreamer.cpp:
(WTF::adoptGRef):
* platform/graphics/gstreamer/GStreamerVersioning.cpp:
(gstObjectIsFloating):
* platform/graphics/gstreamer/GStreamerVersioning.h:

Tools:

Switch build-webkit --gtk to GStreamer 0.11 support and build the
necessary GStreamer git modules from JHBuild.

* Scripts/webkitdirs.pm:
(buildAutotoolsProject): Build WebKit with GStreamer 0.11 support.
* gtk/jhbuild.modules: GStreamer build support.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@124614 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Overlays display checkerboard that doesn't resolve
https://bugs.webkit.org/show_bug.cgi?id=93099

Patch by Arvid Nilsson <anilsson@rim.com> on 2012-08-03
Reviewed by Antonio Gomes.

The WebKit-thread overlays, like tap highlight, inspector highlight and
selection are all part of a separate graphics layer tree rooted in
WebPagePrivate::m_overlayLayer.

When LayerRenderer needs to schedule a commit to reactively render
tiles and resolve checkerboard, it does so through the root layer.
Since the overlay layer root didn't have a GraphicsLayerClient, there
was no implementation of GraphicsLayerClient::notifySyncRequired() to
call, and a commit was never scheduled, thus checkerboard never
resolved.

Fixed by adding a fallback implementation of GraphicsLayerClient in
WebPagePrivate and hooking up the overlay root to it. Also, this
implementation can be shared by the various overlays to avoide code
duplication, specifically to implement notifySyncRequired(),
showDebugBorders() and showRepaintCounter() only once.

Fixing this revealed a bug where the web page would get stuck in an
endless sequence of commits. It turned out that
WebPagePrivate::updateDelegatedOverlays() was called right in the
middle of the commit operation, after performing the webkit thread part
of the commit operation but before we continued on the compositing
thread. Since updateDelegatedOverlays() typically mutates layers, this
is very bad (layers should not be mutated mid-commit). The mutations
also cause a new commit to scheduled from within the current, which
results in an endless sequence of commits.

Fixed this latter bug by moving the updateDelegatedOverlays() call to
the beginning of the method where it can cause no harm. This is before
we mark the web page as no longer needing commit, so even if the
implementation flips the "needs commit" bit, we will immediately flip
it back and proceed with commit as usual.

PR 187458, 184377

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::overlayLayer):
(BlackBerry::WebKit::WebPagePrivate::commitRootLayerIfNeeded):
(WebKit):
(BlackBerry::WebKit::WebPagePrivate::notifySyncRequired):
(BlackBerry::WebKit::WebPagePrivate::showDebugBorders):
(BlackBerry::WebKit::WebPagePrivate::showRepaintCounter):
* Api/WebPage_p.h:
(WebPagePrivate):
(BlackBerry::WebKit::WebPagePrivate::notifyAnimationStarted):
(BlackBerry::WebKit::WebPagePrivate::paintContents):
* WebCoreSupport/InspectorOverlay.cpp:
(WebCore::InspectorOverlay::notifySyncRequired):
(WebCore::InspectorOverlay::showDebugBorders):
(WebCore::InspectorOverlay::showRepaintCounter):
* WebKitSupport/DefaultTapHighlight.cpp:
(BlackBerry::WebKit::DefaultTapHighlight::notifySyncRequired):
(BlackBerry::WebKit::DefaultTapHighlight::showDebugBorders):
(WebKit):
(BlackBerry::WebKit::DefaultTapHighlight::showRepaintCounter):
* WebKitSupport/DefaultTapHighlight.h:
(DefaultTapHighlight):
* WebKitSupport/SelectionOverlay.cpp:
(BlackBerry::WebKit::SelectionOverlay::notifySyncRequired):
(BlackBerry::WebKit::SelectionOverlay::showDebugBorders):
(WebKit):
(BlackBerry::WebKit::SelectionOverlay::showRepaintCounter):
* WebKitSupport/SelectionOverlay.h:
(SelectionOverlay):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@124615 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Initialize the Event Names' string from read only memory
https://bugs.webkit.org/show_bug.cgi?id=92435

Patch by Benjamin Poulain <bpoulain@apple.com> on 2012-08-03
Reviewed by Anders Carlsson.

Similarily to r123689, we can initialize the event names' string from memory without copying the data.
This saves us memory and initialization time.

* dom/EventNames.cpp:
(WebCore):


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