WebKit-https.git
7 years ago[Chromium] Implement the find-in-page match rects API
leandrogracia@chromium.org [Sun, 12 Aug 2012 18:05:19 +0000 (18:05 +0000)]
[Chromium] Implement the find-in-page match rects API
https://bugs.webkit.org/show_bug.cgi?id=93111

Reviewed by Adam Barth.

Source/WebCore:

Introduce the find-in-page coordinate system. This system tries to solve
the unintuitive tickmark results presented in pages with multiple frames
and scrolled contents where the find results might not be in the visible
area of a frame, which might lead to tickmarks below the container frame.

To achieve this, this coordinate system goes up the render tree
normalizing the coordinates by the actual contents size of its container.
This leads to tickmarks scaled to the visible size of their frame
independently of its scroll. This coordinate system supports also CSS
scroll:overflow, transforms and the different positions.

Also add an auxiliary method to Range in order to provide a transform
friendly way to retrieve the absolute coordinates of the enclosing
bounding box without the adjustment operations that the existing
enclosingRect method does.

Tested by WebFrameTest WebKit unit test.

* dom/Range.cpp:
(WebCore::Range::transformFriendlyBoundingBox): add a transform-friendly equivalent of boundingBox.
(WebCore):
* dom/Range.h: move boundingBox to the group of non-transform-friendly methods.
(Range):

Source/WebKit/chromium:

Implement the funcionality of the find-in-page match rects API in WebFrame.
These methods keep a cache of the match rects in a special coordinate system
(find-in-page coordinates) and update them on size changes. They also allow
to recover the match closest to a given point, therefore enabling to move
to find matches when tapping on their corresponding tickmarks.

* WebKit.gyp: add FindInPageCoordinates.h / cpp.
* src/ChromeClientImpl.cpp:
(WebKit::ChromeClientImpl::contentsSizeChanged): propagate didChangeContentsSize to WebFrameImpl.
* src/FindInPageCoordinates.cpp: Added.
(WebKit):
(WebKit::toNormalizedRect): auxiliary internal function.
(WebKit::findInPageRectFromAbsoluteRect): main coordinate conversion function.
(WebKit::findInPageRectFromRange): convenience conversion function for Ranges.
* src/FindInPageCoordinates.h: Added.
(WebCore):
(WebKit):
* src/WebFrameImpl.cpp:
(WebKit::WebFrameImpl::FindMatch::FindMatch): find matches cache constructor.
(WebKit):
(WebKit::WebFrameImpl::find): clear match cache when appropriate and zoom into results on the Android port.
(WebKit::WebFrameImpl::stopFinding): clear matches cache.
(WebKit::WebFrameImpl::scopeStringMatches): add new results to the matches cache.
(WebKit::WebFrameImpl::increaseMatchCount): update the matches cache version.
(WebKit::WebFrameImpl::resetMatchCount): update the matches cache version.
(WebKit::WebFrameImpl::findMatchMarkersVersion): new API providing the matches cache version.
(WebKit::WebFrameImpl::clearFindMatchesCache): internal utility method to reset the matches cache.
(WebKit::WebFrameImpl::isActiveMatchFrameValid): internal utility method to check if the local frame is still in the frame tree.
(WebKit::WebFrameImpl::updateFindMatchRects): internal utility method to update the match result rects if required.
(WebKit::WebFrameImpl::activeFindMatchRect): new API providing the active find match rect in find-in-page coordinates.
(WebKit::WebFrameImpl::findMatchRects): new API returning the valid match rects in find-in-page coordinates.
(WebKit::WebFrameImpl::appendFindMatchRects): internal utility method to concatenate the match results of multiple frames.
(WebKit::WebFrameImpl::selectNearestFindMatch): new API selecting the find match closer to a point in find-in-page coordinates.
(WebKit::WebFrameImpl::nearestFindMatch): internal utility method to find the nearest find match to a point in a frame.
(WebKit::WebFrameImpl::selectFindMatch): internal utility method to select a match in the cache.
(WebKit::WebFrameImpl::WebFrameImpl): initialization of new variables.
(WebKit::WebFrameImpl::didChangeContentsSize): invalidate the cached match rect coordinates on frame content size changes.
* src/WebFrameImpl.h:
(WebCore):
(WebFrameImpl):
(WebKit::WebFrameImpl::activeMatchFrame): remove unrequired const.
(WebKit::WebFrameImpl::activeMatch): expose the range of the active match to allow testing.
(FindMatch): cache structure for find matches.
* tests/WebFrameTest.cpp: new test case for find-in-page match rects.
* tests/data/find_in_page.html: Added. Test case layout.
* tests/data/find_in_page_frame.html: Added. Test case layout.

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

7 years agoStop Y-flipping CROS/ARM video textures
fischman@chromium.org [Sun, 12 Aug 2012 17:40:25 +0000 (17:40 +0000)]
Stop Y-flipping CROS/ARM video textures
https://bugs.webkit.org/show_bug.cgi?id=93769

Reviewed by Eric Seidel.

No new tests; there's no cros/arm bot yet, sadly.

* platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
(WebCore::CCVideoLayerImpl::appendQuads): drop the single-platform Y-flipping in prep for the platform doing the flip natively.

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

7 years ago[Qt] Make it possible to build without QtTest/QtPrintSupport
commit-queue@webkit.org [Sun, 12 Aug 2012 16:52:54 +0000 (16:52 +0000)]
[Qt] Make it possible to build without QtTest/QtPrintSupport
https://bugs.webkit.org/show_bug.cgi?id=93492

Patch by Loïc Yhuel <loic.yhuel@softathome.com> on 2012-08-12
Reviewed by Tor Arne Vestbø.

.:

* Source/QtWebKit.pro: Disable tests if no testlib

Source/WebKit:

* WebKit1.pri: Optional printsupport

Source/WebKit/qt:

* Api/qwebframe.cpp:
(QWebFrame::print): Does nothing if no printsupport
* Api/qwebview.cpp:
(QWebView::print): Does nothing if no printsupport

Tools:

* DumpRenderTree/qt/DumpRenderTree.pro: Optional printsupport
* DumpRenderTree/qt/DumpRenderTreeQt.cpp:
(WebCore):
(WebCore::DumpRenderTree::dryRunPrint): Does nothing if no printsupport
* QtTestBrowser/QtTestBrowser.pro: Optional printsupport
* QtTestBrowser/launcherwindow.cpp:
(LauncherWindow::createChrome): No print menu if no printsupport
(LauncherWindow::print): Does nothing if no printsupport
* QtTestBrowser/launcherwindow.h:
* Tools.pro: Disable DRT/WTR if QtTest not present
* qmake/mkspecs/features/default_pre.prf: printsupport no more mandatory
* qmake/mkspecs/features/features.prf: Qt module availability tests

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

7 years agoCSSRegions: Crash when using style in region for removed element.
mihnea@adobe.com [Sun, 12 Aug 2012 15:57:25 +0000 (15:57 +0000)]
CSSRegions: Crash when using style in region for removed element.
https://bugs.webkit.org/show_bug.cgi?id=93276

Reviewed by Abhishek Arya.

Source/WebCore:

When a RenderInline object from within a render flow thread is split, the cloned
hierarchy built during the split process does not have the inRenderFlowThread bit
set properly. If the cloned hierarchy is flowed into a region with region style rules,
we compute the style in region also for objects that do not have inRenderFlowThread bit
set and we store the computed style in region for caching purposes. But we only remove
an object style in region information if that object has the inRenderFlowThread bit set.
Under these circumstances, it is possible to remove a object with cached style in region
and without inRenderFlowThread bit set from the render tree and leave the associated cached
information un-removed. Such information will be accesses during the next paint phase of
the region, thus resulting a crash.

The fix is to modify RenderBlock::clone() and RenderInline::clone() functions to also copy the inRenderFlowThread bit
from the source into the clone, therefore the cloned hierarchies will have the inRenderFlowThread
bit set properly.

Test: fast/regions/removed-element-style-in-region-crash.html

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::clone):
* rendering/RenderInline.cpp:
(WebCore::RenderInline::clone): Replace former static RenderInline::cloneInline with member RenderInline::clone.
(WebCore::RenderInline::splitInlines):
* rendering/RenderInline.h:
(RenderInline):
* rendering/RenderRegion.cpp:
(WebCore::RenderRegion::setObjectStyleInRegion):
Added an assert to make sure that when we are computing style in region, we are doing for objects
with inRenderFlowThread set. Also, bail out early in this case to prevent further crashes.

LayoutTests:

Added test reproducing the problem.

* fast/regions/removed-element-style-in-region-crash-expected.txt: Added.
* fast/regions/removed-element-style-in-region-crash.html: Added.

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

7 years ago[EFL][WK2] Skip webintents/web-intents-obj-constructor.html test
commit-queue@webkit.org [Sun, 12 Aug 2012 15:46:42 +0000 (15:46 +0000)]
[EFL][WK2] Skip webintents/web-intents-obj-constructor.html test
https://bugs.webkit.org/show_bug.cgi?id=93778

Unreviewed EFL gardening.

Skip webintents/web-intents-obj-constructor.html for
WebKit2 EFL until WTR can print information about the
MessagePorts in a Web Intent (Bug 89072).

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

* platform/efl-wk2/Skipped:

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

7 years agoSet the access qualifier of two methods to query frame specific info of BitmapImage...
commit-queue@webkit.org [Sun, 12 Aug 2012 12:12:56 +0000 (12:12 +0000)]
Set the access qualifier of two methods to query frame specific info of BitmapImage to protected.
https://bugs.webkit.org/show_bug.cgi?id=90505

Patch by Huang Dongsung <luxtella@company100.net> on 2012-08-12
Reviewed by Eric Seidel.

Following 4 methods are protected.
  size_t frameCount();
  NativeImagePtr frameAtIndex(size_t);
  bool frameIsCompleteAtIndex(size_t);
  float frameDurationAtIndex(size_t);

So, 2 methds also should be protected because the frame info is only specific of
BitmapImage.
  bool frameHasAlphaAtIndex(size_t);
  ImageOrientation frameOrientationAtIndex(size_t);

On the other hand, this patch amended GraphicsContext3DCG.
- static_cast<BitmapImage*>(image)->frameHasAlphaAtIndex(0)
+ image->currentFrameHasAlpha()

This patch does not affect PNG, JPEG, BMP, and WEBP because those images
have only 0 indexed frame.
Thus, GIF, and ICO are affected. However, an above query to get Alpha
is for the image that is created by image->nativeImageForCurrentFrame(), so it
is proper to use image->currentFrameHasAlpha() instead of
image->frameHasAlphaAtIndex(0).

No new tests, because it is hard to test. We need an animated GIF that
one frame has alpha and another frame does not have alpha. However, I
cannot find the animated GIF file that suffices the requirement.

* platform/graphics/BitmapImage.h:
(BitmapImage):
* platform/graphics/cg/GraphicsContext3DCG.cpp:
(WebCore::GraphicsContext3D::getImageData):

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

7 years agoDoesn't build with ENABLE_JIT=0
allan.jensen@nokia.com [Sun, 12 Aug 2012 11:47:34 +0000 (11:47 +0000)]
Doesn't build with ENABLE_JIT=0
https://bugs.webkit.org/show_bug.cgi?id=85042

Reviewed by Eric Seidel.

Include headers without which CallFrame.h does not build, and
fix gcc warning about comparing unsigned int with 0.

* dfg/DFGDriver.cpp:
* interpreter/Interpreter.cpp:
(JSC::Interpreter::isOpcode):

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

7 years agomaster.cfg unittest cleanup: Show DeprecationWarnings with python >= 2.7 too
ossy@webkit.org [Sun, 12 Aug 2012 11:38:12 +0000 (11:38 +0000)]
cfg unittest cleanup: Show DeprecationWarnings with python >= 2.7 too
https://bugs.webkit.org/show_bug.cgi?id=90161

Reviewed by Eric Seidel.

* BuildSlaveSupport/build.webkit.org-config/mastercfg_unittest.py:

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

7 years agowebkit fails IETC namespaces/prefix-007.xml
commit-queue@webkit.org [Sun, 12 Aug 2012 11:38:09 +0000 (11:38 +0000)]
webkit fails IETC namespaces/prefix-007.xml
https://bugs.webkit.org/show_bug.cgi?id=86137

Patch by Takashi Sakamoto <tasak@google.com> on 2012-08-12
Reviewed by Eric Seidel.

Source/WebCore:

If a namespace prefix or default namespace is declared more than once
only the last declaration shall be used.

parseAddNamespace doesn't check return value of WTF::HashMap<>::add.
If the return value's isNewEntry is true, the new entry is added with
the specified value. However, if isNewEntry is false, it is required
to update the store value.

No new tests. ietestcenter/css3/namespaces/prefix-007.xml and
ietestcenter/css3/namespaces/prefix-010.xml covers this change.

* css/StyleSheetContents.cpp:
(WebCore::StyleSheetContents::parserAddNamespace):
Modified to check m_namespaces.add's return value.
If the result says not a new entry, updated the value stored in
m_namespaces by using iterator in the result.

LayoutTests:

* platform/chromium/TestExpectations:
Enabled the layout tests, ietestcenter/css3/namespaces/prefix-007.xml
and ietestcenter/css3/namespaces/prefix-010.xml.
* platform/win/ietestcenter/css3/namespaces/prefix-007-expected.txt: Removed.
* platform/win/ietestcenter/css3/namespaces/prefix-010-expected.txt: Removed.
Removed old expectations.

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

7 years agoFix build with recent clang.
commit-queue@webkit.org [Sun, 12 Aug 2012 11:29:29 +0000 (11:29 +0000)]
Fix build with recent clang.
https://bugs.webkit.org/show_bug.cgi?id=90701

Patch by Nuno Lopes <nlopes@apple.com> on 2012-08-12
Reviewed by Eric Seidel.

* Shared/CommandLine.h:
(CommandLine):
* WebProcess/Notifications/NotificationPermissionRequestManager.cpp:
(WebKit::NotificationPermissionRequestManager::NotificationPermissionRequestManager):
* WebProcess/Notifications/NotificationPermissionRequestManager.h:
(NotificationPermissionRequestManager):

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

7 years ago[EFL][UT] Delete shutdown method.
commit-queue@webkit.org [Sun, 12 Aug 2012 11:26:04 +0000 (11:26 +0000)]
[EFL][UT] Delete shutdown method.
https://bugs.webkit.org/show_bug.cgi?id=90785

Patch by Krzysztof Czech <k.czech@samsung.com> on 2012-08-12
Reviewed by Eric Seidel.

EWKTestBase class already has a shutdownAll method that can be used instead of shutdown.

* tests/UnitTestUtils/EWKTestBase.cpp:
* tests/UnitTestUtils/EWKTestBase.h:
(EWKTestBase):

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

7 years agoMove CSS's propertyNameStrings[] to from the header to the cpp file
benjamin@webkit.org [Sun, 12 Aug 2012 10:39:20 +0000 (10:39 +0000)]
Move CSS's propertyNameStrings[] to from the header to the cpp file
https://bugs.webkit.org/show_bug.cgi?id=93771

Reviewed by Eric Seidel.

The names of propertyNameStrings[] should never be accessed directly. The function getPropertyName()
return the correct string of propertyNameStrings.

To ensure the values are not accessed by mistake, move them from the header to the implementation.

* css/makeprop.pl:

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

7 years agoCSSComputedStyleDeclaration::cssText() should use StringBuilder
benjamin@webkit.org [Sun, 12 Aug 2012 10:37:15 +0000 (10:37 +0000)]
CSSComputedStyleDeclaration::cssText() should use StringBuilder
https://bugs.webkit.org/show_bug.cgi?id=93776

Reviewed by Eric Seidel.

String::append() is fairly inefficient when used to create a long string by appending a lot of small
pieces. StringBuilder is more approriate for the kind of operations done by CSSComputedStyleDeclaration::cssText().

This changes makes CSSComputedStyleDeclaration::cssText() about 6 times faster.

* css/CSSComputedStyleDeclaration.cpp:
(WebCore::CSSComputedStyleDeclaration::cssText):

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

7 years ago[Qt] Unreviewed trivial build fix: Newer Qt versions don't implicitly include qwindow...
hausmann@webkit.org [Sun, 12 Aug 2012 07:18:47 +0000 (07:18 +0000)]
[Qt] Unreviewed trivial build fix: Newer Qt versions don't implicitly include qwindowsysteminterface.h
through the QTestLib headers anymore.

* DumpRenderTree/qt/EventSenderQt.cpp:
* WebKitTestRunner/Target.pri:
* WebKitTestRunner/qt/EventSenderProxyQt.cpp:

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

7 years agoFix the build.
weinig@apple.com [Sun, 12 Aug 2012 06:10:31 +0000 (06:10 +0000)]
Fix the build.

* Platform/CoreIPC/Connection.h:
Add missing include.

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

7 years ago[WK2] Get rid of ProcessModelSharedSecondaryThread
weinig@apple.com [Sun, 12 Aug 2012 06:09:16 +0000 (06:09 +0000)]
[WK2] Get rid of ProcessModelSharedSecondaryThread
https://bugs.webkit.org/show_bug.cgi?id=93652

Reviewed by Dan Bernstein.

The threaded model for WebKit2 has been broken a long time and its continued existence in
the code only serves to confuse. It's time to say good bye to it.

* UIProcess/API/C/WKContext.cpp:
* UIProcess/API/C/WKContextPrivate.h:
Remove WKContextGetSharedThreadContext().

* UIProcess/ProcessModel.h:
Remove ProcessModelSharedSecondaryThread from the ProcessModel enum.

* UIProcess/WebContext.cpp:
* UIProcess/WebContext.h:
Remove WebContext::sharedThreadContext().

* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::~WebProcessProxy):
(WebKit::WebProcessProxy::connect):
(WebKit::WebProcessProxy::isLaunching):
* UIProcess/WebProcessProxy.h:
Remove the ThreadLauncher member and stop deriving from ThreadLauncher::Client.

* UIProcess/Launcher/ThreadLauncher.cpp: Removed.
* UIProcess/Launcher/ThreadLauncher.h: Removed.
* UIProcess/Launcher/efl/ThreadLauncherEfl.cpp: Removed.
* UIProcess/Launcher/gtk/ThreadLauncherGtk.cpp: Removed.
* UIProcess/Launcher/mac/ThreadLauncherMac.mm: Removed.
* UIProcess/Launcher/qt/ThreadLauncherQt.cpp: Removed.
* UIProcess/Launcher/win/ThreadLauncherWin.cpp: Removed.
* WebKit2.xcodeproj/project.pbxproj:
* win/WebKit2.vcproj:
* CMakeLists.txt:
* GNUmakefile.list.am:
* PlatformEfl.cmake:
* Target.pri:
Remove ThreadLauncher files.

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

7 years agoRemove ability to run MiniBrowser in threaded mode, it hasn't worked for a long time
weinig@apple.com [Sun, 12 Aug 2012 05:56:33 +0000 (05:56 +0000)]
Remove ability to run MiniBrowser in threaded mode, it hasn't worked for a long time
https://bugs.webkit.org/show_bug.cgi?id=93774

Reviewed by Dan Bernstein.

Remove support for opening windows using the shared thread WKContextRef. WKContextGetSharedThreadContext()
is going away, due to not working for a long time, and the first step is removing all the callers.

While here, remove the BrowserStatisticsWindow, which was not providing interesting information.

* MiniBrowser/MiniBrowser.xcodeproj/project.pbxproj:
* MiniBrowser/mac/AppDelegate.h:
* MiniBrowser/mac/AppDelegate.m:
(-[BrowserAppDelegate init]):
(-[BrowserAppDelegate newWindow:]):
(-[BrowserAppDelegate openPanelDidEnd:returnCode:contextInfo:]):
* MiniBrowser/mac/BrowserStatisticsWindow.xib: Removed.
* MiniBrowser/mac/BrowserStatisticsWindowController.h: Removed.
* MiniBrowser/mac/BrowserStatisticsWindowController.m: Removed.
* MiniBrowser/mac/MainMenu.xib:
* MiniBrowser/win/BrowserView.cpp:
(BrowserView::create):

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

7 years agoEnable XPC Service based WebProcess with runtime flag
weinig@apple.com [Sun, 12 Aug 2012 05:29:41 +0000 (05:29 +0000)]
Enable XPC Service based WebProcess with runtime flag
https://bugs.webkit.org/show_bug.cgi?id=93773

Reviewed by Dan Bernstein.

Source/WebKit2:

Use the XPC Service for WebProcess code path if WEBKIT_USE_XPC_SERVICE_FOR_WEB_PROCESS
is set in the environment.

* UIProcess/Launcher/mac/ProcessLauncherMac.mm:
(WebKit::launchXPCService):
Fix issue that was causing this code not to compile. This was not caught before since
the code was not being built.

* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::connect):
Switch from hard coding always using the XPC Service code path if
HAVE(XPC) was true, to doing it conditionally on an environment variable.

Source/WTF:

* wtf/Platform.h:
Define HAVE_XPC on 10.7 and later.

Tools:

Convert --use-web-process-xpc-service passed to run-safari (and similar scripts)
to setting WEBKIT_USE_XPC_SERVICE_FOR_WEB_PROCESS=YES in the environment and setting
up __XPC_DYLD_FRAMEWORK_PATH and __XPC_DYLD_INSERT_LIBRARIES variables. NOTE: using
the XPC service is not the default code path.

* Scripts/webkitdirs.pm:
(shouldUseXPCServiceForWebProcess):
(determineShouldUseXPCServiceForWebProcess):
Add functions to extract --use-web-process-xpc-service from ARGV and set a
global variable.

(printHelpAndExitForRunAndDebugWebKitAppIfNeeded):
Add help text for --use-web-process-xpc-service.

(runMacWebKitApp):
Set the WEBKIT_USE_XPC_SERVICE_FOR_WEB_PROCESS environment variable and DYLD
if --use-web-process-xpc-service was passed on the command line.

(execMacWebKitAppForDebugging):
Set the WEBKIT_USE_XPC_SERVICE_FOR_WEB_PROCESS environment variable and DYLD
if --use-web-process-xpc-service was passed on the command line. Also, bail
if both --use-web-process-xpc-service and --target-web-process are passed on
the command line, as we don't currently support using both.

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

7 years agoMake it possible to run the WebProcess as an XPC service
weinig@apple.com [Sun, 12 Aug 2012 00:00:40 +0000 (00:00 +0000)]
Make it possible to run the WebProcess as an XPC service
https://bugs.webkit.org/show_bug.cgi?id=92814

Reviewed by Anders Carlsson.

In this initial implementation, we are only using the XPC service
to launch the WebProcess, and then using the xpc_connection to send
over a mach_port to the WebProcess which is then used for creating
the CoreIPC connection.  In the future, we will switch to using the
xpc_connection for all messaging.

When the XPC service is enabled (it is compiled out by default for now), both
the XPC service and the old spawned process are runtime choosable.  This allows
the connect to pre-existing process workflow to continue to work.

There are a few additional caveats of this initial implementation:
    - It is only set up for the WebProcess (not for the PluginProcess)
    - The WebProcess shim does not work.
    - It requires a new environment variable to be set when launching
      to find the right service to launch (__XPC_DYLD_FRAMEWORK_PATH).

* Configurations/WebKit2Service.xcconfig: Added.
Add new configuration file for the service.

* Platform/CoreIPC/Connection.h:
(CoreIPC::Connection::Identifier::Identifier):
(CoreIPC::Connection::identifierIsNull):
Added to encapsulate the concept of a null identifier, now that it
is not possible to just compare to null.

* Platform/CoreIPC/mac/ConnectionMac.cpp:
(CoreIPC::Connection::platformInvalidate):
(CoreIPC::Connection::platformInitialize):
Change Connection::Identifier on the Mac to be a struct instead of
a typedef to a mach_port. This allows for the Connection to get both
the listening port and a reference to the xpc_connection (if it
compiled in). For now, all we do is retain the xpc_connection when it
is given to us, and release on Connection invalidation.

* PluginProcess/PluginProcess.cpp:
(WebKit::PluginProcess::createWebProcessConnection):
* PluginProcess/mac/PluginProcessMainMac.mm:
(WebKit::PluginProcessMain):
* WebProcess/Plugins/PluginProcessConnectionManager.cpp:
(WebKit::PluginProcessConnectionManager::getPluginProcessConnection):
Use the Connection::Identifier constructor.

* UIProcess/Launcher/ProcessLauncher.h:
(LaunchOptions):
Add a UseXPC option to the LaunchOptions so we can dynamically choose whether to use it.

(ProcessLauncher):
Make processTypeAsString public to allow better factoring in the implementation file
using static functions.

* UIProcess/Launcher/mac/ProcessLauncherMac.mm:
Factor out the different launching options into helper functions. Always start by
trying to connect to a pre-existing process.

(WebKit::launchXPCService):
Create a new xpc_connection to our service, and give it a unique instance UUID.
Then, send a bootstrap message with a mach_port and wait for a reply to complete
the launch procedure.

(WebKit::tryPreexistingProcess):
Move the code to connect to a preexisting process to its own helper function.

(WebKit::ProcessLauncher::launchProcess):
Clean up a bit, calling the helper functions and adding call to launch the XPC service
if it is enabled.

* UIProcess/Launcher/mac/ThreadLauncherMac.mm:
(WebKit::webThreadBody):
(WebKit::ThreadLauncher::createWebThread):
Switch to using the constructor version of Identifier.

* UIProcess/Plugins/PluginProcessProxy.cpp:
(WebKit::PluginProcessProxy::PluginProcessProxy):
Don't try to use the XPC service for plugins yet.

(WebKit::PluginProcessProxy::didFinishLaunching):
Use Connection::identifierIsNull instead of explicit null check.

* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::connect):
If XPC is compiled in (it currently is not) enable it by default.

* WebKit2.xcodeproj/project.pbxproj:
Add the new files and targets.

* WebKit2Service: Added.
* WebKit2Service/Info.plist: Added.
Add the paper work needed for an XPC service. Importantly, set up the XPC
service to be an Application service type, use NSApplicationMain as its run
loop, and allow for multiple instantiations. Also make sure the service acts
like the WebProcess binary by making it a LSUIElement, enabling LSFileQuarantine,
and setting the principle class to NSApplication.

* WebKit2Service/MainMacService.mm: Added.
(WebKit2ServiceEventHandler):
(main):
The initialization of the XPC service is quite a bit different than the
WebProcess version, since we don't get passed parameters in argv. Instead,
we initiate the XPC service via xpc_main, and wait for the bootstrap message
we sent in ProcessLauncherMac.mm. When we receive that message we can load
WebKit2 framework and initialize the WebProcess normally (we also get the mach_port
for the CoreIPC connection in that bootstrap message).

* WebProcess/mac/WebProcessMainMac.mm:
(WebKit::WebProcessMainXPC):
Add a variant of WebProcessMain that is used for the XPC service case, where we don't
have command line arguments and don't need to talk to the mach bootstrap server.

(WebKit::WebProcessMain):
* mac/MainMac.cpp: Removed.
* mac/MainMacProcess.cpp: Copied from Source/WebKit2/mac/MainMac.cpp.
Rename MainMac to MainMacProcess to signify that it is different from the XPC
service main.

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

7 years agoDo the DecimalNumber to String conversion on 8 bits
benjamin@webkit.org [Sat, 11 Aug 2012 21:17:27 +0000 (21:17 +0000)]
Do the DecimalNumber to String conversion on 8 bits
https://bugs.webkit.org/show_bug.cgi?id=93683

Patch by Benjamin Poulain <bpoulain@apple.com> on 2012-08-11
Reviewed by Andreas Kling.

Source/WebCore:

Numbers converted to string for CSS are unlikely to ever be concatenated with a 16bits string.
This patch change the conversion to be done to 8bits string in order to reduce memory allocations.

* css/CSSPrimitiveValue.cpp:
(WebCore::formatNumber):
* inspector/InspectorValues.cpp:
(WebCore::InspectorBasicValue::writeJSON):
* platform/graphics/Color.cpp:
(WebCore::Color::serialized): Instead of allocating a static WTF::String, we can simply append the
string literal to the output vector.

Source/WTF:

Modify DecimalNumber to do the conversion to string on LChar instead of UChar.

* wtf/DecimalNumber.cpp:
(WTF::DecimalNumber::toStringDecimal):
(WTF::DecimalNumber::toStringExponential):
* wtf/DecimalNumber.h:
(DecimalNumber):
* wtf/dtoa.h:
* wtf/text/StringBuffer.h:
(WTF::StringBuffer::operator[]): StringBuffer::operator[] was incorrectly typed to UChar, making
the method impossible to instanciate with LChar.
* wtf/text/WTFString.h:
(String):
(WTF::String::adopt): String::adopt() is modified to work with both LChar and UChar. StringImpl
already support that.
(WTF::appendNumber): Add support for any type that can instanciate the template.

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

7 years agoWebCore::findAtomicString(PropertyName) always convert the name to 16bits
benjamin@webkit.org [Sat, 11 Aug 2012 21:12:27 +0000 (21:12 +0000)]
WebCore::findAtomicString(PropertyName) always convert the name to 16bits
https://bugs.webkit.org/show_bug.cgi?id=93685

Reviewed by Geoffrey Garen.

Source/WebCore:

* bindings/js/JSDOMBinding.cpp:
(WebCore::findAtomicString):
Use the new AtomicString::find() to avoid calling StringImpl::characters().

Source/WTF:

Previously, WebCore::findAtomicString() was causing a conversion for the 8bit property name
to a 16bits due to the call to StringImpl::character16().

This patch fixes the issue by adding support for both 8bits and 16bits string in AtomicString::find().

* wtf/text/AtomicString.cpp:
(HashAndCharacters):
(WTF::HashAndCharactersTranslator::hash):
(WTF::HashAndCharactersTranslator::equal):
(WTF::HashAndCharactersTranslator::translate):
Use a template to make the struct and the translator independant of the CharacterType.

(WTF::AtomicString::add):
(WTF::findString):
(WTF::AtomicString::find): Change the API to take a StringImpl*. AtomicString can use
it efficiently to find the right string.
* wtf/text/AtomicString.h:
(AtomicString):
* wtf/text/StringImpl.h:
(StringImpl): Adapt the friends translator to support the template.

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

7 years ago[Qt] Remove QtSenderStack now we do not support __qt_sender__ anymore in Qt bridge
caio.oliveira@openbossa.org [Sat, 11 Aug 2012 20:01:53 +0000 (20:01 +0000)]
[Qt] Remove QtSenderStack now we do not support __qt_sender__ anymore in Qt bridge
https://bugs.webkit.org/show_bug.cgi?id=93767

Reviewed by Kenneth Rohde Christiansen.

Dead code after patch of bug 93649.

* bridge/qt/qt_instance.h:
(QtInstance):

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

7 years agowebarchive/ignore-noscript-if-scripting.html expected results should use .webarchive...
jonlee@apple.com [Sat, 11 Aug 2012 19:41:42 +0000 (19:41 +0000)]
webarchive/ignore-noscript-if-scripting.html expected results should use .webarchive extension
https://bugs.webkit.org/show_bug.cgi?id=93736
<rdar://problem/12077654>

Reviewed by Eric Seidel.

Because the test uses dumpDOMAsWebArchive(), the expected results extension should be .webarchive instead of .txt.
* webarchive/ignore-noscript-if-scripting-enabled-expected.webarchive: Renamed from LayoutTests/webarchive/ignore-noscript-if-scripting-enabled-expected.txt.

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

7 years agoUnreviewed.
inferno@chromium.org [Sat, 11 Aug 2012 16:07:22 +0000 (16:07 +0000)]
Unreviewed.

Removing newly added assert in r125351 since it is exposing
legitimate layout bugs in few tests. We will re-add the assert
after fixing those bugs. Failures are tracked in webkit bug 93766.

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::removeFromTrackedRendererMaps):

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

7 years ago[Qt] Add support for HTML5 state object history API in FrameLoaderClientQt
pierre.rossi@gmail.com [Sat, 11 Aug 2012 13:26:27 +0000 (13:26 +0000)]
[Qt] Add support for HTML5 state object history API in FrameLoaderClientQt
https://bugs.webkit.org/show_bug.cgi?id=93648

Reviewed by Kenneth Rohde Christiansen.

Add support for push/replace/pop by implementing dispatchDidNavigateWithinPage.

* WebCoreSupport/FrameLoaderClientQt.cpp:
(WebCore::FrameLoaderClientQt::dispatchDidNavigateWithinPage):
(WebCore::FrameLoaderClientQt::dispatchDidPushStateWithinPage):
(WebCore::FrameLoaderClientQt::dispatchDidReplaceStateWithinPage):
(WebCore::FrameLoaderClientQt::dispatchDidPopStateWithinPage):
* WebCoreSupport/FrameLoaderClientQt.h:
(FrameLoaderClientQt):
* tests/qwebframe/tst_qwebframe.cpp:
(tst_QWebFrame):
(tst_QWebFrame::setUrlUsingStateObject): Added. Tests that the urlChanged signal is fired.

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

7 years agoSource/WebCore: Track block's positioned objects like percent-height descendants
leviw@chromium.org [Sat, 11 Aug 2012 10:44:53 +0000 (10:44 +0000)]
Source/WebCore: Track block's positioned objects like percent-height descendants
https://bugs.webkit.org/show_bug.cgi?id=89848

Reviewed by Abhishek Arya.

The previous method for tracking a RenderBlock's out-of-flow positioned descendants was error prone,
subject to becoming inconsistent, and in the case of removePositionedObjects, inefficient. This patch
extracts the algorithm used for percent height descendants and re-uses it for positioned objects. This same
method could further be re-used for floats.

This change removes the m_positionedObjects pointer, which brings RenderBlock's size down (yay!).

Test: fast/block/positioning/relayout-nested-positioned-elements-crash-2.html

* rendering/RenderBlock.cpp:
(SameSizeAsRenderBlock):
(WebCore):
(WebCore::removeBlockFromDescendantAndContainerMaps):
(WebCore::RenderBlock::~RenderBlock):
(WebCore::RenderBlock::addOverflowFromPositionedObjects):
(WebCore::RenderBlock::layoutBlockChildren):
(WebCore::RenderBlock::layoutPositionedObjects):
(WebCore::RenderBlock::markPositionedObjectsForLayout):
(WebCore::clipOutPositionedObjects):
(WebCore::RenderBlock::selectionGaps):
(WebCore::RenderBlock::insertIntoTrackedRendererMaps):
(WebCore::RenderBlock::removeFromTrackedRendererMaps):
(WebCore::RenderBlock::positionedObjects):
(WebCore::RenderBlock::insertPositionedObject):
(WebCore::RenderBlock::removePositionedObject):
(WebCore::RenderBlock::removePositionedObjects):
(WebCore::RenderBlock::addPercentHeightDescendant):
(WebCore::RenderBlock::removePercentHeightDescendant):
(WebCore::RenderBlock::percentHeightDescendants):
(WebCore::RenderBlock::checkPositionedObjectsNeedLayout):
* rendering/RenderBlock.h:
(WebCore):
(RenderBlock):
(WebCore::RenderBlock::hasPositionedObjects):
* rendering/RenderBox.cpp:
(WebCore::RenderBox::removeFloatingOrPositionedChildFromBlockLists):
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::moveChildTo): Changing the fixme to reflect the assumption that the caller
has taken care of updating the positioned renderer maps is a decision not a bug. The ASSERT should help
assure this.
* rendering/RenderTableSection.cpp:
(WebCore::RenderTableSection::layoutRows):
* rendering/RenderView.cpp:
(WebCore::RenderView::setFixedPositionedObjectsNeedLayout):

LayoutTests: Track block's positioned objects like percent-height children
https://bugs.webkit.org/show_bug.cgi?id=89848

Reviewed by Abhishek Arya.

Adding another test to confirm that RenderBlock's positioned children lists don't become
inconsistent.

* fast/block/positioning/relayout-nested-positioned-elements-crash-2-expected.txt: Added.
* fast/block/positioning/relayout-nested-positioned-elements-crash-2.html: Added.

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

7 years ago[EFL] Bump harfbuzz dependency to v0.9.2
gyuyoung.kim@samsung.com [Sat, 11 Aug 2012 09:37:22 +0000 (09:37 +0000)]
[EFL] Bump harfbuzz dependency to v0.9.2
https://bugs.webkit.org/show_bug.cgi?id=93762

Reviewed by Eric Seidel.

EFL port has used harfbuzz 0.9.0 ver. However, the 0.9.2 version was released on 10th Aug 2012.
In addition, 0.9.0 ver. was disappeared. So, EFL port needs to use 0.9.2 ver. from now on.

* efl/jhbuild.modules:

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

7 years ago[WebGL] Add support for EXT_robustness
commit-queue@webkit.org [Sat, 11 Aug 2012 02:45:06 +0000 (02:45 +0000)]
[WebGL] Add support for EXT_robustness
https://bugs.webkit.org/show_bug.cgi?id=93379

Patch by Joshua Netterfield <jnetterfield@rim.com> on 2012-08-10
Reviewed by George Staikos.

Source/WebCore:

Take advantage of EXT robustness in WebKit.

This commit makes WebKit use readnPixelsEXT, getnUniformfvEXT and
getnUniformivEXT instead of readPixels, getUniformfv and getUniformiv
when possible, and sets up the reset notification behaviour for
GLES platforms.

The reset behaviour has not yet been implemented in the BlackBerry
compositing thread, so for now on BlackBerry we just abort when
the context has been reset. This prevents undefined behaviour, but
can be improved in the future.

No new tests are needed because no new functionality is introduced.
Support for ARB robustness reset notification behaviour is already
in WebKit, and EXT robustness' reset notifcation behaviour is the
same. readnPixelsEXT replaces WebKit's existing mechanisms of
preventing buffer overflows.

RIM PR# 147510
Internally reviewed by Arvid Nilsson.

* html/canvas/WebGLRenderingContext.cpp:
(WebCore):
(WebCore::WebGLRenderingContext::setupFlags):
(WebCore::WebGLRenderingContext::getUniform):
(WebCore::WebGLRenderingContext::readPixels):
* html/canvas/WebGLRenderingContext.h:
(WebGLRenderingContext):
* platform/chromium/support/Extensions3DChromium.cpp:
(WebCore::Extensions3DChromium::readnPixelsEXT):
(WebCore):
(WebCore::Extensions3DChromium::getnUniformfvEXT):
(WebCore::Extensions3DChromium::getnUniformivEXT):
* platform/graphics/Extensions3D.h:
* platform/graphics/blackberry/GraphicsContext3DBlackBerry.cpp:
(WebCore::GraphicsContext3D::setContextLostCallback):
* platform/graphics/blackberry/LayerRenderer.cpp:
(WebCore::LayerRenderer::LayerRenderer):
(WebCore::LayerRenderer::makeContextCurrent):
* platform/graphics/blackberry/LayerRenderer.h:
(LayerRenderer):
* platform/graphics/chromium/Extensions3DChromium.h:
* platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
(WebCore::Extensions3DOpenGLCommon::readnPixelsEXT):
(WebCore):
(WebCore::Extensions3DOpenGLCommon::getnUniformfvEXT):
(WebCore::Extensions3DOpenGLCommon::getnUniformivEXT):
* platform/graphics/opengl/Extensions3DOpenGLCommon.h:
(Extensions3DOpenGLCommon):
* platform/graphics/opengl/Extensions3DOpenGLES.cpp:
(WebCore::Extensions3DOpenGLES::Extensions3DOpenGLES):
(WebCore::Extensions3DOpenGLES::getGraphicsResetStatusARB):
(WebCore):
(WebCore::Extensions3DOpenGLES::setEXTContextLostCallback):
(WebCore::Extensions3DOpenGLES::readnPixelsEXT):
(WebCore::Extensions3DOpenGLES::getnUniformfvEXT):
(WebCore::Extensions3DOpenGLES::getnUniformivEXT):
(WebCore::Extensions3DOpenGLES::supportsExtension):
* platform/graphics/opengl/Extensions3DOpenGLES.h:
(Extensions3DOpenGLES):

Source/WebKit:

RIM PR# 147510
Internally reviewed by Arvid Nilsson.

* CMakeLists.txt: Build system adaptation.

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

7 years agoMicrodata: item with itemprop attribute should not include the item itself in the...
arko@motorola.com [Sat, 11 Aug 2012 02:33:14 +0000 (02:33 +0000)]
Microdata: item with itemprop attribute should not include the item itself in the HTMLPropertiesCollection.
https://bugs.webkit.org/show_bug.cgi?id=93717

Reviewed by Ryosuke Niwa.

Source/WebCore:

Tests: fast/dom/MicroData/item-with-itemprop-attr.html
       fast/dom/MicroData/item-with-itemref-pointing-to-itself.html

* dom/PropertyNodeList.cpp:
(WebCore::PropertyNodeList::nodeMatches): Do not process the testElement if it is the owner node.
* html/HTMLPropertiesCollection.cpp:
(WebCore::nextNodeWithProperty): Traverse the next node only if previous node is microdata item
i.e, ownerNode or previous element does not have itemscope attribute specified.
(WebCore::HTMLPropertiesCollection::virtualItemAfter): Try to find the next property if current
is ownerNode.

LayoutTests:

Added test to ensure that item with itemprop attribute should not include
itself in its HTMLPropetiesCollection.

* fast/dom/MicroData/item-with-itemprop-attr-expected.txt: Added.
* fast/dom/MicroData/item-with-itemprop-attr.html: Added.
* fast/dom/MicroData/item-with-itemref-pointing-to-itself-expected.txt: Added.
* fast/dom/MicroData/item-with-itemref-pointing-to-itself.html: Added.

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

7 years agoLayout Test: plugins/nested-plugin-objects.html passes but causes subsequent test...
commit-queue@webkit.org [Sat, 11 Aug 2012 02:20:32 +0000 (02:20 +0000)]
Layout Test: plugins/nested-plugin-objects.html passes but causes subsequent test to fail on Windows.
https://bugs.webkit.org/show_bug.cgi?id=93741

Patch by Roger Fong <roger_fong@apple.com> on 2012-08-10
Reviewed by Tim Horton.

plugins/nested-plugin-objects.html passes but causes subsequent test to fail on Windows.
plugins/netscape-dom-access-and-reload.html fails as a result.
Or if I skip that test, then plugins/netscape-dom-access.html fails (the next test in the list).

* platform/win/Skipped:
Added plugins/nested-plugin-objects.html to skip list.

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

7 years ago[BlackBerry][EFL][GTK][WIN][WX] Remove ScriptControllerXXX.cpp to reduce duplication
ryuan.choi@samsung.com [Sat, 11 Aug 2012 02:02:51 +0000 (02:02 +0000)]
[BlackBerry][EFL][GTK][WIN][WX] Remove ScriptControllerXXX.cpp to reduce duplication
https://bugs.webkit.org/show_bug.cgi?id=61424

Reviewed by Rob Buis.

ScriptControllerBlackBerry, ScriptControllerEfl, ScriptControllerGtk,
ScriptControllerWin and ScriptControllerWx are almost same.
In order to reduce duplication, this patch moves codes to ScriptController
and removes them.

No behavior change. Just a refactoring.

* GNUmakefile.list.am:
* PlatformBlackBerry.cmake:
* PlatformEfl.cmake:
* PlatformWinCE.cmake:
* WebCore.gypi:
* bindings/js/JSBindingsAllInOne.cpp:
* bindings/js/ScriptController.cpp:
(WebCore):
(WebCore::ScriptController::createScriptInstanceForWidget):
Moved from ScriptControllerXXX.cpp
* bindings/js/ScriptControllerBlackBerry.cpp: Removed.
* bindings/js/ScriptControllerEfl.cpp: Removed.
* bindings/js/ScriptControllerGtk.cpp: Removed.
* bindings/js/ScriptControllerWin.cpp: Removed.
* bindings/js/ScriptControllerWx.cpp: Removed.

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

7 years agoLayoutTest: fast/forms/basic-selects.html rebaselined.
commit-queue@webkit.org [Sat, 11 Aug 2012 01:55:12 +0000 (01:55 +0000)]
LayoutTest: fast/forms/basic-selects.html rebaselined.
https://bugs.webkit.org/show_bug.cgi?id=93751

Patch by Roger Fong <roger_fong@apple.com> on 2012-08-10
Reviewed by Tim Horton.

As per https://bugs.webkit.org/show_bug.cgi?id=92833,
this test needs to be rebaselined for other platforms.
Rebaselining for Windows.

* platform/win/fast/forms/basic-selects-expected.txt:
Rebaselining.

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

7 years agoRenderQuote corrupts doubly linked list on insertion before head of list
commit-queue@webkit.org [Sat, 11 Aug 2012 01:49:14 +0000 (01:49 +0000)]
RenderQuote corrupts doubly linked list on insertion before head of list
https://bugs.webkit.org/show_bug.cgi?id=93750

Patch by Elliott Sprehn <esprehn@gmail.com> on 2012-08-10
Reviewed by Abhishek Arya.

Source/WebCore:

Fix bug where moving a RenderQuote instance before the first one in
the document would not update the m_previous pointer of the original
first RenderQuote to point back at the new one.

Test: fast/css-generated-content/quote-crash-93750.html

* rendering/RenderQuote.cpp:
(WebCore::RenderQuote::attachQuote):

LayoutTests:

Test for moving around RenderQuote nodes before each other in an
existing document to catch corruption in the linked list of RenderQuote.

* fast/css-generated-content/quote-crash-93750-expected.txt: Added.
* fast/css-generated-content/quote-crash-93750.html: Added.

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

7 years agoREGRESSION (r124416): fast/forms/basic-selects.html failing on Lion Debug Tests
dino@apple.com [Sat, 11 Aug 2012 01:45:46 +0000 (01:45 +0000)]
REGRESSION (r124416): fast/forms/basic-selects.html failing on Lion Debug Tests
https://bugs.webkit.org/show_bug.cgi?id=93538

Unreviewed gardening. Rebaseline of this test for Mac ports, and
remove expected failure.

* platform/mac/TestExpectations:
* platform/mac/fast/forms/basic-selects-expected.png:
* platform/mac/fast/forms/basic-selects-expected.txt:

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

7 years agoUnreviewed gardening. Missing platform expectations for this test. Results
dino@apple.com [Sat, 11 Aug 2012 01:33:47 +0000 (01:33 +0000)]
Unreviewed gardening. Missing platform expectations for this test. Results
are identical to chromium-mac at present.

* platform/mac/svg/repaint/text-mask-update-expected.txt: Added.

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

7 years ago(r125185) http/tests/images/jpg-img-partial-load.html timeout on Lion
dino@apple.com [Sat, 11 Aug 2012 00:59:56 +0000 (00:59 +0000)]
(r125185) http/tests/images/jpg-img-partial-load.html timeout on Lion
https://bugs.webkit.org/show_bug.cgi?id=93636

Unreviewed test expectation update for Mac.

* platform/mac/TestExpectations:

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

7 years ago[chromium] Remove forwarding headers for compositor-related WebKit API and update...
jamesr@google.com [Sat, 11 Aug 2012 00:55:17 +0000 (00:55 +0000)]
[chromium] Remove forwarding headers for compositor-related WebKit API and update includes
https://bugs.webkit.org/show_bug.cgi?id=93669

Reviewed by Adam Barth.

Source/Platform:

Removes a no-longer-necessary transitional define.

* chromium/public/WebCompositor.h:

Source/WebCore:

Updates all includes for compositor-related headers to refer consistently to the Platform API location.

* platform/chromium/support/WebCompositorImpl.h:

Source/WebKit/chromium:

This updates all includes for compositor-related headers to refer consistently to the Platform API location and
removes the now-unneeded forwarding headers in the client API location. I also updated and resorted other
platform API includes in modified header blocks.

* WebKit.gyp:
* public/WebCompositor.h: Removed.
* public/platform/WebContentLayer.h: Removed.
* public/platform/WebContentLayerClient.h: Removed.
* public/platform/WebExternalTextureLayer.h: Removed.
* public/platform/WebLayer.h: Removed.
* public/platform/WebLayerTreeView.h: Removed.
* public/platform/WebLayerTreeViewClient.h: Removed.
* public/platform/WebSolidColorLayer.h: Removed.
* src/WebCompositorInputHandlerImpl.h:
* src/WebContentLayerImpl.cpp:
* src/WebLayer.cpp:
* src/WebLayerTreeView.cpp:
* src/WebLayerTreeViewImpl.cpp:
* src/WebLayerTreeViewImpl.h:
* src/WebSolidColorLayer.cpp:
* src/WebViewImpl.h:
* tests/Canvas2DLayerBridgeTest.cpp:
* tests/GraphicsLayerChromiumTest.cpp:
* tests/TextureLayerChromiumTest.cpp:

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

7 years agoUnreviewed build fix.
jamesr@google.com [Sat, 11 Aug 2012 00:32:19 +0000 (00:32 +0000)]
Unreviewed build fix.

r125337 added a call to WTF::currentTime() in MediaController.cpp, but that file didn't #include
<wtf/CurrentTime.h>. This file is indirectly picked up on the include paths for some ports, but not all.

* html/MediaController.cpp:

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

7 years agono timeupdate events emitted for media controller
jer.noble@apple.com [Fri, 10 Aug 2012 23:50:46 +0000 (23:50 +0000)]
no timeupdate events emitted for media controller
https://bugs.webkit.org/show_bug.cgi?id=93745

Reviewed by Eric Carlson.

Source/WebCore:

Generate timeupdate events while the current position is changing.

Test: media/media-controller-timeupdate.html

Enforce the spec requirement that the timeupdate event is fired no more often
than every 250ms.
* html/MediaController.cpp:
(MediaController::scheduleTimeupdateEvent):

Add a periodic firing timer to generate timeupdate events during playback.
* html/MediaController.cpp:
(MediaController::startTimeupdateTimer):
(MediaController::timeupdateTimerFired):

* html/MediaController.cpp:
(MediaController::MediaController): Initialize m_previousTimeupdateTime.
(MediaController::setCurrentTime): Call scheduleTimeUpdateEvent.
(MediaController::updatePlaybackState): Start and stop the timeupdate timer.
* html/MediaController.h:

LayoutTests:

New test checking that the timeupdate event is emmitted correctly during playback.

* media/media-controller-timeupdate-expected.txt: Added.
* media/media-controller-timeupdate.html: Added.

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

7 years agoUnreviewed. Rolled DEPS.
commit-queue@webkit.org [Fri, 10 Aug 2012 23:33:55 +0000 (23:33 +0000)]
Unreviewed.  Rolled DEPS.

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

* DEPS:

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

7 years agoAllow blocking of third-party localStorage and sessionStorage
jpfau@apple.com [Fri, 10 Aug 2012 23:13:37 +0000 (23:13 +0000)]
Allow blocking of third-party localStorage and sessionStorage
https://bugs.webkit.org/show_bug.cgi?id=93390

Reviewed by Adam Barth.

Source/WebCore:

Add checks for if a page is third-party and third-party storage blocking is enabled while accessing storage.

Tests: http/tests/security/cross-origin-local-storage-allowed.html
       http/tests/security/cross-origin-local-storage.html
       http/tests/security/cross-origin-session-storage-allowed.html
       http/tests/security/cross-origin-session-storage.html
       http/tests/security/same-origin-document-domain-storage-allowed.html

* dom/Document.cpp:
(WebCore::Document::initSecurityContext): Initialize securityOrigin with knowledge of if we should block third-party storage.
* page/DOMWindow.cpp: Check if the origin trying to access storage is third-party relative to the top document.
(WebCore::DOMWindow::sessionStorage):
(WebCore::DOMWindow::localStorage):
* page/SecurityOrigin.cpp: Add a call in Security origin to see if another origin counts as a third-party.
(WebCore::SecurityOrigin::SecurityOrigin):
(WebCore::SecurityOrigin::canAccessLocalStorage):
(WebCore):
(WebCore::SecurityOrigin::isThirdParty):
* page/SecurityOrigin.h:
(WebCore::SecurityOrigin::blockThirdPartyStorage):
(SecurityOrigin):
* testing/InternalSettings.cpp: Add an internals.settings hook for setting third-party storage blocking enabled.
(WebCore::InternalSettings::setThirdPartyStorageBlockingEnabled):
(WebCore):
* testing/InternalSettings.h:
(InternalSettings):
* testing/InternalSettings.idl:

LayoutTests:

Created tests for testing accessing localStorage and selfStorage from a third party and first party when third-party blocking is on and off.

* http/tests/security/cross-origin-local-storage-allowed-expected.txt: Added.
* http/tests/security/cross-origin-local-storage-allowed.html: Added.
* http/tests/security/cross-origin-local-storage-expected.txt: Added.
* http/tests/security/cross-origin-local-storage.html: Added.
* http/tests/security/cross-origin-session-storage-allowed-expected.txt: Added.
* http/tests/security/cross-origin-session-storage-allowed.html: Added.
* http/tests/security/cross-origin-session-storage-expected.txt: Added.
* http/tests/security/cross-origin-session-storage.html: Added.
* http/tests/security/same-origin-document-domain-storage-allowed-expected.html: Added.
* http/tests/security/same-origin-document-domain-storage-allowed.html: Added.
* http/tests/security/resources/document-domain-iframe-for-local-storage.html: Added.
* http/tests/security/resources/cross-origin-iframe-for-local-storage.html: Added.
* http/tests/security/resources/cross-origin-iframe-for-session-storage.html: Added.

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

7 years agoSource/WebCore: REGRESSION(r125159): ASSERTION FAILED: m_listsInvalidatedAtDocument...
arko@motorola.com [Fri, 10 Aug 2012 22:52:41 +0000 (22:52 +0000)]
Source/WebCore: REGRESSION(r125159): ASSERTION FAILED: m_listsInvalidatedAtDocument.contains(list) in Document::unregisterNodeListCache.
https://bugs.webkit.org/show_bug.cgi?id=93729

Reviewed by Ryosuke Niwa.

In Document::registerNodeListCache() it was not adding PropertyNodeList
cache to m_listsInvalidatedAtDocument the as node list currently not rooted
at the document. Where in Document::unregisterNodeListCache() it was trying
to remove PropertyNodeList cache from m_listsInvalidatedAtDocument. Hence it
caused the assertion failure.

We need to check if m_rootType is NodeListIsRootedAtDocumentIfOwnerHasItemrefAttr,
not that it's currently rooted at the document.

Test: fast/dom/MicroData/propertynodelist-crash.html

* dom/DynamicNodeList.h:
(WebCore::DynamicNodeListCacheBase::isRootedAtDocument):

LayoutTests: REGRESSION(r125159): ASSERTION FAILED: m_listsInvalidatedAtDocument.contains(list) in Document::unregisterNodeListCache.
https://bugs.webkit.org/show_bug.cgi?id=93729

Reviewed by Ryosuke Niwa.

Added a test to ensure that it does not crash in Document::unregisterNodeListCache.

* fast/dom/MicroData/propertynodelist-crash-expected.txt: Added.
* fast/dom/MicroData/propertynodelist-crash.html: Added.

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

7 years agoImproved RuleData packing on some 32-bit platforms
fmalita@chromium.org [Fri, 10 Aug 2012 22:41:51 +0000 (22:41 +0000)]
Improved RuleData packing on some 32-bit platforms
https://bugs.webkit.org/show_bug.cgi?id=93737

Reviewed by Andreas Kling.

Certain 32-bit plarforms use an 8-byte alignment for uint64_t. We can save 4 bytes per
object on these platforms by using two naturally-aligning unsigned ints instead.

* css/StyleResolver.cpp:
(RuleData):
(SameSizeAsRuleData):

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

7 years agorun-perf-tests should upload memory statistics to perf-o-matic
rniwa@webkit.org [Fri, 10 Aug 2012 22:17:57 +0000 (22:17 +0000)]
run-perf-tests should upload memory statistics to perf-o-matic
https://bugs.webkit.org/show_bug.cgi?id=93690

Reviewed by Dirk Pranke.

Upload JS Heap and FastMalloc results for a test X/Y as: X/Y:JSHeap and X/Y:FastMalloc.
Note "JS Heap" is converted to the CamelCase JSHeap.

Also did some refactoring in PerfTest.parse_output and PerfTestRunnerTest and updated
some helps in PerfTest.parse_output per arv's comments.

* Scripts/webkitpy/performance_tests/perftest.py:
(PerfTest):
(PerfTest.parse_output): Include JSHeap and FastMalloc statistics in results as well as of Time.
Also refactored it to avoid hard-coding indices in _result_classes and moved complied regular
exressions out of the function to avoid re-compiling them every time the method runs.
(PerfTest.output_statistics): Convert ':' to ': ' as well as '/'.
(ChromiumStylePerfTest.parse_output): Removed an unused variable.
* Scripts/webkitpy/performance_tests/perftestsrunner.py:
(PerfTestsRunner._parse_args): Uploaded some helps per arv's feedback.
(PerfTestsRunner._output_json_path): Extracted from _generate_and_show_results to be used in
PerfTestRunnerTest.create_runner.
(PerfTestsRunner._generate_and_show_results):
* Scripts/webkitpy/performance_tests/perftestsrunner_unittest.py:
(create_runner): Extracted runner.load_output_json from various tests.
(test_run_memory_test): Added.
(PerfTestRunner): Extracted _event_target_wrapper_and_inspector_results from various tests.
(test_run_with_json_output):
(test_run_with_description):
(test_run_generates_json_by_default):
(test_run_generates_and_show_results_page):
(test_run_with_json_source):
(test_run_with_multiple_repositories):

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

7 years ago[CSS Shaders] Add blend mode and composite op to compiled program cache key
commit-queue@webkit.org [Fri, 10 Aug 2012 22:15:52 +0000 (22:15 +0000)]
[CSS Shaders] Add blend mode and composite op to compiled program cache key
https://bugs.webkit.org/show_bug.cgi?id=93623

Patch by Max Vujovic <mvujovic@adobe.com> on 2012-08-10
Reviewed by Dirk Schulze.

Right now, only the vertex shader string and the fragment shader string are hashed
to create a key for the compiled program. However, in a future patch, WebKit will
rewrite the fragment shader based on the blend mode and composite op specified by
the author. This means that the unique key for a compiled program is (original
vertex shader string, original fragment shader string, blend mode, composite
operator). This patch adds blend mode and composite operator in the hash for the
key.

No new tests. The state of the compiled program cache is not exposed to a web
page. Existing tests should ensure this change doesn't break current
functionality. Additional tests will be added in a future patch that implements
shader rewriting based on blend mode and composite op.

* platform/graphics/filters/CustomFilterProgram.cpp:
(WebCore::CustomFilterProgram::programInfo):
* platform/graphics/filters/CustomFilterProgram.h:
(WebCore):
* platform/graphics/filters/CustomFilterProgramInfo.cpp:
(WebCore::CustomFilterProgramInfo::CustomFilterProgramInfo):
(WebCore::CustomFilterProgramInfo::hash):
(WebCore::CustomFilterProgramInfo::operator==):
* platform/graphics/filters/CustomFilterProgramInfo.h:
(WebCore::CustomFilterProgramMixSettings::CustomFilterProgramMixSettings):
(CustomFilterProgramMixSettings):
(WebCore::CustomFilterProgramMixSettings::operator==):
(WebCore):
(CustomFilterProgramInfo):

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

7 years agoPart 1 of: Extend -webkit-user-select with a new value "all"
commit-queue@webkit.org [Fri, 10 Aug 2012 21:48:04 +0000 (21:48 +0000)]
Part 1 of: Extend -webkit-user-select with a new value "all"
<rdar://problem/10161404>
https://bugs.webkit.org/show_bug.cgi?id=93562

Patch by Alice Cheng <alice_cheng@apple.com> on 2012-08-10
Reviewed by Dan Bernstein.

Source/WebCore:

Parse the new "all" value for -webkit-user-select

Test: editing/selection/user-select-all-parsing.html

* css/CSSParser.cpp:
(WebCore::isValidKeywordPropertyAndValue): Add new value all
* css/CSSPrimitiveValueMappings.h:
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Add new value all
(WebCore::CSSPrimitiveValue::operator EUserSelect): Add one more bit to store the new property value
* rendering/style/RenderStyleConstants.h: Add new value all
* rendering/style/StyleRareInheritedData.h: Add new value all
(StyleRareInheritedData):

Source/WebKit/gtk:

Modify the enum to resolve ambiguous reference

* webkit/webkitwebview.cpp:
(webkit_web_view_class_init): Modify the ambiguous enum
(webkit_web_view_select_all): Modify the ambiguous enum

LayoutTests:

Add a test to verify that the new "all" value is parsed correctly.

* editing/selection/user-select-all-parsing-expected.txt: Added.
* editing/selection/user-select-all-parsing.html: Added.

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

7 years ago[chromium] Upstream Android changes to WebFrameImpl::selectRange
commit-queue@webkit.org [Fri, 10 Aug 2012 21:45:43 +0000 (21:45 +0000)]
[chromium] Upstream Android changes to WebFrameImpl::selectRange
https://bugs.webkit.org/show_bug.cgi?id=92513

Patch by Iain Merrick <husky@google.com> on 2012-08-10
Reviewed by Ryosuke Niwa.

Source/WebCore:

Make this function public we so can call it from the WebKit layer.

* page/EventHandler.h:
(EventHandler):

Source/WebKit/chromium:

This change is driven by the Chromium port on the Android platform,
but it should be suitable for other touch-based platforms. We reuse
selectionExtentRespectingEditingBoundary (extracted from EventHandler
into VisibleSelection).

* src/WebFrameImpl.cpp:
(WebKit::WebFrameImpl::selectRange):
(WebKit::WebFrameImpl::visiblePositionForWindowPoint):

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

7 years ago[Chromium] Updated results for fast/borders/border-shadow-large-radius.html.
fmalita@chromium.org [Fri, 10 Aug 2012 21:42:57 +0000 (21:42 +0000)]
[Chromium] Updated results for fast/borders/border-shadow-large-radius.html.

Unreviewed gardening.

* platform/chromium-win/fast/borders/border-shadow-large-radius-expected.png: Added.

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

7 years ago[GTK] Broken implementation of AtkText and AtkEditableText for password fields
mario@webkit.org [Fri, 10 Aug 2012 21:09:08 +0000 (21:09 +0000)]
[GTK] Broken implementation of AtkText and AtkEditableText for password fields
https://bugs.webkit.org/show_bug.cgi?id=93621

Rubber-stamped by Ryosuke Niwa.

Fix Apple Win build, by avoiding to generate unreachable sections
of code in AccessibilityRenderObject::passwordFieldValue().

* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::passwordFieldValue):

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

7 years ago[chromium] Remove targetSurface pointer from CCRenderPass
danakj@chromium.org [Fri, 10 Aug 2012 20:40:38 +0000 (20:40 +0000)]
[chromium] Remove targetSurface pointer from CCRenderPass
https://bugs.webkit.org/show_bug.cgi?id=93734

Reviewed by Adrienne Walker.

Source/WebCore:

This removes the CCRenderSurface pointer from the CCRenderPass
structure, allowing it to be serialized and used across processes
freely.

No new tests; no intended change in behaviour.

* platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
(WebCore::CCLayerTreeHostImpl::drawLayers):
* platform/graphics/chromium/cc/CCRenderPass.cpp:
(WebCore::CCRenderPass::CCRenderPass):
* platform/graphics/chromium/cc/CCRenderPass.h:
(CCRenderPass):

Source/WebKit/chromium:

Use the RenderPass's damageRect instead of the surface's damageRect
directly to test the same things without requiring a pointer to
the surface that generated the RenderPass.

* tests/CCLayerTreeHostImplTest.cpp:

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

7 years agoIntroduce JavaScriptVariant object.
commit-queue@webkit.org [Fri, 10 Aug 2012 20:40:11 +0000 (20:40 +0000)]
Introduce JavaScriptVariant object.
https://bugs.webkit.org/show_bug.cgi?id=93644

The JavaScriptVariant can be used for functions that return results from
JavaScript such as executeJavaScript or functions that take arguments
to pass a variable to JavaScript and they want to make sure the type
is correct.

Convert executeJavaScriptFunction() to use this data type as the
example, other functions will be converted in the future.

PR 14929

Internally reviewed by Joe Mason
Patch by Benjamin C Meyer <bmeyer@rim.com> on 2012-08-10
Reviewed by Adam Treat

Source/WebKit:

* PlatformBlackBerry.cmake:

Source/WebKit/blackberry:

* Api/JavaScriptVariant.cpp: Added.
(WebKit):
(BlackBerry::WebKit::JSValueRefToBlackBerryJavaScriptVariant):
(BlackBerry::WebKit::BlackBerryJavaScriptVariantToJSValueRef):
(BlackBerry::WebKit::JavaScriptVariant::JavaScriptVariant):
(BlackBerry::WebKit::JavaScriptVariant::~JavaScriptVariant):
(BlackBerry::WebKit::JavaScriptVariant::operator=):
(BlackBerry::WebKit::JavaScriptVariant::setType):
(BlackBerry::WebKit::JavaScriptVariant::type):
(BlackBerry::WebKit::JavaScriptVariant::setDouble):
(BlackBerry::WebKit::JavaScriptVariant::doubleValue):
(BlackBerry::WebKit::JavaScriptVariant::setString):
(BlackBerry::WebKit::JavaScriptVariant::stringValue):
(BlackBerry::WebKit::JavaScriptVariant::setBoolean):
(BlackBerry::WebKit::JavaScriptVariant::booleanValue):
* Api/JavaScriptVariant.h: Added.
(WebKit):
* Api/JavaScriptVariant_p.h: Added.
(WebKit):
* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPage::executeJavaScriptFunction):
* Api/WebPage.h:

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

7 years agoUnreviewed, rolling out r125310.
fmalita@chromium.org [Fri, 10 Aug 2012 20:30:45 +0000 (20:30 +0000)]
Unreviewed, rolling out r125310.
http://trac.webkit.org/changeset/125310
https://bugs.webkit.org/show_bug.cgi?id=93739

The DEPS roll broke Android. One does not simply break
Android. (Requested by fmalita_ on #webkit).

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

* DEPS:

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

7 years ago[BlackBerry] Enable relro link option for JSC executable
rwlbuis@webkit.org [Fri, 10 Aug 2012 20:21:57 +0000 (20:21 +0000)]
[BlackBerry] Enable relro link option for JSC executable
https://bugs.webkit.org/show_bug.cgi?id=93726

Reviewed by Yong Li.

Enable relro link option for JSC executable.

* Source/cmake/OptionsBlackBerry.cmake:

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

7 years ago[GTK] Broken implementation of AtkText and AtkEditableText for password fields
mario@webkit.org [Fri, 10 Aug 2012 20:20:54 +0000 (20:20 +0000)]
[GTK] Broken implementation of AtkText and AtkEditableText for password fields
https://bugs.webkit.org/show_bug.cgi?id=93621

Reviewed by Chris Fleizach.

Source/WebCore:

Fix broken implementation of AtkText and AtkEditableText
interfaces in the GTK port for password input fields.

* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::stringValue): Call the new
function passwordFieldValue() for password input fields.
(WebCore::AccessibilityRenderObject::text): Ditto.
(WebCore::AccessibilityRenderObject::textLength): Return the
actual length of the password in the field for GTK, return -1
otherwise (not to break current behavior in other platforms).
(WebCore::AccessibilityRenderObject::doAXStringForRange): Don't
early return for password fields in GTK (will rely on text()).
(WebCore::AccessibilityRenderObject::passwordFieldValue): New, it
returns the text being actually rendered for a password input
field (normally a masked string) in GTK. It returns String() in
the rest of platforms, to ensure we don't break anything there.
(WebCore):
* accessibility/AccessibilityRenderObject.h:
(AccessibilityRenderObject):
* accessibility/AccessibilityObject.h:
(WebCore::AccessibilityObject::passwordFieldValue): Default
implementation of this new method, returning an empty string.
(AccessibilityObject):

Ensure the 'text-insert' and 'text-remove' signals for the AtkText
interface are properly emitted for password input fields.

* accessibility/gtk/AXObjectCacheAtk.cpp:
(WebCore::AXObjectCache::nodeTextChangePlatformNotification): Make
sure we never emit the password value for an input field in plain
text when inserting or removing text. Emit the masked text instead.

Source/WebKit/gtk:

Update unit test to ensure that password input fields behave
as expected when inserting and removing characters in them.

* tests/testatk.c:
(testWebkitAtkTextChangedNotifications): Updated unit test to
cover the special case of password input fields.

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

7 years agoAdd support for String initialization from literal to WTFString
benjamin@webkit.org [Fri, 10 Aug 2012 20:18:15 +0000 (20:18 +0000)]
Add support for String initialization from literal to WTFString
https://bugs.webkit.org/show_bug.cgi?id=93426

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

Source/WTF:

This patch adds two constructor to WTF::String in order to support fast initialization from literal:
-String(ASCIILiteral): Constructor similar to String(const char*) while being faster. This constructor
 does not incur any overhead over String(const char*).
-String(char[], ConstructFromLiteralTag): Template constructor that encode explicitely the size of the
 string.

String(ASCIILiteral) is expected to be used in most cases to avoid regressions. This constructor was
added because of what we have learned from r124922: inlining the string length in the code causes a code bloat
that is not always welcome.

Regarding performance of string initialization, the constructors performance are (6 characters string):
-String(ASCIILiteral): 16% faster.
-String(char[], ConstructFromLiteralTag): 33% faster (the delta increases with the string length).

In addition, no memory is allocated for the characters.

* wtf/text/StringImpl.cpp:
* wtf/text/StringImpl.h:
(WTF::StringImpl::createFromLiteral): Extend StringImpl::createFromLiteral to have a version
with strlen() which avoids loading one extra argument.
* wtf/text/WTFString.cpp:
(WTF::String::String):
* wtf/text/WTFString.h:
(WTF::String::String):
(ASCIILiteral): This class is aimed at making the construction of WTFString from a literal very easy.
By using the explicit constructor ASCIILiteral(char *), one can expect the implicit conversion to String
when needed.
(WTF::ASCIILiteral::ASCIILiteral):
(WTF::ASCIILiteral::operator const char*):

Tools:

* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/WTF/StringImpl.cpp:
(TestWebKitAPI::TEST):
* TestWebKitAPI/Tests/WTF/WTFString.cpp: Copied from Tools/TestWebKitAPI/Tests/WTF/StringImpl.cpp.
(TestWebKitAPI):
(TestWebKitAPI::TEST):

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

7 years agoCrash exiting from HTML5 FS mode to normal mode via ESC key
jer.noble@apple.com [Fri, 10 Aug 2012 20:16:45 +0000 (20:16 +0000)]
Crash exiting from HTML5 FS mode to normal mode via ESC key
https://bugs.webkit.org/show_bug.cgi?id=93663

Reviewed by Eric Carlson.

Crash is due to a refcount underrun with _watchdogTimer due to adopting an autoreleased NSTimer.
Use the non-autoreleased NSTimer creation method and manually add to the main NSRunLoop.

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

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

7 years agoUse the new AVPlayerItemVideoOutput API in MediaPlayerPrivateAVFoundation.
jer.noble@apple.com [Fri, 10 Aug 2012 20:13:02 +0000 (20:13 +0000)]
Use the new AVPlayerItemVideoOutput API in MediaPlayerPrivateAVFoundation.
https://bugs.webkit.org/show_bug.cgi?id=93591

Reviewed by Eric Carlson.

Support the new AVPlayerItemVideoOutput API from Mountain Lion, which has much increased performance over
AVAssetImageGenerator.

No new tests; Performance change only, no net change in functionality.

AVPlayerItemVideoOutput requires an attached CALayer for rendering to occur.  Make the rendering modes non-exclusive,
so layer-rendering and context-rendering can exist simultaneously:
* platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h: Make the MediaRenderingMode enum
    a bitfield.
* platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
(WebCore::MediaPlayerPrivateAVFoundation::currentRenderingModes): Renamed from currentRenderingMode().
(WebCore::MediaPlayerPrivateAVFoundation::setUpVideoRendering): Check for the presence of the MediaRenderingToLayer bit.
(WebCore::MediaPlayerPrivateAVFoundation::prepareForRendering): Ditto.
(WebCore::MediaPlayerPrivateAVFoundation::updateStates): Ditto.

Pull out existing the AVAssetImageGenerator into its own functions:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::createImageGenerator):
(WebCore::MediaPlayerPrivateAVFoundationObjC::destroyImageGenerator):
(WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithImageGenerator):

Add new AVPlayerItemVideoOutput equivalent functions:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoOutput):
(WebCore::MediaPlayerPrivateAVFoundationObjC::destroyVideoOutput):
(WebCore::MediaPlayerPrivateAVFoundationObjC::createPixelBuffer):
(WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput):

Switch between the AVAssetImageGenerator and AVPlayerItemVideoOutput functions from
within the original functions:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::createContextVideoRenderer):
(WebCore::MediaPlayerPrivateAVFoundationObjC::destroyContextVideoRenderer):
(WebCore::MediaPlayerPrivateAVFoundationObjC::hasContextRenderer):
(WebCore::MediaPlayerPrivateAVFoundationObjC::paint):

* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::createImageForTimeInRect): Call the
    AVAssetImageGenerator creation function directly.

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

7 years agoUnreviewed; fix an insanely silly typo.
rniwa@webkit.org [Fri, 10 Aug 2012 20:10:57 +0000 (20:10 +0000)]
Unreviewed; fix an insanely silly typo.

* resources/results-template.html:

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

7 years agoNRWT crashes when DRT with --encode-binary crashes just before it dumps pixels
wangxianzhu@chromium.org [Fri, 10 Aug 2012 19:49:22 +0000 (19:49 +0000)]
NRWT crashes when DRT with --encode-binary crashes just before it dumps pixels
https://bugs.webkit.org/show_bug.cgi?id=93728

Reviewed by Dirk Pranke.

* Scripts/webkitpy/layout_tests/port/driver.py:
(ContentBlock.decode_content): Check self.content is not None before calling base64.b64decode().

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

7 years agoCrash on accessing a removed layout root in FrameView::scheduleRelayout.
inferno@chromium.org [Fri, 10 Aug 2012 19:41:20 +0000 (19:41 +0000)]
Crash on accessing a removed layout root in FrameView::scheduleRelayout.
https://bugs.webkit.org/show_bug.cgi?id=91368

Reviewed by Levi Weintraub.

We were calling setNeedsLayoutAndPrefWidthsRecalc() in RenderBlock::collapseAnonymousBoxChild
even when documentBeingDestroyed() was true. This ends up accessing stale layout root and bypasses
mitigation added in r109406. There is no need to waste time merging up anonymous blocks in
RenderBlock::removeChild when documentBeingDestroyed() is true.

No new tests. The test is time sensitive, requires a bunch of reloads, and only reproduces on chromium linux.

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::collapseAnonymousBoxChild):
(WebCore::RenderBlock::removeChild):

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

7 years ago<rdar://problem/11855229> When in paginated mode, the layout timer fires continually
mitz@apple.com [Fri, 10 Aug 2012 19:38:59 +0000 (19:38 +0000)]
<rdar://problem/11855229> When in paginated mode, the layout timer fires continually
https://bugs.webkit.org/show_bug.cgi?id=91038

Reviewed by Simon Fraser.

* page/Page.cpp:
(WebCore::Page::pageCount): Changed to only trigger layout if needed.

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

7 years agoUnreviewed GTK gardening.
zandobersek@gmail.com [Fri, 10 Aug 2012 19:22:51 +0000 (19:22 +0000)]
Unreviewed GTK gardening.

Updating or adding newly-generated pixel baselines for tests in animations,
dom/xhtml/level3/core, scrollbars, transforms and transitions directories.

* platform/gtk/animations/3d/change-transform-in-end-event-expected.png: Added.
* platform/gtk/animations/3d/matrix-transform-type-animation-expected.png: Added.
* platform/gtk/animations/3d/replace-filling-transform-expected.png: Added.
* platform/gtk/animations/3d/state-at-end-event-transform-expected.png: Added.
* platform/gtk/animations/additive-transform-animations-expected.png: Added.
* platform/gtk/animations/cross-fade-background-image-expected.png: Added.
* platform/gtk/animations/cross-fade-border-image-source-expected.png: Added.
* platform/gtk/animations/cross-fade-list-style-image-expected.png: Added.
* platform/gtk/animations/cross-fade-webkit-mask-box-image-expected.png: Added.
* platform/gtk/animations/cross-fade-webkit-mask-image-expected.png: Added.
* platform/gtk/animations/missing-values-last-keyframe-expected.png: Added.
* platform/gtk/animations/opacity-transform-animation-expected.png: Added.
* platform/gtk/animations/state-at-end-event-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/canonicalform08-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/canonicalform09-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/documentgetinputencoding03-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/entitygetinputencoding02-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/entitygetxmlversion02-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/nodegetbaseuri05-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/nodegetbaseuri07-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/nodegetbaseuri09-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/nodegetbaseuri10-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/nodegetbaseuri11-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/nodegetbaseuri15-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/nodegetbaseuri17-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/nodegetbaseuri18-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/nodelookupnamespaceuri01-expected.png: Added.
* platform/gtk/dom/xhtml/level3/core/nodelookupprefix19-expected.png: Added.
* platform/gtk/scrollbars/basic-scrollbar-expected.png: Added.
* platform/gtk/scrollbars/custom-scrollbar-with-incomplete-style-expected.png:
* platform/gtk/scrollbars/disabled-scrollbar-expected.png: Added.
* platform/gtk/scrollbars/listbox-scrollbar-combinations-expected.png: Added.
* platform/gtk/scrollbars/overflow-scrollbar-combinations-expected.png: Added.
* platform/gtk/scrollbars/scrollbar-buttons-expected.png: Added.
* platform/gtk/scrollbars/scrollbar-orientation-expected.png: Added.
* platform/gtk/scrollbars/scrollbars-on-positioned-content-expected.png:
* platform/gtk/transforms/2d/compound-transforms-vs-containers-expected.png: Added.
* platform/gtk/transforms/2d/hindi-rotated-expected.png:
* platform/gtk/transforms/2d/transform-borderbox-expected.png: Added.
* platform/gtk/transforms/2d/transform-fixed-container-expected.png:
* platform/gtk/transforms/2d/transform-origin-borderbox-expected.png: Added.
* platform/gtk/transforms/2d/zoom-menulist-expected.png:
* platform/gtk/transforms/svg-vs-css-expected.png: Added.
* platform/gtk/transitions/cross-fade-background-image-expected.png: Added.
* platform/gtk/transitions/cross-fade-border-image-expected.png: Added.
* platform/gtk/transitions/default-timing-function-expected.png:
* platform/gtk/transitions/move-after-transition-expected.png: Added.
* platform/gtk/transitions/opacity-transition-zindex-expected.png: Added.
* platform/gtk/transitions/suspend-transform-transition-expected.png: Added.
* platform/gtk/transitions/svg-text-shadow-transition-expected.png: Added.
* platform/gtk/transitions/transition-end-event-rendering-expected.png: Added.

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

7 years ago[CMAKE] Fix wrong idl include path in CMakeList.txt
gyuyoung.kim@samsung.com [Fri, 10 Aug 2012 19:10:18 +0000 (19:10 +0000)]
[CMAKE] Fix wrong idl include path in CMakeList.txt
https://bugs.webkit.org/show_bug.cgi?id=93715

Reviewed by Rob Buis.

No new tests. No change in behavior.

* CMakeLists.txt: Fix notifications path.

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

7 years agoUnreviewed. Rolled DEPS.
commit-queue@webkit.org [Fri, 10 Aug 2012 18:59:29 +0000 (18:59 +0000)]
Unreviewed.  Rolled DEPS.

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

* DEPS:

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

7 years ago[Transforms] Hit test issue with large scale() transform
allan.jensen@nokia.com [Fri, 10 Aug 2012 18:42:38 +0000 (18:42 +0000)]
[Transforms] Hit test issue with large scale() transform
https://bugs.webkit.org/show_bug.cgi?id=23170

Reviewed by Simon Fraser.

Source/WebCore:

By using normal rounding to determine the top-left corner of the
hit-tested rectangle, we end up offsetting the hit test by up to
half a pixel, once scaled to x60, this creates a 30px error.

Normal rounding is replaced with floored rounding which means the
hit-tested pixel will now always be the pixel containing the
point.

Test: fast/transforms/hit-test-large-scale.html

* rendering/HitTestResult.cpp:
(WebCore::HitTestPoint::HitTestPoint):
(WebCore::HitTestPoint::intersectsRect):
(WebCore::HitTestPoint::rectForPoint):

LayoutTests:

New test checking that we can hit the bottom-right part of an element with
a large scale transformation.

Modified test-input on perspective-clipped.html, since it was mathematically
0.1px inside the transformed target, but used to miss due to bad rounding.

* fast/transforms/hit-test-large-scale-expected.txt: Added.
* fast/transforms/hit-test-large-scale.html: Added.
* transforms/3d/hit-testing/perspective-clipped-expected.txt:
* transforms/3d/hit-testing/perspective-clipped.html:

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

7 years agoUnreviewed gardening: build fix for 32bit platforms after 125294.
fmalita@chromium.org [Fri, 10 Aug 2012 18:40:46 +0000 (18:40 +0000)]
Unreviewed gardening: build fix for 32bit platforms after 125294.

* css/StyleResolver.cpp:
(RuleData):

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

7 years agoSource/WebCore: box-shadow creates incorrect shadow when border-radius is too large
commit-queue@webkit.org [Fri, 10 Aug 2012 18:35:37 +0000 (18:35 +0000)]
Source/WebCore: box-shadow creates incorrect shadow when border-radius is too large
https://bugs.webkit.org/show_bug.cgi?id=72103

Patch by Takashi Sakamoto <tasak@google.com> on 2012-08-10
Reviewed by Simon Fraser.

Added a code for adjusting a rounded rect before paintBoxShadow in
a similar way to getRoundedRectFor.

Test: fast/borders/border-shadow-large-radius.html

* platform/graphics/RoundedRect.cpp:
(WebCore::RoundedRect::adjustRadii):
Added a new method to set radii's scale to fit into rect.
* platform/graphics/RoundedRect.h:
(RoundedRect):
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::paintBoxShadow):
A rounded rect for box-shadow is not checked whether the raii matches
the rect or not. Added the code to adjust radii's scale if the rounded
rect is not renderable, the case: RoundedRect::isRenderable is false.

LayoutTests: box-shadow creates incorrect shadow when border-radius is too large.
https://bugs.webkit.org/show_bug.cgi?id=72103

Patch by Takashi Sakamoto <tasak@google.com> on 2012-08-10
Reviewed by Simon Fraser.

* fast/borders/border-shadow-large-radius.html: Added.
* fast/borders/border-shadow-large-radius-expected.txt: Added.
* platform/chromium-linux/fast/borders/border-shadow-large-radius-expected.png: Added.
* platform/chromium-mac/fast/borders/border-shadow-large-radius-expected.png: Added.

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

7 years agoUnreviewed GTK gardening.
zandobersek@gmail.com [Fri, 10 Aug 2012 18:31:48 +0000 (18:31 +0000)]
Unreviewed GTK gardening.

Removing expectation for css3/flexbox/inline-flex-crash2.html after
the fix for it was landed in r125302.

* platform/gtk/TestExpectations:

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

7 years agoNew test introduced in r125262 css3/flexbox/inline-flex-crash2.html fails
ojan@chromium.org [Fri, 10 Aug 2012 18:24:47 +0000 (18:24 +0000)]
New test introduced in r125262 css3/flexbox/inline-flex-crash2.html fails
https://bugs.webkit.org/show_bug.cgi?id=93718

Test uses layoutTestController instead of testRunner.

* css3/flexbox/inline-flex-crash2.html:
* platform/qt/Skipped:

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

7 years agoWrap INLINE_FLEX in a #if ENABLE(CSS3_FLEXBOX).
ojan@chromium.org [Fri, 10 Aug 2012 18:21:06 +0000 (18:21 +0000)]
Wrap INLINE_FLEX in a #if ENABLE(CSS3_FLEXBOX).
Unreviewed build fix.

* rendering/style/RenderStyle.h:

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

7 years ago[BlackBerry] Fix wrong include path for notifications.
gyuyoung.kim@samsung.com [Fri, 10 Aug 2012 17:57:03 +0000 (17:57 +0000)]
[BlackBerry] Fix wrong include path for notifications.
https://bugs.webkit.org/show_bug.cgi?id=93714

Reviewed by Rob Buis.

* PlatformBlackBerry.cmake: Change path from notifications to Modules/notifications.

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

7 years ago[Chromium-Android][NRWT] Executable might not be pushed correctly when there are...
wangxianzhu@chromium.org [Fri, 10 Aug 2012 17:52:56 +0000 (17:52 +0000)]
[Chromium-Android][NRWT] Executable might not be pushed correctly when there are multiple builds
https://bugs.webkit.org/show_bug.cgi?id=93688

Reviewed by Dirk Pranke.

There might be other better methods, but this change is the smallest.
I think the chance of equal timestamp can be ignored because we flock
to avoid concurrent linkers.

* Scripts/webkitpy/layout_tests/port/chromium_android.py:
(ChromiumAndroidDriver._push_executable): Changed '<' to '!=' to compare the timestamp.

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

7 years agoRenamed the “Modules/webaudio” group in the Xcode project to “webaudio” and moved...
mitz@apple.com [Fri, 10 Aug 2012 17:42:57 +0000 (17:42 +0000)]
Renamed the “Modules/webaudio” group in the Xcode project to “webaudio” and moved it into
the Modules group.

Rubber-stamped by Simon Fraser.

* WebCore.xcodeproj/project.pbxproj:

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

7 years agoUnreviewed GTK gardening.
zandobersek@gmail.com [Fri, 10 Aug 2012 17:35:26 +0000 (17:35 +0000)]
Unreviewed GTK gardening.

Adding failure expectations for failures introduced in r125133 and r125262.

* platform/gtk/TestExpectations:

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

7 years ago[V8] Enable es5_readonly
arv@chromium.org [Fri, 10 Aug 2012 17:05:11 +0000 (17:05 +0000)]
[V8] Enable es5_readonly
https://bugs.webkit.org/show_bug.cgi?id=91031

Reviewed by Adam Barth.

This turns on the es5_readonly flag for V8. This makes V8 match the ES5 spec regarding
non writable properties on the prototype chain. JSC already behaves the right so this
just makes V8 behave the same.

Source/WebCore:

Updated test expectations.

* bindings/v8/V8DOMWindowShell.cpp:
(WebCore::V8DOMWindowShell::initContextIfNeeded):
* bindings/v8/WorkerContextExecutionProxy.cpp:
(WebCore::WorkerContextExecutionProxy::initIsolate):

LayoutTests:

* platform/chromium/media/network-no-source-const-shadow-expected.txt: Added.

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

7 years ago[V8] Introduce V8DOMConfiguration class and make batchConfigureXXX() methods static
haraken@chromium.org [Fri, 10 Aug 2012 17:03:15 +0000 (17:03 +0000)]
[V8] Introduce V8DOMConfiguration class and make batchConfigureXXX() methods static
https://bugs.webkit.org/show_bug.cgi?id=93615

Reviewed by Adam Barth.

Per the discussion in bug 93239,

(1) Rename V8ConfigureDOMAttributesAndMethods to V8DOMConfiguration.
(2) Introduce V8DOMConfiguration class and make batchConfigureXXX() methods static.

No tests. No change in behavior.

* UseV8.cmake:
* WebCore.gypi:
* bindings/scripts/CodeGeneratorV8.pm:
(GenerateImplementation):
* bindings/scripts/test/V8/V8Float64Array.cpp:
(WebCore):
(WebCore::ConfigureV8Float64ArrayTemplate):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore):
(WebCore::ConfigureV8TestActiveDOMObjectTemplate):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
(WebCore):
(WebCore::ConfigureV8TestCustomNamedGetterTemplate):
* bindings/scripts/test/V8/V8TestEventConstructor.cpp:
(WebCore):
(WebCore::ConfigureV8TestEventConstructorTemplate):
* bindings/scripts/test/V8/V8TestEventTarget.cpp:
(WebCore):
(WebCore::ConfigureV8TestEventTargetTemplate):
* bindings/scripts/test/V8/V8TestException.cpp:
(WebCore):
(WebCore::ConfigureV8TestExceptionTemplate):
* bindings/scripts/test/V8/V8TestInterface.cpp:
(WebCore):
(WebCore::ConfigureV8TestInterfaceTemplate):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
(WebCore):
(WebCore::ConfigureV8TestMediaQueryListListenerTemplate):
* bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
(WebCore::ConfigureV8TestNamedConstructorTemplate):
* bindings/scripts/test/V8/V8TestNode.cpp:
(WebCore::ConfigureV8TestNodeTemplate):
* bindings/scripts/test/V8/V8TestObj.cpp:
(WebCore):
(WebCore::ConfigureV8TestObjTemplate):
(WebCore::V8TestObj::installPerContextProperties):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
(WebCore):
(WebCore::ConfigureV8TestSerializedScriptValueInterfaceTemplate):
* bindings/v8/V8Binding.h:
* bindings/v8/V8ConfigureDOMAttributesAndMethods.h: Removed.
* bindings/v8/V8DOMConfiguration.cpp: Renamed from Source/WebCore/bindings/v8/V8ConfigureDOMAttributesAndMethods.cpp.
(WebCore):
(WebCore::V8DOMConfiguration::batchConfigureAttributes):
(WebCore::V8DOMConfiguration::batchConfigureConstants):
(WebCore::V8DOMConfiguration::batchConfigureCallbacks):
(WebCore::V8DOMConfiguration::configureTemplate):
* bindings/v8/V8DOMConfiguration.h: Added.
(WebCore):
(V8DOMConfiguration):
(BatchedAttribute):
(WebCore::V8DOMConfiguration::configureAttribute):
(BatchedConstant):
(BatchedCallback):

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

7 years agoCSS: Shrink RuleData by storing selector as index rather than pointer.
kling@webkit.org [Fri, 10 Aug 2012 17:00:40 +0000 (17:00 +0000)]
CSS: Shrink RuleData by storing selector as index rather than pointer.
<http://webkit.org/b/93712>

Reviewed by Antti Koivisto.

Pack the selector's index in the rule in the RuleData bitfield, effectively
shrinking each RuleData by 8 bytes.

* css/CSSSelectorList.h:
(WebCore::CSSSelectorList::selectorAt):
(WebCore::CSSSelectorList::indexOfNextSelectorAfter):

    Add helpers to CSSSelectorList to iterate by index.

* css/StyleResolver.cpp:
(RuleData):
(WebCore::RuleData::selector):
(WebCore::RuleData::selectorIndex):
(SameSizeAsRuleData):
(RuleSet):
(WebCore::makeRuleSet):
(WebCore::StyleResolver::collectMatchingRulesForList):
* css/StyleResolver.h:
(WebCore::StyleResolver::RuleFeature::RuleFeature):
(RuleFeature):

    Store selector indices instead of CSSSelector* pointers.

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

7 years agoRemove custom bindings from WaveShaperNode.
commit-queue@webkit.org [Fri, 10 Aug 2012 16:48:57 +0000 (16:48 +0000)]
Remove custom bindings from WaveShaperNode.
https://bugs.webkit.org/show_bug.cgi?id=93613

Patch by Vineet Chaudhary <rgf748@motorola.com> on 2012-08-10
Reviewed by Kentaro Hara.

We should remove custom bindings as CodeGenerator uses UNUSED_PARAM macro.

TestObj.idl
No behavioural changes.
All tests under webaudio/* should behave same.

* GNUmakefile.list.am: Removed JSWaveShaperNodeCustom.cpp from builds.
* Modules/webaudio/WaveShaperNode.idl: Removed [JSCustomSetter].
* UseJSC.cmake: Removed JSWaveShaperNodeCustom.cpp from builds.
* WebCore.xcodeproj/project.pbxproj: Ditto.
* bindings/js/JSWaveShaperNodeCustom.cpp: Removed.
* bindings/scripts/CodeGeneratorCPP.pm:
(SkipAttribute): Skip TypedArray attribute.
* bindings/scripts/CodeGeneratorGObject.pm:
(SkipAttribute): Skip TypedArray attribute.
* bindings/scripts/CodeGeneratorObjC.pm:
(SkipAttribute): Skip TypedArray attribute.
* bindings/scripts/test/JS/JSTestObj.cpp: Bindings tests.
(WebCore::jsTestObjTypedArrayAttr):
(WebCore::setJSTestObjReflectedCustomURLAttr):
(WebCore::setJSTestObjTypedArrayAttr):
* bindings/scripts/test/JS/JSTestObj.h:
* bindings/scripts/test/TestObj.idl: Test.
* bindings/scripts/test/V8/V8TestObj.cpp: Bindings tests.
(WebCore::TestObjV8Internal::typedArrayAttrAttrGetter):
(TestObjV8Internal):
(WebCore::TestObjV8Internal::typedArrayAttrAttrSetter):

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

7 years agoREGRESSION (r123848): Heap-use-after-free in WebCore::CachedResource::didAddClient.
commit-queue@webkit.org [Fri, 10 Aug 2012 16:35:14 +0000 (16:35 +0000)]
REGRESSION (r123848): Heap-use-after-free in WebCore::CachedResource::didAddClient.
https://bugs.webkit.org/show_bug.cgi?id=93632
-and corresponding-
<http://crbug.com/140656>

Patch by Huang Dongsung <luxtella@company100.net> on 2012-08-10
Reviewed by Antti Koivisto.

CachedCSSStyleSheet::didAddClient() calls CachedStyleSheetClient::setCSSStyleSheet
and HTMLLnkElement can be CachedStyleSheetClient.
HTMLLinkElement::setCSSStyleSheet may cause scripts to be executed, which could
destroy the HTMLLinkElement instance. After calliing
CachedStyleSheetClient::setCSSStyleSheet, using the CachedStyleSheetClient
instance can cause Heap-use-after-free.

r115625 prevents HTMLLinkElement from being destroyed during
HTMLLinkElement::setCSSStyleSheet, but r115625 doesn't prevent HTMLLinkElement
from being destroyed after HTMLLinkElement::setCSSStyleSheet.

So this patch calls CachedResource::didAddClient() before calling
setCSSStyleSheet() to make sure its client is not destroyed.

No new tests. it's covered by fast/css/cached-sheet-restore-crash.html.

* loader/cache/CachedCSSStyleSheet.cpp:
(WebCore::CachedCSSStyleSheet::didAddClient):

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

7 years ago[Qt] WebViewLoadFavIcon::test_favIconLoad() fails
rafael.lobo@openbossa.org [Fri, 10 Aug 2012 16:30:23 +0000 (16:30 +0000)]
[Qt] WebViewLoadFavIcon::test_favIconLoad() fails
https://bugs.webkit.org/show_bug.cgi?id=91888

Reviewed by Simon Hausmann.

* UIProcess/API/qt/tests/qmltests/WebView/tst_favIconLoad.qml:
We should wait for iconChanged signal instead of loadFinished,
there was no guarantee that at that point we would get it already.

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

7 years ago[BlackBerry] GCActivityCallback should always schedule GC even allocated bytes is...
commit-queue@webkit.org [Fri, 10 Aug 2012 16:21:25 +0000 (16:21 +0000)]
[BlackBerry] GCActivityCallback should always schedule GC even allocated bytes is a small number
https://bugs.webkit.org/show_bug.cgi?id=93650

Patch by Yong Li <yoli@rim.com> on 2012-08-10
Reviewed by Rob Buis.

Even a small number of allocated JS objects could hold expensive resources.

* runtime/GCActivityCallbackBlackBerry.cpp:
(JSC::DefaultGCActivityCallback::didAllocate):

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

7 years agoHorizontal scrollbar appears in the month-year selector of input[type=date]
commit-queue@webkit.org [Fri, 10 Aug 2012 16:15:59 +0000 (16:15 +0000)]
Horizontal scrollbar appears in the month-year selector of input[type=date]
https://bugs.webkit.org/show_bug.cgi?id=93517

Patch by Kevin Ellis <kevers@chromium.org> on 2012-08-10
Reviewed by Kent Tamura.

Update size of the month-year selector popup to account for the
width of the vertical scrollbar being platform dependent.

* Resources/calendarPicker.css:
(.month-selector-popup): Suppress horizontal scrolling.
* Resources/calendarPicker.js:
(YearMonthController.prototype.attachTo): Add a sizer element to facilitate determining the scrollbar width.
(YearMonthController.prototype._showPopup): Use computed scrollbar width for popup resizing.

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

7 years ago[Qt] Uninitialized flags in CoordinatedGraphicsLayer
allan.jensen@nokia.com [Fri, 10 Aug 2012 16:08:16 +0000 (16:08 +0000)]
[Qt] Uninitialized flags in CoordinatedGraphicsLayer
https://bugs.webkit.org/show_bug.cgi?id=93719

Reviewed by Kenneth Rohde Christiansen.

* WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.cpp:
(WebCore::CoordinatedGraphicsLayer::CoordinatedGraphicsLayer):

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

7 years agoWeb Inspector: Unreviewed, fix frontend compilability after r125268.
apavlov@chromium.org [Fri, 10 Aug 2012 16:06:02 +0000 (16:06 +0000)]
Web Inspector: Unreviewed, fix frontend compilability after r125268.

* inspector/front-end/CSSStyleModel.js:
(WebInspector.NamedFlow):
(WebInspector.NamedFlow.parsePayloadArray):

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

7 years ago[Qt] Dotted borders not drawn with rounded dots
commit-queue@webkit.org [Fri, 10 Aug 2012 15:56:55 +0000 (15:56 +0000)]
[Qt] Dotted borders not drawn with rounded dots
https://bugs.webkit.org/show_bug.cgi?id=92383

Patch by Martin Leutelt <martin.leutelt@basyskom.com> on 2012-08-10
Reviewed by Noam Rosenthal.

The dots in borders with dotted style were previously drawn with
rectangular dots. The CSS spec specifies that the dots should be
rounded dots. This patch fixes this behavior for the Qt port.

No new tests, existing ones have been updated with new expected
results.

Source/WebCore:

* platform/graphics/qt/GraphicsContextQt.cpp:
(WebCore::adjustPointsForDottedLine):
(WebCore):
(WebCore::drawLineEndpointsForStyle):
(WebCore::GraphicsContext::drawLine):

LayoutTests:

* platform/qt/css2.1/t170602-bdr-conflct-w-04-d-expected.png:
* platform/qt/css2.1/t170602-bdr-conflct-w-14-d-expected.png:
* platform/qt/css2.1/t170602-bdr-conflct-w-24-d-expected.png:
* platform/qt/css2.1/t170602-bdr-conflct-w-34-d-expected.png:
* platform/qt/css2.1/t170602-bdr-conflct-w-41-d-expected.png:
* platform/qt/css2.1/t170602-bdr-conflct-w-42-d-expected.png:
* platform/qt/css2.1/t170602-bdr-conflct-w-43-d-expected.png:
* platform/qt/css2.1/t170602-bdr-conflct-w-44-d-expected.png:
* platform/qt/css2.1/t170602-bdr-conflct-w-49-d-expected.png:
* platform/qt/css2.1/t170602-bdr-conflct-w-94-d-expected.png:
* platform/qt/editing/inserting/editing-empty-divs-expected.png:
* platform/qt/fast/backgrounds/repeat/negative-offset-repeat-expected.png:
* platform/qt/fast/css/margin-top-bottom-dynamic-expected.png:
* platform/qt/fast/layers/opacity-outline-expected.png:
* platform/qt/fast/lists/ordered-list-with-no-ol-tag-expected.png:
* platform/qt/fast/multicol/progression-reverse-expected.png:
* platform/qt/fast/overflow/overflow-with-local-background-attachment-expected.png:
* platform/qt/fast/table/border-collapsing/001-expected.png:
* platform/qt/fast/table/border-collapsing/001-vertical-expected.png:
* platform/qt/svg/custom/no-inherited-dashed-stroke-expected.png:
* platform/qt/svg/transforms/svg-css-transforms-expected.png:
* platform/qt/tables/mozilla/bugs/bug22019-expected.png:
* platform/qt/tables/mozilla/bugs/bug2947-expected.png:
* platform/qt/tables/mozilla/bugs/bug6674-expected.png:
* platform/qt/tables/mozilla/marvin/backgr_layers-opacity-expected.png:
* platform/qt/tables/mozilla/marvin/backgr_position-table-expected.png:
* platform/qt/tables/mozilla/marvin/backgr_simple-table-cell-expected.png:
* platform/qt/tables/mozilla/marvin/backgr_simple-table-column-expected.png:
* platform/qt/tables/mozilla/marvin/backgr_simple-table-column-group-expected.png:
* platform/qt/tables/mozilla/marvin/backgr_simple-table-expected.png:
* platform/qt/tables/mozilla/marvin/backgr_simple-table-row-expected.png:
* platform/qt/tables/mozilla/marvin/backgr_simple-table-row-group-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_border-table-cell-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_border-table-column-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_border-table-column-group-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_border-table-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_border-table-quirks-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_border-table-row-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_border-table-row-group-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_fixed-bg-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_layers-hide-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_position-table-cell-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_position-table-column-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_position-table-column-group-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_position-table-row-expected.png:
* platform/qt/tables/mozilla_expected_failures/marvin/backgr_position-table-row-group-expected.png:
* platform/qt/transforms/svg-vs-css-expected.png:

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

7 years agoWeb Inspector: render arrays as dir in case they were logged into console prior to...
pfeldman@chromium.org [Fri, 10 Aug 2012 15:42:23 +0000 (15:42 +0000)]
Web Inspector: render arrays as dir in case they were logged into console prior to the front-end opening.
https://bugs.webkit.org/show_bug.cgi?id=93713

Reviewed by Vsevolod Vlasov.

Source/WebCore:

Dumping potentially outdated arrays using the "dir" representation.

* inspector/front-end/ConsoleMessage.js:
(WebInspector.ConsoleMessageImpl):
(WebInspector.ConsoleMessageImpl.prototype._formatParameterAsArray):
(WebInspector.ConsoleMessageImpl.prototype.clone):
* inspector/front-end/ConsoleModel.js:
(WebInspector.ConsoleModel.prototype.enableAgent.callback):
(WebInspector.ConsoleModel.prototype.enablingConsole):
(WebInspector.ConsoleMessage.create):
(WebInspector.ConsoleDispatcher.prototype.messageAdded):
* inspector/front-end/ConsoleView.js:
(WebInspector.ConsoleMessage.create):

LayoutTests:

* inspector/console/console-dirxml-expected.txt:
* inspector/console/console-external-array-expected.txt:
* inspector/console/console-format-collections-expected.txt:
* inspector/console/console-format-expected.txt:
* inspector/console/console-format.html:
* inspector/console/console-tests-expected.txt:
* platform/chromium/inspector/console/console-format-collections-expected.txt:

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

7 years ago[chromium] Fix the colors in the debugging HUD
danakj@chromium.org [Fri, 10 Aug 2012 15:36:47 +0000 (15:36 +0000)]
[chromium] Fix the colors in the debugging HUD
https://bugs.webkit.org/show_bug.cgi?id=93656

Reviewed by Adrienne Walker.

The R and B channels became swapped in our compositor debug HUD when
wkb.ug/92182 happened. This corrects the problem by swizzling the
color channels when we draw to the SkCanvas, so that it matches the
expectations of the shader.

Chromium bug: crbug.com/139908

* platform/graphics/chromium/cc/CCFontAtlas.cpp:
(WebCore::CCFontAtlas::drawText):
(WebCore::CCFontAtlas::drawOneLineOfTextInternal):
* platform/graphics/chromium/cc/CCFontAtlas.h:
(CCFontAtlas):
* platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.cpp:
(WebCore::createPaint):
(WebCore):
(WebCore::CCHeadsUpDisplayLayerImpl::drawHudContents):
(WebCore::CCHeadsUpDisplayLayerImpl::drawFPSCounter):
(WebCore::CCHeadsUpDisplayLayerImpl::drawFPSCounterText):
(WebCore::CCHeadsUpDisplayLayerImpl::drawDebugRects):

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

7 years ago[chromium] Remove scissor from the namings in CCOcclusionTracker
danakj@chromium.org [Fri, 10 Aug 2012 15:29:02 +0000 (15:29 +0000)]
[chromium] Remove scissor from the namings in CCOcclusionTracker
https://bugs.webkit.org/show_bug.cgi?id=93630

Reviewed by Adrienne Walker.

Source/WebCore:

As a followup to wkb.ug/91800 which stops using partial-swap scissor
in the occlusion tracker, this does a large rename to the occlusion
tracker and affected tests to remove "scissor" from the names of its
variables and methods, instead reflecting their new behaviour.

* platform/graphics/chromium/cc/CCOcclusionTracker.cpp:
(WebCore::::CCOcclusionTrackerBase):
(WebCore::addOcclusionBehindLayer):
(WebCore::::markOccludedBehindLayer):
(WebCore::testContentRectOccluded):
(WebCore::::occluded):
(WebCore::computeUnoccludedContentRect):
(WebCore::::unoccludedContentRect):
(WebCore::::unoccludedContributingSurfaceContentRect):
(WebCore::::layerClipRectInTarget):
(WebCore):
* platform/graphics/chromium/cc/CCOcclusionTracker.h:
(CCOcclusionTrackerBase):
(WebCore::CCOcclusionTrackerBase::computeVisibleRegionInScreen):

Source/WebKit/chromium:

* tests/CCOcclusionTrackerTest.cpp:
(WebKitTests::TestCCOcclusionTrackerWithClip::TestCCOcclusionTrackerWithClip):
(WebKitTests::TestCCOcclusionTrackerWithClip::setLayerClipRect):
(WebKitTests::TestCCOcclusionTrackerWithClip::useDefaultLayerClipRect):
(WebKitTests::TestCCOcclusionTrackerWithClip::layerClipRectInTarget):
(TestCCOcclusionTrackerWithClip):
(WebKitTests::CCOcclusionTrackerTestIdentityTransforms::runMyTest):
(WebKitTests::CCOcclusionTrackerTestRotatedChild::runMyTest):
(WebKitTests::CCOcclusionTrackerTestTranslatedChild::runMyTest):
(WebKitTests::CCOcclusionTrackerTestChildInRotatedChild::runMyTest):
(WebKitTests::CCOcclusionTrackerTestVisitTargetTwoTimes::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceRotatedOffAxis::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceWithTwoOpaqueChildren::runMyTest):
(WebKitTests::CCOcclusionTrackerTestOverlappingSurfaceSiblings::runMyTest):
(WebKitTests::CCOcclusionTrackerTestOverlappingSurfaceSiblingsWithTwoTransforms::runMyTest):
(WebKitTests::CCOcclusionTrackerTestFilters::runMyTest):
(WebKitTests::CCOcclusionTrackerTestReplicaDoesOcclude::runMyTest):
(WebKitTests::CCOcclusionTrackerTestReplicaWithClipping::runMyTest):
(WebKitTests::CCOcclusionTrackerTestReplicaWithMask::runMyTest):
(WebKitTests::CCOcclusionTrackerTestLayerClipRectOutsideChild::runMyTest):
(WebKitTests):
(WebKitTests::CCOcclusionTrackerTestViewportRectOutsideChild::runMyTest):
(WebKitTests::CCOcclusionTrackerTestLayerClipRectOverChild::runMyTest):
(WebKitTests::CCOcclusionTrackerTestViewportRectOverChild::runMyTest):
(WebKitTests::CCOcclusionTrackerTestLayerClipRectPartlyOverChild::runMyTest):
(WebKitTests::CCOcclusionTrackerTestViewportRectPartlyOverChild::runMyTest):
(WebKitTests::CCOcclusionTrackerTestLayerClipRectOverNothing::runMyTest):
(WebKitTests::CCOcclusionTrackerTestViewportRectOverNothing::runMyTest):
(WebKitTests::CCOcclusionTrackerTestLayerClipRectForLayerOffOrigin::runMyTest):
(WebKitTests::CCOcclusionTrackerTestOpaqueContentsRegionEmpty::runMyTest):
(WebKitTests::CCOcclusionTrackerTestOpaqueContentsRegionNonEmpty::runMyTest):
(WebKitTests::CCOcclusionTrackerTest3dTransform::runMyTest):
(WebKitTests::CCOcclusionTrackerTestUnsorted3dLayers::runMyTest):
(WebKitTests::CCOcclusionTrackerTestPerspectiveTransform::runMyTest):
(WebKitTests::CCOcclusionTrackerTestPerspectiveTransformBehindCamera::runMyTest):
(WebKitTests::CCOcclusionTrackerTestLayerBehindCameraDoesNotOcclude::runMyTest):
(WebKitTests::CCOcclusionTrackerTestLargePixelsOccludeInsideClipRect::runMyTest):
(WebKitTests::CCOcclusionTrackerTestAnimationOpacity1OnMainThread::runMyTest):
(WebKitTests::CCOcclusionTrackerTestAnimationOpacity0OnMainThread::runMyTest):
(WebKitTests::CCOcclusionTrackerTestAnimationTranslateOnMainThread::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceOcclusionTranslatesToParent::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceOcclusionTranslatesWithClipping::runMyTest):
(WebKitTests::CCOcclusionTrackerTestReplicaOccluded::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceWithReplicaUnoccluded::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceAndReplicaOccludedDifferently::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceChildOfSurface::runMyTest):
(WebKitTests::CCOcclusionTrackerTestTopmostSurfaceIsClippedToViewport::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceChildOfClippingSurface::runMyTest):
(WebKitTests::CCOcclusionTrackerTestDontOccludePixelsNeededForBackgroundFilter::runMyTest):
(WebKitTests::CCOcclusionTrackerTestTwoBackgroundFiltersReduceOcclusionTwice::runMyTest):
(WebKitTests::CCOcclusionTrackerTestDontOccludePixelsNeededForBackgroundFilterWithClip::runMyTest):
(WebKitTests::CCOcclusionTrackerTestDontReduceOcclusionBelowBackgroundFilter::runMyTest):
(WebKitTests::CCOcclusionTrackerTestDontReduceOcclusionIfBackgroundFilterIsOccluded::runMyTest):
(WebKitTests::CCOcclusionTrackerTestReduceOcclusionWhenBackgroundFilterIsPartiallyOccluded::runMyTest):
(WebKitTests::CCOcclusionTrackerTestMinimumTrackingSize::runMyTest):
* tests/TiledLayerChromiumTest.cpp:

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

7 years agoChange Notification.permissionLevel() to Notification.permission
jonlee@apple.com [Fri, 10 Aug 2012 15:20:41 +0000 (15:20 +0000)]
Change Notification.permissionLevel() to Notification.permission
https://bugs.webkit.org/show_bug.cgi?id=88919
<rdar://problem/11650319>

Reviewed by Kentaro Hara.

Source/WebCore:

Retrieving the permission level has changed to Notification.permission, per this discussion:
http://lists.w3.org/Archives/Public/public-web-notification/2012Jun/0000.html

Test: fast/notifications/notifications-permission.html

* Modules/notifications/Notification.cpp: Rename to match attribute name.
(WebCore::Notification::permission):
* Modules/notifications/Notification.h: Rename to match attribute name.
(Notification):
* Modules/notifications/Notification.idl: Change to static readonly attribute.

LayoutTests:

* fast/notifications/notifications-permission-expected.txt: Added.
* fast/notifications/notifications-permission.html: Added.
* platform/chromium/TestExpectations: V8 does not properly support IDL static
attributes. This is tracked in bug 93488.

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

7 years ago[V8] Remove collectIsolatedContexts() from V8Proxy
haraken@chromium.org [Fri, 10 Aug 2012 15:16:22 +0000 (15:16 +0000)]
[V8] Remove collectIsolatedContexts() from V8Proxy
https://bugs.webkit.org/show_bug.cgi?id=93682

Reviewed by Adam Barth.

We want to remove V8Proxy. This patch removes V8Proxy::collectIsolatedContexts().

No tests. No change in behavior.

* bindings/v8/ScriptController.cpp:
(WebCore::ScriptController::collectIsolatedContexts):
* bindings/v8/V8Proxy.cpp:
(WebCore::V8Proxy::collectIsolatedContexts):

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

7 years ago[Qt] Unreviewed trivial build fix: Avoid passing a non-existance WebCore/websockets...
hausmann@webkit.org [Fri, 10 Aug 2012 14:12:43 +0000 (14:12 +0000)]
[Qt] Unreviewed trivial build fix: Avoid passing a non-existance WebCore/websockets directory
to the generators, which produces unnecessary warnings. The module lives now in WebCore/Modules/websockets.

* DerivedSources.pri:

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

7 years agoWeb Inspector: add frame ids to TimeStamp, Time and TimeEnd records in Timeline
caseq@chromium.org [Fri, 10 Aug 2012 13:42:47 +0000 (13:42 +0000)]
Web Inspector: add frame ids to TimeStamp, Time and TimeEnd records in Timeline
https://bugs.webkit.org/show_bug.cgi?id=93699

Reviewed by Pavel Feldman.

Source/WebCore:

- plumb Frame from Console to TimelineAgent and use it to add frameId to 3 timeline records;

* inspector/InspectorConsoleInstrumentation.h:
(WebCore::InspectorInstrumentation::startConsoleTiming):
(WebCore::InspectorInstrumentation::stopConsoleTiming):
(WebCore::InspectorInstrumentation::consoleTimeStamp):
* inspector/InspectorInstrumentation.cpp:
(WebCore):
(WebCore::InspectorInstrumentation::startConsoleTimingImpl):
(WebCore::InspectorInstrumentation::stopConsoleTimingImpl):
(WebCore::InspectorInstrumentation::consoleTimeStampImpl):
* inspector/InspectorInstrumentation.h:
(InspectorInstrumentation):
* inspector/InspectorTimelineAgent.cpp:
(WebCore::InspectorTimelineAgent::didTimeStamp):
(WebCore::InspectorTimelineAgent::time):
(WebCore::InspectorTimelineAgent::timeEnd):
* inspector/InspectorTimelineAgent.h:
(InspectorTimelineAgent):
* page/Console.cpp:
(WebCore::Console::markTimeline):
(WebCore::Console::time):
(WebCore::Console::timeEnd):
(WebCore::Console::timeStamp):

LayoutTests:

- rebased expectations to include frameId field;
- removed platform overrides for chromium as these are identical to the default ones;

* inspector/timeline/timeline-mark-timeline-expected.txt:
* inspector/timeline/timeline-time-stamp-expected.txt:
* platform/chromium/inspector/timeline/timeline-mark-timeline-expected.txt: Removed.
* platform/chromium/inspector/timeline/timeline-time-stamp-expected.txt: Removed.

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

7 years ago[Qt] Fix failing assertions when using JSC C API in QObject bridge
hausmann@webkit.org [Fri, 10 Aug 2012 13:40:33 +0000 (13:40 +0000)]
[Qt] Fix failing assertions when using JSC C API in QObject bridge
https://bugs.webkit.org/show_bug.cgi?id=93720

Reviewed by Kenneth Rohde Christiansen.

Avoid calling JSValueProtect and JSValueIsEqual with null JSValueRefs, as in debug
builds they trigger failing assertions about the arguments being non-null.

In these signal & slot connections the receiver can be null, when the signal is connected
just to a function, for example using obj.mySignal.connect(function() { .... }).

* bridge/qt/qt_runtime.cpp:
(JSC::Bindings::QtConnectionObject::QtConnectionObject):
(JSC::Bindings::QtConnectionObject::~QtConnectionObject):
(JSC::Bindings::QtConnectionObject::match):

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

7 years ago[Qt] Remove QRegExp <> JS RegExp conversion
hausmann@webkit.org [Fri, 10 Aug 2012 13:37:46 +0000 (13:37 +0000)]
[Qt] Remove QRegExp <> JS RegExp conversion
https://bugs.webkit.org/show_bug.cgi?id=93716

Reviewed by Kenneth Rohde Christiansen.

Source/WebCore:

Removed automatic conversion between QRegExp and JS regular expressions. The semantics
between the expressions are totally different, which can cause data loss and unexpected
behaviour. QJSEngine/Value doesn't have this conversion anymore neither.

* bridge/qt/qt_runtime.cpp:
(JSC::Bindings::operator<<):
(JSC::Bindings::valueRealType):
(JSC::Bindings::convertValueToQVariant):
(JSC::Bindings::convertQVariantToValue):

Source/WebKit/qt:

Removed tests that cover the automatic QRegExp <> JS RegExp conversion. See WebCore
ChangeLog for details.

* tests/qobjectbridge/tst_qobjectbridge.cpp:
(MyQObject::emitMySignalWithDateTimeArg):
(MyQObject):
(tst_QObjectBridge::overloadedSlots):
(tst_QObjectBridge::typeConversion):

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

7 years ago[Qt] Unreviwed gardening.
kkristof@inf.u-szeged.hu [Fri, 10 Aug 2012 13:35:48 +0000 (13:35 +0000)]
[Qt] Unreviwed gardening.
https://bugs.webkit.org/show_bug.cgi?id=93718

Patch by Zoltan Arvai <zarvai@inf.u-szeged.hu> on 2012-08-10

* platform/qt/Skipped: xmlviewer/extensions-api.html moved, skip new failing test after r125262.

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

7 years ago[EFL][WK2] Add Skipped file for EFL WK2
commit-queue@webkit.org [Fri, 10 Aug 2012 13:29:42 +0000 (13:29 +0000)]
[EFL][WK2] Add Skipped file for EFL WK2
https://bugs.webkit.org/show_bug.cgi?id=93645

Unreviewed gardening.

Added LayoutTests/platform/efl-wk2/Skipped file, so that it will be possible to keep EFL WK2 bot green.

Patch by Mikhail Pozdnyakov <mikhail.pozdnyakov@intel.com> on 2012-08-10

* platform/efl-wk2/Skipped: Added.

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

7 years agoWeb Inspector: console.timeStamp() marked are not shown in Timeline overview
caseq@chromium.org [Fri, 10 Aug 2012 13:24:50 +0000 (13:24 +0000)]
Web Inspector: console.timeStamp() marked are not shown in Timeline overview
https://bugs.webkit.org/show_bug.cgi?id=93697

Reviewed by Pavel Feldman.

Source/WebCore:

- ignore frameId on TimeStamp records, consider it's always an event divider.

* inspector/front-end/TimelinePresentationModel.js:
(WebInspector.TimelinePresentationModel.isEventDivider):

LayoutTests:

- add support for dumpting timestamp records to timeline test suite;
- dump timestamp records for TimeStamp tests;

* inspector/timeline/timeline-test.js:
(initialize_Timeline.InspectorTest.stopTimeline):
(initialize_Timeline.InspectorTest.performActionsAndPrint.step3):
(initialize_Timeline.InspectorTest.performActionsAndPrint):
(initialize_Timeline.InspectorTest.printTimelineRecords):
(initialize_Timeline.InspectorTest.printTimestampRecords):
(initialize_Timeline.InspectorTest.innerPrintTimelineRecords):
* inspector/timeline/timeline-time-stamp-expected.txt:
* inspector/timeline/timeline-time-stamp.html:
* platform/chromium/inspector/timeline/timeline-time-stamp-expected.txt: Removed.

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

7 years ago[CSS Regions] region-overflow: break still renders the content that does not fit...
mihnea@adobe.com [Fri, 10 Aug 2012 11:46:01 +0000 (11:46 +0000)]
[CSS Regions] region-overflow: break still renders the content that does not fit in the last region.
https://bugs.webkit.org/show_bug.cgi?id=92996

Reviewed by Julien Chaffraix.

Source/WebCore:

Flow content that follows the last break in the last region, if any, should not be rendered
for the regions with region-overflow: break.
http://www.w3.org/TR/css3-regions/#the-region-overflow-property

Modified the expected result for existing test fast/regions/region-overflow-break.html
to reflect the correct behavior.

* rendering/RenderRegion.cpp:
(WebCore::RenderRegion::regionOversetRect):

LayoutTests:

Modified expected result for original test to match the behavior described in the regions spec.

* fast/regions/region-overflow-break-expected.html:

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

7 years ago[EFL] Gardening of failing tests
commit-queue@webkit.org [Fri, 10 Aug 2012 10:09:52 +0000 (10:09 +0000)]
[EFL] Gardening of failing tests
https://bugs.webkit.org/show_bug.cgi?id=93700

Unreviewed EFL gardening.

Patch by Sudarsana Nagineni <sudarsana.nagineni@linux.intel.com> on 2012-08-10

* platform/efl/Skipped: Test extensions-api.html moved out of
the http directory in r125222.
* platform/efl/TestExpectations: Add failing tests to the Test
Expectations and unskip passing test.

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

7 years agoWeb Inspector: Protocol Extension: Refactor protocol extension for CSS Regions
commit-queue@webkit.org [Fri, 10 Aug 2012 09:58:35 +0000 (09:58 +0000)]
Web Inspector: Protocol Extension: Refactor protocol extension for CSS Regions
https://bugs.webkit.org/show_bug.cgi?id=92089

Patch by Andrei Poenaru <poenaru@adobe.com> on 2012-08-10
Reviewed by Pavel Feldman.

Source/WebCore:

Replaced "WebKitNamedFlowCollection::namedFlowsNames" with "WebKitNamedFlowCollection::namedFlows" to return a Vector of "WebKitNamedFlow"s,
instead of a Vector of Strings.

Added the "Region" type to Inspector.json.
Changed the "NamedFlow" type and the "getNamedFlowCollection" function in Inspector.json.

Modified existing test: inspector/styles/protocol-css-regions-commands.html

* dom/WebKitNamedFlowCollection.cpp:
(WebCore::WebKitNamedFlowCollection::namedFlows):
* dom/WebKitNamedFlowCollection.h:
(WebKitNamedFlowCollection):
* inspector/Inspector.json:
* inspector/InspectorCSSAgent.cpp:
(WebCore::InspectorCSSAgent::getNamedFlowCollection):
(WebCore::InspectorCSSAgent::getFlowByName):
(WebCore::InspectorCSSAgent::buildArrayForRegions):
(WebCore):
(WebCore::InspectorCSSAgent::buildObjectForNamedFlow):
* inspector/InspectorCSSAgent.h:
(InspectorCSSAgent):
* inspector/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::pushNodeToFrontend):
(WebCore):
* inspector/InspectorDOMAgent.h:
(InspectorDOMAgent):
* inspector/front-end/CSSStyleModel.js:
(WebInspector.CSSStyleModel.prototype.getNamedFlowCollectionAsync):
(WebInspector.NamedFlow):
(WebInspector.NamedFlow.parsePayloadArray):

LayoutTests:

Changed the test to validate the changes made to the protocol.

* inspector/styles/protocol-css-regions-commands-expected.txt:
* inspector/styles/protocol-css-regions-commands.html:

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