WebKit-https.git
8 years ago[GTK] Combine WebKit API tests into fewer binaries
mrobinson@webkit.org [Thu, 21 Jun 2012 18:01:58 +0000 (18:01 +0000)]
[GTK] Combine WebKit API tests into fewer binaries
https://bugs.webkit.org/show_bug.cgi?id=88458

Reviewed by Carlos Garcia Campos.

Instead of creating one binary per-test file, create binaries for each
category of tests. Right now this includes WTF and the WebKit2 C API,
but later tests can be added for the GTK+ platform layer and the WebKit1
and WebKit2 API layers.

* TestWebKitAPI/GNUmakefile.am: Compile only two test binaries, one for the WebKit2
  C API and one for WTF. Refresh the source list to ensure that new test are active.
* gtk/run-api-tests: Change the way that tests are skipped by splitting out the
concept of skipping a test and skipping a suite (program) of tests. Test cases are
skipped because of legitimate failures, but entire programs are skipped because of
problems in the harness. As of right now a test program is only skipped if the
accessibility bus cannot be started.
(SkippedTest.__init__): Make the test case a required argument and have one skipped
test case per SkippedTest instance.
(SkippedTest.__str__): Ditto.
(TestRunner): Update the directory list. We only have two gtest binaries now and they are
in one directory. Reformat the test list to make it slightly easier to read.
(TestRunner.__init__): Add the _skipped_test_program member, which handles entire
test programs that are skipped.
(TestRunner._setup_testing_environment): Use the new member.
(TestRunner._test_cases_to_skip): Collect all skipped test cases now instead of just
the first SkippedTest that matches.
(TestRunner._should_run_test_program): Take a look at the new member to make this
decision.
(TestRunner._run_test_command): Use the name test_program instead of test
to disambiguate between test cases and test suites.
(TestRunner._run_test_glib): ditto.
(TestRunner._run_test_google): Ditto.
(TestRunner._run_test): Ditto.
(TestRunner.run_tests): Ditto.

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

8 years ago[CSSRegions]Change WEBKIT_REGION_RULE value to 16
commit-queue@webkit.org [Thu, 21 Jun 2012 17:53:54 +0000 (17:53 +0000)]
[CSSRegions]Change WEBKIT_REGION_RULE value to 16
https://bugs.webkit.org/show_bug.cgi?id=89421

Patch by Andrei Onea <onea@adobe.com> on 2012-06-21
Reviewed by Tony Chang.

Source/WebCore:

Modified WEBKIT_REGION_RULE where applicable to match CSS Regions spec.
The new value for WEBKIT_REGION_RULE is 16 (was 10).

* css/CSSRule.cpp:
(WebCore):
Added COMPILE_ASSERT to ensure StyleRule::Region and CSSRule::WEBKIT_REGION_RULE will
* css/CSSRule.h:
(CSSRule):
Modified m_type bitfield length to 5
* css/CSSRule.idl:
* css/StyleRule.cpp:
(SameSizeAsStyleRuleBase):
(WebCore):
Added COMPILE_ASSERT to ensure that StyleRuleBase will always have exactly 32bits.
* css/StyleRule.h:
(StyleRuleBase):
Modified m_type bitfield to 5 to accommodate the new value, and modified
m_sourceLine bitfield to 27 bits in order to keep StyleRule 32
bits long. Consequently, any css rule longer than 67,108,863 lines will
cause overflow - however, the value is large enough not to cause
problems.

LayoutTests:

Added check for exact value of WEBKIT_REGION_RULE which should be 16,
according to CSS Regions spec.

* fast/regions/webkit-region-rule-expected.txt:
* fast/regions/webkit-region-rule.html:

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

8 years agoUnreviewed. Moving myself from committer list to reviewer.
yong.li@torchmobile.com [Thu, 21 Jun 2012 17:50:34 +0000 (17:50 +0000)]
Unreviewed. Moving myself from committer list to reviewer.

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

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

8 years agomake sure headers are included only once per file
commit-queue@webkit.org [Thu, 21 Jun 2012 17:34:26 +0000 (17:34 +0000)]
make sure headers are included only once per file
https://bugs.webkit.org/show_bug.cgi?id=88922

Patch by Arnaud Renevier <arno@renevier.net> on 2012-06-21
Reviewed by Alexey Proskuryakov.

* bytecode/CodeBlock.h:
* heap/MachineStackMarker.cpp:
* runtime/JSVariableObject.h:

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

8 years agor120835: fast/box-decoration-break/box-decoration-break-rendering.html failing on...
jonlee@apple.com [Thu, 21 Jun 2012 17:34:23 +0000 (17:34 +0000)]
r120835: fast/box-decoration-break/box-decoration-break-rendering.html failing on mac bots
https://bugs.webkit.org/show_bug.cgi?id=89620

* platform/mac/Skipped:

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

8 years agoPaint played and buffered ranges differently in Chrome video controls.
commit-queue@webkit.org [Thu, 21 Jun 2012 17:32:05 +0000 (17:32 +0000)]
Paint played and buffered ranges differently in Chrome video controls.
https://bugs.webkit.org/show_bug.cgi?id=89284

Patch by Silvia Pfeiffer <silviapf@chromium.org> on 2012-06-21
Reviewed by Eric Carlson.

Source/WebCore:

No new tests; existing video control tests cover this case.

The Chrome video controls are receiving a visual update. This patch changes
the format in which the playback position slider displays the buffered range.
It is painted in a lighter color left of the position thumb and darker right
of the position thumb

* css/mediaControlsChromium.css:
(input[type="range"]::-webkit-media-slider-container):
Adjust the border color of the playback position slider.
* rendering/RenderMediaControlsChromium.cpp:
(WebCore::paintRoundedSliderBackground):
Adjust the background color of the position slider.
(WebCore::paintSliderRangeHighlight):
Make the color of the range region a function parameter,
provide start and end position as pixel width instead of percentage,
and make sure the rounded corners at beginning and end don't turn into rectangles.
(WebCore):
Move the mediaSliderThumbWidth variable up to be used in paintMediaSlider().
(WebCore::paintMediaSlider):
Calculate start, current and end position instead of fractions,
adjust the current position by half the thumb's width for improved rendering,
and draw two highlight areas: one bright one before current position and
one grey one after current position.
(WebCore::paintMediaVolumeSlider):
Adjust the paintSliderRangeHighlight function call and add the colors.

LayoutTests:

Rebaseline tests for linux build; mark others in TestExpectations.

* platform/chromium/TestExpectations:
* platform/chromium-linux/fast/layers/video-layer-expected.png:
* platform/chromium-linux/fullscreen/full-screen-stacking-context-expected.png:
* platform/chromium-linux/http/tests/media/video-buffered-range-contains-currentTime-expected.png:
* platform/chromium-linux/media/audio-controls-rendering-expected.png:
* platform/chromium-linux/media/controls-after-reload-expected.png:
* platform/chromium-linux/media/controls-strict-expected.png:
* platform/chromium-linux/media/controls-styling-expected.png:
* platform/chromium-linux/media/controls-without-preload-expected.png:
* platform/chromium-linux/media/video-controls-rendering-expected.png:
* platform/chromium-linux/media/video-display-toggle-expected.png:
* platform/chromium-linux/media/video-playing-and-pause-expected.png:
* platform/chromium-linux/media/video-zoom-controls-expected.png:
* platform/chromium-linux/media/audio-repaint-expected.png:
* platform/chromium-linux/media/controls-layout-direction-expected.png:
* platform/chromium-linux/media/media-controls-clone-expected.png:
* platform/chromium-linux/media/media-document-audio-repaint-expected.png:
* platform/chromium-linux/media/video-no-audio-expected.png:
* platform/chromium-win/fast/layers/video-layer-expected.txt:
* platform/chromium-win/media/audio-controls-rendering-expected.txt:
* platform/chromium-win/media/audio-repaint-expected.txt:
* platform/chromium-win/media/controls-after-reload-expected.txt:
* platform/chromium-win/media/controls-strict-expected.txt:
* platform/chromium-win/media/controls-styling-expected.txt:
* platform/chromium-win/media/controls-without-preload-expected.txt:
* platform/chromium-win/media/media-controls-clone-expected.txt:
* platform/chromium-win/media/media-document-audio-repaint-expected.txt:
* platform/chromium-win/media/video-controls-rendering-expected.txt:
* platform/chromium-win/media/video-display-toggle-expected.txt:
* platform/chromium-win/media/video-no-audio-expected.txt:
* platform/chromium-win/media/video-playing-and-pause-expected.txt:
* platform/chromium-win/media/video-zoom-controls-expected.txt:

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

8 years agoRemove unused static variable uninitializedLineNumberValue.
commit-queue@webkit.org [Thu, 21 Jun 2012 17:28:10 +0000 (17:28 +0000)]
Remove unused static variable uninitializedLineNumberValue.
https://bugs.webkit.org/show_bug.cgi?id=89643

Patch by Kwang Yul Seo <skyul@company100.net> on 2012-06-21
Reviewed by Alexey Proskuryakov.

No behavioral changes.

* html/parser/HTMLTreeBuilder.cpp:
(WebCore):

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

8 years ago[GTK] Add a new webkit2 tests slave bot
sergio@webkit.org [Thu, 21 Jun 2012 17:25:59 +0000 (17:25 +0000)]
[GTK] Add a new webkit2 tests slave bot
https://bugs.webkit.org/show_bug.cgi?id=89336

Reviewed by Philippe Normand.

Slave configuration for a new GTK bot that will run WebKit2 tests.

* BuildSlaveSupport/build.webkit.org-config/config.json:

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

8 years agoRemove unused static function skipComment.
commit-queue@webkit.org [Thu, 21 Jun 2012 17:21:44 +0000 (17:21 +0000)]
Remove unused static function skipComment.
https://bugs.webkit.org/show_bug.cgi?id=89641

Patch by Kwang Yul Seo <skyul@company100.net> on 2012-06-21
Reviewed by Alexey Proskuryakov.

No behavioral changes.

* loader/TextResourceDecoder.cpp:

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

8 years agoRemove two more member variables found by clang's Wunused-private-field
thakis@chromium.org [Thu, 21 Jun 2012 17:19:15 +0000 (17:19 +0000)]
Remove two more member variables found by clang's Wunused-private-field
https://bugs.webkit.org/show_bug.cgi?id=89672

Reviewed by Anders Carlsson.

* html/shadow/MediaControlRootElementChromium.h:
(MediaControlRootElementChromium):
* platform/graphics/filters/FECustomFilter.cpp:
(WebCore::FECustomFilter::FECustomFilter):
* platform/graphics/filters/FECustomFilter.h:
(FECustomFilter):

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

8 years agoNon-fixed length margins don't work with align=center
jchaffraix@webkit.org [Thu, 21 Jun 2012 17:15:18 +0000 (17:15 +0000)]
Non-fixed length margins don't work with align=center
https://bugs.webkit.org/show_bug.cgi?id=89626

Reviewed by Levi Weintraub.

Source/WebCore:

Tests: fast/block/negative-start-margin-align-center-percent.html
       fast/block/positive-margin-block-child-align-center-calc.html

Calling Length::value() is a bad idea as it returns the *raw* value of
the length. For percent and calculated length this is a bad idea as they
bear not relation to the actual computed length.

* rendering/RenderBox.cpp:
(WebCore::RenderBox::computeInlineDirectionMargins):
Fixed the code to use minimumValueForLength as this nicely takes care of the 'auto' case.

LayoutTests:

* fast/block/negative-start-margin-align-center-percent-expected.html: Added.
* fast/block/negative-start-margin-align-center-percent.html: Added.
* fast/block/positive-margin-block-child-align-center-calc-expected.html: Added.
* fast/block/positive-margin-block-child-align-center-calc.html: Added.

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

8 years ago[chromium] style improvement for setDeviceScaleFactor code
rjkroege@chromium.org [Thu, 21 Jun 2012 17:13:01 +0000 (17:13 +0000)]
[chromium] style improvement for setDeviceScaleFactor code
https://bugs.webkit.org/show_bug.cgi?id=89665

Correct a coding style error committed in https://bugs.webkit.org/show_bug.cgi?id=88916

Reviewed by Adrienne Walker.

Purely code hygiene: existing tests suffice.

* platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
(WebCore::CCLayerTreeHostImpl::setDeviceScaleFactor):

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

8 years ago[GTK] Update TestExpectations
commit-queue@webkit.org [Thu, 21 Jun 2012 17:07:51 +0000 (17:07 +0000)]
[GTK] Update TestExpectations
https://bugs.webkit.org/show_bug.cgi?id=89664

Unreviewed gardening. Mark editing/deleting/delete-3800834-fix.html
as flaky.

Patch by Simon Pena <spena@igalia.com> on 2012-06-21

* platform/gtk/TestExpectations:

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

8 years ago[Crash][Editing] Pressing enter on LI element triggers assertion in Shadow DOM.
shinyak@chromium.org [Thu, 21 Jun 2012 17:05:12 +0000 (17:05 +0000)]
[Crash][Editing] Pressing enter on LI element triggers assertion in Shadow DOM.
https://bugs.webkit.org/show_bug.cgi?id=89171

Reviewed by Ryosuke Niwa.

Source/WebCore:

Since modidying Shadow DOM removes renderer of elements in Shadow DOM and shadow host,
assertion to check the existence of renderer was triggered.

We should update layout here to create renderer again.

Test: editing/shadow/pressing-enter-on-list.html

* editing/CompositeEditCommand.cpp:
(WebCore::CompositeEditCommand::appendBlockPlaceholder):

LayoutTests:

* editing/shadow/pressing-enter-on-list-expected.txt: Added.
* editing/shadow/pressing-enter-on-list.html: Added.

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

8 years agoDeviceOrientation and DeviceMotion Test Cleanup
commit-queue@webkit.org [Thu, 21 Jun 2012 17:03:28 +0000 (17:03 +0000)]
DeviceOrientation and DeviceMotion Test Cleanup
https://bugs.webkit.org/show_bug.cgi?id=89662

Patch by Amy Ousterhout <aousterh@chromium.org> on 2012-06-21
Reviewed by Ryosuke Niwa.

Replaces 'LayoutTestController' with 'TestRunner' in debug messages.
This makes it consistent with testRunner, which replaced layoutTestController.

* fast/dom/DeviceMotion/script-tests/no-page-cache.js:
* fast/dom/DeviceOrientation/script-tests/add-listener-from-callback.js:
* fast/dom/DeviceOrientation/script-tests/basic-operation.js:
* fast/dom/DeviceOrientation/script-tests/event-after-navigation.js:
* fast/dom/DeviceOrientation/script-tests/multiple-frames.js:
* fast/dom/DeviceOrientation/script-tests/no-page-cache.js:
* fast/dom/DeviceOrientation/script-tests/no-synchronous-events.js:
* fast/dom/DeviceOrientation/script-tests/null-values.js:
(setMockOrientation):
* fast/dom/DeviceOrientation/script-tests/updates.js:
(setMockOrientation):

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

8 years agoWeb Inspector: [WebGL] Add injected WebGL module class
commit-queue@webkit.org [Thu, 21 Jun 2012 16:53:57 +0000 (16:53 +0000)]
Web Inspector: [WebGL] Add injected WebGL module class
https://bugs.webkit.org/show_bug.cgi?id=89592

Patch by Andrey Adaikin <aandrey@chromium.org> on 2012-06-21
Reviewed by Pavel Feldman.

Adding a new InjectedScriptWebGLModule class and moving WebGL-related
stuff out of InjectedScriptManager class.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.gypi:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.xcodeproj/project.pbxproj:
* inspector/InjectedScriptManager.cpp:
* inspector/InjectedScriptManager.h:
(InjectedScriptManager):
* inspector/InjectedScriptModule.cpp:
(WebCore::InjectedScriptModule::ensureInjected):
* inspector/InjectedScriptModule.h:
(InjectedScriptModule):
* inspector/InjectedScriptWebGLModule.cpp: Copied from Source/WebCore/inspector/InjectedScriptModule.cpp.
(WebCore):
(WebCore::InjectedScriptWebGLModule::InjectedScriptWebGLModule):
(WebCore::InjectedScriptWebGLModule::moduleForState):
(WebCore::InjectedScriptWebGLModule::source):
(WebCore::InjectedScriptWebGLModule::wrapWebGLContext):
(WebCore::InjectedScriptWebGLModule::captureFrame):
* inspector/InjectedScriptWebGLModule.h: Copied from Source/WebCore/inspector/InjectedScriptModule.h.
(WebCore):
(InjectedScriptWebGLModule):
* inspector/InspectorWebGLAgent.cpp:
(WebCore::InspectorWebGLAgent::wrapWebGLRenderingContextForInstrumentation):

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

8 years agoWeb Inspector: do not add separator to the end of the context menu.
pfeldman@chromium.org [Thu, 21 Jun 2012 16:34:36 +0000 (16:34 +0000)]
Web Inspector: do not add separator to the end of the context menu.
https://bugs.webkit.org/show_bug.cgi?id=89634

Reviewed by Vsevolod Vlasov.

Attaching separators only before menu items now.

* inspector/front-end/ContextMenu.js:
(WebInspector.ContextSubMenuItem.prototype.appendItem):
(WebInspector.ContextSubMenuItem.prototype.appendSubMenuItem):
(WebInspector.ContextSubMenuItem.prototype.appendCheckboxItem):
(WebInspector.ContextSubMenuItem.prototype.appendSeparator):
(WebInspector.ContextSubMenuItem.prototype._pushItem):

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

8 years ago[EFL][WK2] Make WebKit2/Efl headers and resources installable.
commit-queue@webkit.org [Thu, 21 Jun 2012 15:46:40 +0000 (15:46 +0000)]
[EFL][WK2] Make WebKit2/Efl headers and resources installable.
https://bugs.webkit.org/show_bug.cgi?id=88207

Patch by Ryuan Choi <ryuan.choi@gmail.com> on 2012-06-21
Reviewed by Chang Shu.

.:

* Source/cmake/OptionsCommon.cmake:
Provide new variable, EXEC_INSTALL_DIR to determine where to install
executables.

Source/JavaScriptCore:

* shell/CMakeLists.txt: Use ${EXEC_INSTALL_DIR} instead of hardcoding "bin"

Source/WebKit2:

* CMakeLists.txt: Install WebProcess.
* PlatformEfl.cmake: Generate ewebkit2.pc and install it.
* efl/ewebkit2.pc.in: Added.

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

8 years agoWeb Inspector: Unify FileSystem callbacks
commit-queue@webkit.org [Thu, 21 Jun 2012 15:28:10 +0000 (15:28 +0000)]
Web Inspector: Unify FileSystem callbacks
https://bugs.webkit.org/show_bug.cgi?id=89420

Patch by Taiju Tsuiki <tzik@chromium.org> on 2012-06-21
Reviewed by Vsevolod Vlasov.

* inspector/InspectorFileSystemAgent.cpp:
(WebCore):

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

8 years ago[EFL[WK2] Add WKViewEfl and WebKit2 API Object to represent Evas_Object.
ryuan.choi@samsung.com [Thu, 21 Jun 2012 15:11:48 +0000 (15:11 +0000)]
[EFL[WK2] Add WKViewEfl and WebKit2 API Object to represent Evas_Object.
https://bugs.webkit.org/show_bug.cgi?id=88935

Reviewed by Chang Shu.

.:

* Source/cmake/OptionsEfl.cmake: Defines BUILDING_EFL__.

Source/WebKit2:

Add WKViewEfl to support WTR/Efl.

* PlatformEfl.cmake:
* Shared/API/c/WKBase.h:
* Shared/API/c/efl/WKBaseEfl.h: Added.
* UIProcess/API/C/WKAPICast.h:
* UIProcess/API/C/efl/WKAPICastEfl.h: Added.
(WebKit):
* UIProcess/API/C/efl/WKView.cpp: Added.
(WKViewCreate):
(WKViewGetPage):
* UIProcess/API/C/efl/WKView.h: Added.
* UIProcess/API/efl/ewk_view.cpp:
(ewk_view_page_get):
* UIProcess/API/efl/ewk_view_private.h:

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

8 years ago[Qt] Unreviewed gardening, unskip now passing tests.
ossy@webkit.org [Thu, 21 Jun 2012 14:45:13 +0000 (14:45 +0000)]
[Qt] Unreviewed gardening, unskip now passing tests.

* platform/qt/Skipped:
* platform/qt/editing/inserting/4960120-1-expected.png: Added.
* platform/qt/editing/inserting/4960120-1-expected.txt:
* platform/qt/editing/inserting/before-after-input-element-expected.png: Added.
* platform/qt/editing/inserting/before-after-input-element-expected.txt:
* platform/qt/editing/inserting/insert-text-with-newlines-expected.png: Added.
* platform/qt/editing/inserting/insert-text-with-newlines-expected.txt:
* platform/qt/http/tests/misc/favicon-as-image-expected.png: Added.
* platform/qt/http/tests/misc/favicon-as-image-expected.txt: Added.

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

8 years ago[BlackBerry] Input mode should adapt automatically to settings changes
mifenton@rim.com [Thu, 21 Jun 2012 13:39:45 +0000 (13:39 +0000)]
[BlackBerry] Input mode should adapt automatically to settings changes
https://bugs.webkit.org/show_bug.cgi?id=89595

Reviewed by Antonio Gomes.

PR 167540.

Add helper function to check if input is enabled so that
the override settings can be applied at any time.

Reviewed Internally by Gen Mak.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::setLoadState):
(BlackBerry::WebKit::WebPagePrivate::handleMouseEvent):
* WebKitSupport/InputHandler.cpp:
(BlackBerry::WebKit::InputHandler::isInputModeEnabled):
(BlackBerry::WebKit::InputHandler::setInputModeEnabled):
(BlackBerry::WebKit::InputHandler::setElementFocused):
(BlackBerry::WebKit::InputHandler::ensureFocusTextElementVisible):
(BlackBerry::WebKit::InputHandler::notifyClientOfKeyboardVisibilityChange):
(BlackBerry::WebKit::InputHandler::handleKeyboardInput):
(BlackBerry::WebKit::InputHandler::setComposingText):
* WebKitSupport/InputHandler.h:
* WebKitSupport/TouchEventHandler.cpp:
(BlackBerry::WebKit::TouchEventHandler::handleTouchPoint):

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

8 years agoCompile error: 'bool std::isinf(float)' is not 'constexpr' with GCC 4.6 in C++11...
kbalazs@webkit.org [Thu, 21 Jun 2012 13:26:42 +0000 (13:26 +0000)]
Compile error: 'bool std::isinf(float)' is not 'constexpr' with GCC 4.6 in C++11 mode
https://bugs.webkit.org/show_bug.cgi?id=88721

Reviewed by Csaba Osztrogon√°c.

Don't define these as consexpr because with gcc 4.6
they call non constexpr functions.
* wtf/MathExtras.h:
(std::wtf_isinf):
(std::wtf_isnan):

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

8 years ago[Qt] Add a custom Color Chooser widget to MiniBrowser
commit-queue@webkit.org [Thu, 21 Jun 2012 13:12:43 +0000 (13:12 +0000)]
[Qt] Add a custom Color Chooser widget to MiniBrowser
https://bugs.webkit.org/show_bug.cgi?id=87988

Patch by Thiago Marcos P. Santos <thiago.santos@intel.com> on 2012-06-21
Reviewed by Alexis Menard.

Added custom color chooser example for the MiniBrowser.

* MiniBrowser/qt/MiniBrowser.qrc:
* MiniBrowser/qt/qml/BrowserWindow.qml:
* MiniBrowser/qt/qml/ColorChooser.qml: Added.

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

8 years agoRemove the warning "File not found" in MiniBrowser post-build event
commit-queue@webkit.org [Thu, 21 Jun 2012 12:27:54 +0000 (12:27 +0000)]
Remove the warning "File not found" in MiniBrowser post-build event
https://bugs.webkit.org/show_bug.cgi?id=89601

Patch by Vivek Galatage <vivekgalatage@gmail.com> on 2012-06-21
Reviewed by Adam Roben.

* MiniBrowser/MiniBrowserPostBuild.cmd:

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

8 years ago[GTK] Add new baseline and update TestExpectations
commit-queue@webkit.org [Thu, 21 Jun 2012 12:14:34 +0000 (12:14 +0000)]
[GTK] Add new baseline and update TestExpectations
https://bugs.webkit.org/show_bug.cgi?id=89651

Unreviewed gardening.

Patch by Simon Pena <spena@igalia.com> on 2012-06-21

* platform/gtk/TestExpectations: marked
svg/W3C-SVG-1.1/animate-elem-{32,33,40,41,46}-t.svg as flaky, and
fast/canvas/canvas-createImageData.html as crashing on DEBUG
* platform/gtk/fast/hidpi/device-scale-factor-paint-expected.png: Added.
* platform/gtk/fast/hidpi/device-scale-factor-paint-expected.txt: Added.

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

8 years ago[GTK] Backport run-file-chooser to WebKit1
commit-queue@webkit.org [Thu, 21 Jun 2012 12:08:36 +0000 (12:08 +0000)]
[GTK] Backport run-file-chooser to WebKit1
https://bugs.webkit.org/show_bug.cgi?id=87283

Patch by Daniel Drake <dsd@laptop.org> on 2012-06-21
Reviewed by Gustavo Noronha Silva.

This is a relatively straightforward backport of Mario Sanchez
Prada's WebKit2 run-file-chooser signal work, intended for use by
OLPC and others who are not quite ready to move to WebKit2.

Add a new public class to the API, WebKitFileChooserRequest, to be
emitted along with a new WebKitWebView::run-file-chooser signal to
let client applications to provide their own file chooser dialog
when the use interacts with HTML Input elements of type 'file'.

* GNUmakefile.am: Added new source files and headers.
* webkit/webkitfilechooserrequest.cpp: Added.
(_WebKitFileChooserRequestPrivate):
(webkit_file_chooser_request_init):
(webkit_file_chooser_request_finalize):
(webkit_file_chooser_request_get_property):
(webkit_file_chooser_request_class_init):
(webkit_file_chooser_request_create):
(webkit_file_chooser_request_get_mime_types):
(webkit_file_chooser_request_get_mime_types_filter):
(webkit_file_chooser_request_get_select_multiple):
(webkit_file_chooser_request_select_files):
(webkit_file_chooser_request_get_selected_files):
* webkit/webkitfilechooserrequest.h: Added.
(_WebKitFileChooserRequest):
(_WebKitFileChooserRequestClass):
* webkit/webkitfilechooserrequestprivate.h: Added,
containing the prototype of webkit_file_chooser_request_create.

Provide private API to make a file chooser request from the
WebView, and provide a default handler for it.

* webkit/webkitwebview.cpp:
(fileChooserDialogResponseCallback): Handler for the 'response'
signal for the GtkFileChooserDialog used in the default
handler. It will call to webkit_file_chooser_request_select_files
or webkit_file_chooser_request_cancel as needed.
(webkitWebViewRealRunFileChooser): Default handler for the new
'run-file-chooser' signal. It will create a GtkFileChooserDialog,
connect to the 'response' signal and show it.
(webkit_web_view_class_init): Connect the 'run-file-chooser'
signal to the default handler, webkitWebViewRunFileChooser.
(webkit_web_view_new):
(webkitWebViewRunFileChooserRequest):
* webkit/webkitwebview.h:
(_WebKitWebViewClass): Added prototype for the handler of the new
'run-file-chooser' signal.
* webkit/webkitwebviewprivate.h: Added prototype for
private new function webkitWebViewRunFileChooserRequest.

Update runOpenPanel to use the new API, including a default handler
with similar behaviour to before.

* WebCoreSupport/ChromeClientGtk.cpp:
(WebKit::ChromeClient::runOpenPanel): Now creates an instance of
WebKitFileChooserRequest and asks the WebView to emit the
new 'run-file-chooser' signal with it.

Added the new public header to the main header.

* webkit/webkit.h: Added webkitfilechooserrequest.h

New unit tests for the new WebKitFileChooserRequest API.

* tests/testwebview.c: Various WebKitFileChooserRequest tests,
including MIME type filtering and selection handling.

Updated documentation related files with the new API.

* docs/webkitgtk-docs.sgml: Added new section.
* docs/webkitgtk-sections.txt: Added new API.
* docs/webkitgtk.types: Added get_type function.

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

8 years ago[Qt] DRT in standalone mode hangs after the first test
kbalazs@webkit.org [Thu, 21 Jun 2012 12:01:39 +0000 (12:01 +0000)]
[Qt] DRT in standalone mode hangs after the first test
https://bugs.webkit.org/show_bug.cgi?id=89613

Reviewed by Csaba Osztrogon√°c.

Break an inline signal slot chain that ends up in setting
LayoutTestController::m_hasDumped too early. In LayoutTestController::maybeDump()
we emit done() which starts the chain that finishes in DumpRenderTree::open().
The next line in maybeDump sets m_hasDumped to true. We could simply reorder
these two lines but it seems to be wrong in general to start the next load
from this call chain. The server mode (when DRT is runned by the test harness)
also uses a queued connection to read the next test from stdin.

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

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

8 years ago[Qt] API tests for ColorChooser
commit-queue@webkit.org [Thu, 21 Jun 2012 11:38:06 +0000 (11:38 +0000)]
[Qt] API tests for ColorChooser
https://bugs.webkit.org/show_bug.cgi?id=88101

Patch by Thiago Marcos P. Santos <thiago.santos@intel.com> on 2012-06-21
Reviewed by Kenneth Rohde Christiansen.

The test uses the value sanitization to detect if the feature is
enabled or disabled and will just pass when disabled.

* UIProcess/API/qt/tests/qmltests/WebView/tst_colorChooser.qml: Added.
* UIProcess/API/qt/tests/qmltests/common/colorChooser.html: Added.

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

8 years ago[WK2][Qt] Color chooser API missing
commit-queue@webkit.org [Thu, 21 Jun 2012 10:58:53 +0000 (10:58 +0000)]
[WK2][Qt] Color chooser API missing
https://bugs.webkit.org/show_bug.cgi?id=87749

Patch by Thiago Marcos P. Santos <thiago.santos@intel.com> on 2012-06-21
Reviewed by Kenneth Rohde Christiansen.

Source/WebKit/qt:

Added ColorChooser API stub to WebKit. Otherwise
it will break the build for Qt WebKit2 (that now has
complete support for color chooser) when INPUT_TYPE_COLOR is set.

* WebCoreSupport/ChromeClientQt.cpp:
(WebCore):
(WebCore::ChromeClientQt::createColorChooser):
* WebCoreSupport/ChromeClientQt.h:
(ChromeClientQt):

Source/WebKit2:

Added public experimental API for ColorChooser. This will
allow the browser to define a custom dialog for selecting
color when a input field of type "color" get focus.

The current implementation gives a model to the QML Component
that has methods for canceling a request, selecting a color
and fetching what is the current value of the HTML input.

* Target.pri:
* UIProcess/API/qt/qquickwebview.cpp:
(QQuickWebViewPrivate::QQuickWebViewPrivate):
(QQuickWebViewExperimental::colorChooser):
(QQuickWebViewExperimental::setColorChooser):
* UIProcess/API/qt/qquickwebview_p.h:
* UIProcess/API/qt/qquickwebview_p_p.h:
(QQuickWebViewPrivate):
* UIProcess/qt/QtPageClient.cpp:
(WebKit::QtPageClient::createColorChooserProxy):
* UIProcess/qt/WebColorChooserProxyQt.cpp: Added.
(WebKit):
(ColorChooserContextObject):
(WebKit::ColorChooserContextObject::ColorChooserContextObject):
(WebKit::ColorChooserContextObject::currentColor):
(WebKit::ColorChooserContextObject::accept):
(WebKit::ColorChooserContextObject::reject):
(WebKit::WebColorChooserProxyQt::WebColorChooserProxyQt):
(WebKit::WebColorChooserProxyQt::~WebColorChooserProxyQt):
(WebKit::WebColorChooserProxyQt::createItem):
(WebKit::WebColorChooserProxyQt::createContext):
(WebKit::WebColorChooserProxyQt::setSelectedColor):
(WebKit::WebColorChooserProxyQt::notifyColorSelected):
(WebKit::WebColorChooserProxyQt::endChooser):
* UIProcess/qt/WebColorChooserProxyQt.h: Added.
(WebCore):
(WebKit):
(WebColorChooserProxyQt):
(WebKit::WebColorChooserProxyQt::create):

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

8 years ago[Qt] Unreviewed gardening, skip a new failing test.
ossy@webkit.org [Thu, 21 Jun 2012 10:24:32 +0000 (10:24 +0000)]
[Qt] Unreviewed gardening, skip a new failing test.

* platform/qt-5.0-wk2/Skipped:

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

8 years agoSpeech JavaScript API: SpeechRecognition should hook up with ActiveDOMObject more
hans@chromium.org [Thu, 21 Jun 2012 10:23:15 +0000 (10:23 +0000)]
Speech JavaScript API: SpeechRecognition should hook up with ActiveDOMObject more
https://bugs.webkit.org/show_bug.cgi?id=89217

Reviewed by Adam Barth.

Source/WebCore:

Previously, the SpeechRecognition was kept alive while waiting for
pending events by making the embedder hold a reference to the object.
We should do this by using ActiveDOMObject's setPendingActivity() instead.

Also, override ActiveDOMObject::stop() to get notified when the user
leaves the page.

Test: fast/speech/scripted/navigate-away.html

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

Tools:

Add a method for checking whether the mock speech
recognition was aborted.

Also redo the way the mock posts tasks. Instead of posting them all at once,
maintain an internal queue of task objects, and call postTask() for them
once at the time. This means that for example when the page is navigated
away and abort() is called, that call doesn't end up after a bunch
of previously posted events on the event loop.

* DumpRenderTree/chromium/LayoutTestController.cpp:
(LayoutTestController::LayoutTestController):
(LayoutTestController::wasMockSpeechRecognitionAborted):
* DumpRenderTree/chromium/LayoutTestController.h:
(LayoutTestController):
* DumpRenderTree/chromium/MockWebSpeechRecognizer.cpp:
(WebKit::ClientCallTask::ClientCallTask):
(WebKit::ResultTask::ResultTask):
(WebKit::NoMatchTask::NoMatchTask):
(WebKit::ErrorTask::ErrorTask):
(MockWebSpeechRecognizer::start):
(MockWebSpeechRecognizer::abort):
(MockWebSpeechRecognizer::setError):
(MockWebSpeechRecognizer::MockWebSpeechRecognizer):
(MockWebSpeechRecognizer::startTaskQueue):
(MockWebSpeechRecognizer::StepTask::runIfValid):
* DumpRenderTree/chromium/MockWebSpeechRecognizer.h:
(MockWebSpeechRecognizer::hasBeenAborted):
(MockWebSpeechRecognizer):
(MockWebSpeechRecognizer::taskList):
(Task):
(MockWebSpeechRecognizer::Task::Task):
(MockWebSpeechRecognizer::Task::~Task):
(StepTask):
(MockWebSpeechRecognizer::StepTask::StepTask):

LayoutTests:

Add a layout test to check that speech recognition gets aborted when
navigating away from the page.

* fast/speech/scripted/navigate-away-expected.txt: Added.
* fast/speech/scripted/navigate-away-iframe-expected.txt: Added.
* fast/speech/scripted/navigate-away-iframe.html: Added.
* fast/speech/scripted/navigate-away.html: Added.

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

8 years ago[EFL] Gardening after r120847
commit-queue@webkit.org [Thu, 21 Jun 2012 10:06:23 +0000 (10:06 +0000)]
[EFL] Gardening after r120847
https://bugs.webkit.org/show_bug.cgi?id=89640

Unreviewed gardening. Newly added compositing/backface-visibility/backface-visibility-webgl.html
test does not pass on EFL port due to missing WebGL support.

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

* platform/efl/TestExpectations:

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

8 years ago[GTK] Add support for window.showModalDialog in WebKit2GTK+
mario@webkit.org [Thu, 21 Jun 2012 08:07:56 +0000 (08:07 +0000)]
[GTK] Add support for window.showModalDialog in WebKit2GTK+
https://bugs.webkit.org/show_bug.cgi?id=79500

Reviewed by Carlos Garcia Campos.

Source/WebKit2:

Implement runModal in WebKitUIClient to make the WebKitWebView
emit a 'run-as-modal' signal when requested, creating a new
mainloop there to block user interaction with the original window
while the modal dialog is showing.

* UIProcess/API/gtk/WebKitUIClient.cpp:
(runModal): Call to the new webkitWebViewRunAsModalPage function.
(attachUIClientToView): Add runModal.
* UIProcess/API/gtk/WebKitWebView.cpp:
(_WebKitWebViewPrivate): Add an atribute for a new main loop.
(webkitWebViewFinalize): Make sure the main loop for main dialogs,
if any, is stopped if it was still running.
(webkit_web_view_class_init): Declare new signal 'run-as-modal'.
(webkitWebViewRunAsModal): Emit the 'run-as-modal' signal and, if
handled, create and run a new main loop.
* UIProcess/API/gtk/WebKitWebView.h:
(_WebKitWebViewClass): New handler for the 'run-as-modal' signal.
* UIProcess/API/gtk/WebKitWebViewPrivate.h: Add webkitWebViewRunAsModalPage.

Allow setting and getting the value of WebPage's canRunModal
attribute in the WebProcess from the UIProcess after the creation
of a WebPage, to allow using it from WebKitWebView to allow the
client application to decide whether to allow create modal
dialogs, which would result in launching an additional nested
event loop in the web process, after creating the dialog.

* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::WebPageProxy): Initialize the new
m_canRunModal attribute, to cache the current status of the
WebPage in the WebProcess.
(WebKit::WebPageProxy::initializeUIClient): Call the new function
setCanRunModal, instead of manually sending the SetCanRunModal message.
(WebKit::WebPageProxy::creationParameters): Use m_canRunModal
instead of m_uiClient.canRunModal when preparing the parameters.
(WebKit::WebPageProxy::setCanRunModal): New public function, it
sets the value of m_canRunModal and sends a message to the Web
process for updating the WebPage, whenever possible.
(WebKit::WebPageProxy::canRunModal): New public function, returns
the value of the m_canRunModal attribute.
* UIProcess/WebPageProxy.h:
(WebPageProxy): Added new public functions and private attribute.

New property in WebKitSettings to be able to decide whether it is
allowed to create and run new child webviews as modal dialogs.

* UIProcess/API/gtk/WebKitSettings.cpp:
(_WebKitSettingsPrivate): New attribute allowModalDialogs.
(webKitSettingsSetProperty): Handle the new property.
(webKitSettingsGetProperty): Ditto.
(webkit_settings_class_init): Install the new property.
(webkitSettingsAttachSettingsToPage): Make sure the WebPage is
initialized with the value of the new property.
(webkit_settings_set_allow_modal_dialogs): New setter.
(webkit_settings_get_allow_modal_dialogs): New getter.
* UIProcess/API/gtk/WebKitSettings.h:
* UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Added new accessors.

Connect to the 'notify::allow-modal-dialogs' signal from
WebKitSettings to ensure that canRunModal property of the WebPage
is kept up to date. Ensure that signal handlers for monitoring
settings are disconnected when the webview is finalized.

* UIProcess/API/gtk/WebKitWebView.cpp:
(webkitWebViewSetSettings): Connect to the new signal
'notify::allow-modal-dialogs', from WebKitSettings.
(allowModalDialogsChanged): Callback to update WebPage's
canRunModal property when updated through WebKitSettings.
(webkitWebViewDisconnectSettingsSignalHandlers): Disconnect signal
handlers for monitoring WebKitSettings properties.
(webkitWebViewFinalize): Ensure signal handlers are disconnected.
(webkit_web_view_set_settings): Ditto.
* UIProcess/API/gtk/WebKitWebView.h:

Add new unit tests to check the 'run-as-modal' signal is emitted
only when the new property in WebKitSettings is set to TRUE.

* UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
(testWebViewAllowModalDialogs): New unit test to check that modal
dialogs are properly created from JavaScript when allowed.
(testWebViewDisallowModalDialogs): New unit test to check that
it's not possible to create modal dialogs when not allowed.
(beforeAll): Add the new unit test.

Tools:

Add support for modal dialogs in GTK's MiniBrowser.

* MiniBrowser/gtk/BrowserWindow.c:
(webViewRunAsModal):
(webViewCreate):
(webViewDecidePolicy):
(browser_window_new):
* MiniBrowser/gtk/BrowserWindow.h:
* MiniBrowser/gtk/main.c:
(createBrowserWindow):

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

8 years ago[GTK] accessibility/textbox-role-reports-line-number.html fails
mario@webkit.org [Thu, 21 Jun 2012 07:48:52 +0000 (07:48 +0000)]
[GTK] accessibility/textbox-role-reports-line-number.html fails
https://bugs.webkit.org/show_bug.cgi?id=75785

Reviewed by Chris Fleizach.

Move a Mac specific accessibility test to the platform directory.

* platform/gtk/TestExpectations: Removed test from gtk test expectations.
* platform/mac/accessibility/textbox-role-reports-line-number-expected.txt: Renamed from LayoutTests/accessibility/textbox-role-reports-line-number-expected.txt.
* platform/mac/accessibility/textbox-role-reports-line-number.html: Renamed from LayoutTests/accessibility/textbox-role-reports-line-number.html.
* platform/win/accessibility/textbox-role-reports-line-number-expected.txt: Removed.

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

8 years agoWeb Inspector: Move requestId allocation from FileSystem frontend to backend
commit-queue@webkit.org [Thu, 21 Jun 2012 07:23:48 +0000 (07:23 +0000)]
Web Inspector: Move requestId allocation from FileSystem frontend to backend
https://bugs.webkit.org/show_bug.cgi?id=89555

Patch by Taiju Tsuiki <tzik@chromium.org> on 2012-06-21
Reviewed by Vsevolod Vlasov.

Source/WebCore:

Test: http/tests/inspector/filesystem/get-filesystem-root.html:
      http/tests/inspector/filesystem/read-directory.html:

* inspector/Inspector.json:
* inspector/InspectorFileSystemAgent.cpp:
(WebCore):
(WebCore::InspectorFileSystemAgent::requestFileSystemRoot):
(WebCore::InspectorFileSystemAgent::requestDirectoryContent):
(WebCore::InspectorFileSystemAgent::InspectorFileSystemAgent):
* inspector/InspectorFileSystemAgent.h:
(InspectorFileSystemAgent):
* inspector/front-end/FileSystemModel.js:
(WebInspector.FileSystemModel.prototype._originAdded):
(WebInspector.FileSystemModel.prototype._fileSystemRootReceived):
(WebInspector.FileSystemRequestManager):
(WebInspector.FileSystemRequestManager.prototype.requestFileSystemRoot.requestAccepted):
(WebInspector.FileSystemRequestManager.prototype.requestFileSystemRoot):
(WebInspector.FileSystemRequestManager.prototype._fileSystemRootReceived):
(WebInspector.FileSystemRequestManager.prototype.requestDirectoryContent.requestAccepted):
(WebInspector.FileSystemRequestManager.prototype.requestDirectoryContent):
(WebInspector.FileSystemRequestManager.prototype._directoryContentReceived):
(WebInspector.FileSystemDispatcher.prototype.fileSystemRootReceived):
(WebInspector.FileSystemDispatcher.prototype.directoryContentReceived):

LayoutTests:

* http/tests/inspector/filesystem/filesystem-test.js:
(initialize_FileSystemTest.InspectorTest.dumpReadDirectoryResult):
(initialize_FileSystemTest):
* http/tests/inspector/filesystem/get-filesystem-root.html:
* http/tests/inspector/filesystem/read-directory-expected.txt:
* http/tests/inspector/filesystem/read-directory.html:

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

8 years ago[cairo] improve putByteArray speed by avoiding max/min checks at Color construction.
commit-queue@webkit.org [Thu, 21 Jun 2012 06:08:47 +0000 (06:08 +0000)]
[cairo] improve putByteArray speed by avoiding max/min checks at Color construction.
https://bugs.webkit.org/show_bug.cgi?id=89138

Patch by Arnaud Renevier <arno@renevier.net> on 2012-06-20
Reviewed by Adam Barth.

Color constructor accepts integer arguments and checks if they are
between 0 and 255. In some cases, we already known those numbers to be
within those boundaries. For example when using unsigned chars. So
this patch introduces Color::createUnChecked which return a Color
object without checking for boundaries.

No new tests: no behaviour change

* platform/graphics/Color.cpp:
(WebCore::colorFromPremultipliedARGB):
* platform/graphics/Color.h:
(WebCore::Color::createUnCheked):
(Color):
* platform/graphics/cairo/ImageBufferCairo.cpp:
(WebCore::ImageBuffer::putByteArray):

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

8 years ago[Chromium] Damage tracker is not used without partial swap, causing valid render...
commit-queue@webkit.org [Thu, 21 Jun 2012 05:39:56 +0000 (05:39 +0000)]
[Chromium] Damage tracker is not used without partial swap, causing valid render passes to be removed
https://bugs.webkit.org/show_bug.cgi?id=89589

Patch by Zeev Lieber <zlieber@chromium.org> on 2012-06-20
Reviewed by Adrienne Walker.

Source/WebCore:

When not using partial swap, the CCDamageTracker was not used, and
its m_currentDamageRect was always empty. As a result,
CCLayerTreeHostImpl was thinking no content was changed and was
removing more textures than needed. Fixed this by turning on
CCDamageTracker usage even if not using partial swap, but
overwriting the rootScissorRect with viewport rect if required.

Added unit tests to exercise this scenario.

* platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
(WebCore::CCLayerTreeHostImpl::calculateRenderSurfaceLayerList):

Source/WebKit/chromium:

Added unit tests to check surface texture caching when partial
swap is not used.

* tests/CCLayerTreeHostImplTest.cpp:

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

8 years ago[Forms] Make step action of SpinButtonElement replaceable
yosin@chromium.org [Thu, 21 Jun 2012 05:11:25 +0000 (05:11 +0000)]
[Forms] Make step action of SpinButtonElement replaceable
https://bugs.webkit.org/show_bug.cgi?id=89439

Reviewed by Kent Tamura.

This patch introduces SpinButtonElement::Callback to specify step
action by control clients for using SpinButtonElement by
TextFieldInputType and future version of TimeInputField.

In addition to this improving flexibility of SpinButtonElement, we
free HTMLInputElement from SpinButtonElement dependency on
stepUpFromRenderer.

No new tests. This patch doesn't change behavior.

* html/HTMLInputElement.cpp: Removed stepUpFromRenderer().
* html/HTMLInputElement.h: Removed stepUpFromRenderer().
* html/TextFieldInputType.cpp:
(WebCore::TextFieldInputType::~TextFieldInputType): Added to call SpinButtonElement::removeStepActionHandler.
(WebCore::TextFieldInputType::handleKeydownEventForSpinButton): Changed to call spinButtonStep{Down,Up}
(WebCore::TextFieldInputType::handleWheelEventForSpinButton): Changed to call spinButtonStep{Down,Up}
(WebCore::TextFieldInputType::createShadowSubtree): Added SpinButtonElement::StepActionHandler parameter.
(WebCore::TextFieldInputType::destroyShadowSubtree): Added to call SpinButtonElement::removeStepActionHandler.
(WebCore::TextFieldInputType::spinButtonStepDown): Added for implementation of SpinButtonElement::StepActionHandler.
(WebCore::TextFieldInputType::spinButtonStepUp): Added for implementation of SpinButtonElement::StepActionHandler.
* html/TextFieldInputType.h:
(TextFieldInputType):
* html/shadow/TextControlInnerElements.cpp:
(WebCore::SpinButtonElement::SpinButtonElement): Added StepActionHandler parameter.
(WebCore::SpinButtonElement::defaultEventHandler): Changed to call doStepAction.
(WebCore::SpinButtonElement::doStepAction): Added to call StepActionHandler if possible.
(WebCore::SpinButtonElement::step): Changed to call doStepAction.
* html/shadow/TextControlInnerElements.h:
(StepActionHandler): Added.

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

8 years ago[chromium] Modify CCDamageTracker hash to allow for layer id 0
enne@google.com [Thu, 21 Jun 2012 04:46:05 +0000 (04:46 +0000)]
[chromium] Modify CCDamageTracker hash to allow for layer id 0
https://bugs.webkit.org/show_bug.cgi?id=89631

Reviewed by James Robinson.

HashMap has the bizarre property that 0 is the empty value for integer
keys. Modify the damage tracking HashMap to use negative values for
both the empty and the deleted key traits. Additionally, make sure we
never generate negative layer IDs in practice.

Test: passes webkit_unit_tests with the patch in bug 89589 applied.

* platform/graphics/chromium/LayerChromium.cpp:
(WebCore::LayerChromium::LayerChromium):
* platform/graphics/chromium/cc/CCDamageTracker.h:
(RectMapKeyTraits):
(WebCore::CCDamageTracker::RectMapKeyTraits::emptyValue):
(WebCore::CCDamageTracker::RectMapKeyTraits::constructDeletedValue):
(WebCore::CCDamageTracker::RectMapKeyTraits::isDeletedValue):
(CCDamageTracker):
* platform/graphics/chromium/cc/CCLayerImpl.cpp:
(WebCore::CCLayerImpl::CCLayerImpl):

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

8 years ago[WinCairo] Unreviewed build fix.
bfulgham@webkit.org [Thu, 21 Jun 2012 04:27:18 +0000 (04:27 +0000)]
[WinCairo] Unreviewed build fix.
The wrapper script that launched new- and old-run-webkit-tests
was discarding the --wincairo argument needed to get the proper
test infrastructure to build under WinCairo.

* Scripts/run-webkit-tests: Emulate the Qt, Wx, Chromium, etc.,
behavior to chain the --wincairo flag through to the new build
and test scripts.

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

8 years agoUse Dictionary in MutationObserver.observe to kill custom code
adamk@chromium.org [Thu, 21 Jun 2012 04:18:51 +0000 (04:18 +0000)]
Use Dictionary in MutationObserver.observe to kill custom code
https://bugs.webkit.org/show_bug.cgi?id=89629

Reviewed by Ryosuke Niwa.

Move code for dictionary parsing in MutationObserver.observe
that used to be duplicated (with different implementations)
in JSC and V8 bindings into WebKitMutationObserver.cpp, using
the new Dictionary interface.

No new tests, no change in behavior.

* bindings/js/JSWebKitMutationObserverCustom.cpp:
* bindings/v8/custom/V8WebKitMutationObserverCustom.cpp:
* dom/WebKitMutationObserver.cpp:
(WebCore::WebKitMutationObserver::observe):
* dom/WebKitMutationObserver.h:
(WebCore):
* dom/WebKitMutationObserver.idl:

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

8 years agoUnreviewed, rolling out r120889.
commit-queue@webkit.org [Thu, 21 Jun 2012 02:03:44 +0000 (02:03 +0000)]
Unreviewed, rolling out r120889.
http://trac.webkit.org/changeset/120889
https://bugs.webkit.org/show_bug.cgi?id=89630

[Chromium] webkit_unit_tests didDrawNotCalledOnHiddenLayer
start failing (Requested by ukai on #webkit).

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

Source/WebCore:

* platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
(WebCore::CCLayerTreeHostImpl::calculateRenderSurfaceLayerList):

Source/WebKit/chromium:

* tests/CCLayerTreeHostImplTest.cpp:

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

8 years agoReduced (but did not eliminate) use of "berzerker GC"
ggaren@apple.com [Thu, 21 Jun 2012 02:00:08 +0000 (02:00 +0000)]
Reduced (but did not eliminate) use of "berzerker GC"
https://bugs.webkit.org/show_bug.cgi?id=89237

Reviewed by Gavin Barraclough.

(PART 1)

This patch turned out to be crashy, so I'm landing the non-crashy bits
first.

This part is pre-requisite refactoring. I didn't actually turn off
"berzerker GC" or turn on incremental shrinking.

* heap/MarkedAllocator.cpp:
(JSC::MarkedAllocator::removeBlock): Make sure to clear the free list when
we throw away the block we're currently allocating out of. Otherwise, we'll
allocate out of a stale free list.

* heap/MarkedSpace.cpp:
(JSC::Free::Free):
(JSC::Free::operator()):
(JSC::Free::returnValue): Refactored this functor to use a shared helper
function, so we can share our implementation with the incremental sweeper.

Also changed to freeing individual blocks immediately instead of linking
them into a list for later freeing. This makes the programming interface
simpler, and it's slightly more efficient to boot.

(JSC::MarkedSpace::~MarkedSpace): Updated for rename.

(JSC::MarkedSpace::freeBlock):
(JSC::MarkedSpace::freeOrShrinkBlock): New helper functions to share behavior
with the incremental sweeper.

(JSC::MarkedSpace::shrink): Updated for new functor behavior.

* heap/MarkedSpace.h: Statically typed languages are awesome.

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

8 years agoDFG should optimize ResolveGlobal
fpizlo@apple.com [Thu, 21 Jun 2012 01:38:49 +0000 (01:38 +0000)]
DFG should optimize ResolveGlobal
https://bugs.webkit.org/show_bug.cgi?id=89617

Reviewed by Oliver Hunt.

This adds inlining of ResolveGlobal accesses that are known monomorphic. It also
adds the specific function optimization to ResolveGlobal, when it is inlined. And,
it makes internal functions act like specific functions, since that will be the
most common use-case of this optimization.

This is only a slighy speed-up (sub 1%), since we don't yet do the obvious thing
with this optimization, which is to completely inline common "globally resolved"
function and constructor calls, like "new Array()".

* CMakeLists.txt:
* GNUmakefile.list.am:
* JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
* JavaScriptCore.xcodeproj/project.pbxproj:
* Target.pri:
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::globalResolveInfoForBytecodeOffset):
* bytecode/CodeBlock.h:
(CodeBlock):
(JSC::CodeBlock::numberOfGlobalResolveInfos):
* bytecode/GlobalResolveInfo.h:
(JSC::getGlobalResolveInfoBytecodeOffset):
(JSC):
* bytecode/ResolveGlobalStatus.cpp: Added.
(JSC):
(JSC::computeForStructure):
(JSC::computeForLLInt):
(JSC::ResolveGlobalStatus::computeFor):
* bytecode/ResolveGlobalStatus.h: Added.
(JSC):
(ResolveGlobalStatus):
(JSC::ResolveGlobalStatus::ResolveGlobalStatus):
(JSC::ResolveGlobalStatus::state):
(JSC::ResolveGlobalStatus::isSet):
(JSC::ResolveGlobalStatus::operator!):
(JSC::ResolveGlobalStatus::isSimple):
(JSC::ResolveGlobalStatus::takesSlowPath):
(JSC::ResolveGlobalStatus::structure):
(JSC::ResolveGlobalStatus::offset):
(JSC::ResolveGlobalStatus::specificValue):
* dfg/DFGByteCodeParser.cpp:
(ByteCodeParser):
(JSC::DFG::ByteCodeParser::handleGetByOffset):
(DFG):
(JSC::DFG::ByteCodeParser::handleGetById):
(JSC::DFG::ByteCodeParser::parseBlock):
* runtime/JSObject.cpp:
(JSC::getCallableObjectSlow):
(JSC):
(JSC::JSObject::put):
(JSC::JSObject::putDirectVirtual):
(JSC::JSObject::putDirectAccessor):
* runtime/JSObject.h:
(JSC):
(JSC::getCallableObject):
(JSC::JSObject::putOwnDataProperty):
(JSC::JSObject::putDirect):
(JSC::JSObject::putDirectWithoutTransition):

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

8 years agoSource/WebCore: [Shadow][Editing] Deleting character in distributed element caused...
hayato@chromium.org [Thu, 21 Jun 2012 01:34:11 +0000 (01:34 +0000)]
Source/WebCore: [Shadow][Editing] Deleting character in distributed element caused a crash.
https://bugs.webkit.org/show_bug.cgi?id=88484

Reviewed by Ryosuke Niwa.

If we mutate nodes which are children of a shadow host, it causes
ElementShadow::invalidateDistribution().  As a result, shadow host
is detached (and lazyAttached()) and its renderer is gone.  That
causes assertion error since isEditablePosition() assumes
anchorNode's style was correctly calculated.

This patch makes isEditablePosition() call
document->updateLayoutIgnorePendingStylesheets() so that it does
not return a bogus result.

There is an exceptional caller of isEditablePosition,
RenderBlock::paintCaret(), from where we can not call
updateLayout() in isEditablePosition because it hits assertion,
ASSERT(!isPainting). So I've added the third parameter to
isEditablePosition to control updating the style.

Test: edition/shadow/delete-characters-in-distributed-node.html

* editing/FrameSelection.h:
(WebCore::FrameSelection::rendererIsEditable):
* editing/VisibleSelection.cpp:
(WebCore::VisibleSelection::rendererIsEditable):
(WebCore):
* editing/VisibleSelection.h:
(VisibleSelection):
* editing/htmlediting.cpp:
(WebCore::isEditablePosition):
* editing/htmlediting.h:
(WebCore):
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::paintCaret):

LayoutTests: [Shadow][Editing] Deleting character in distributed element caused a crash
https://bugs.webkit.org/show_bug.cgi?id=88484

Reviewed by Ryosuke Niwa.

* editing/shadow/delete-characters-in-distributed-node-crash-expected.txt: Added.
* editing/shadow/delete-characters-in-distributed-node-crash.html: Added.

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

8 years agoUnmodified form control value are overwritten by another form
tkent@chromium.org [Thu, 21 Jun 2012 01:31:08 +0000 (01:31 +0000)]
Unmodified form control value are overwritten by another form
control value with the same name after navigating and going back
https://bugs.webkit.org/show_bug.cgi?id=89409

Reviewed by Hajime Morita.

Source/WebCore:

Detail of the bug:
If a page had multiple form controls of which names and types were
identical like the following:
  <input type=text name=name1 id=input1>
  <input type=text name=name1 id=input2>
and a user updated the value of the second control, then went to
another page and went back to the page again, we restored the updated
value to the first element, and didn't update the second element.

We didn't save unmodified control state, and the form state data
had no ways to represent "this control should be skipped".

How to resovle the bug:
We need to represent "this control should be skipped" in the
seriazlied form state vector.

- A serialized control state had three items:
        name, type, value.
  Now we change it to:
        name, type, flag, optional value

- It is definitely incompatible with serizlized state produced by
older WebCore. So, we need to add the signature string to
represent the version of serialized state format.

- Because the state for a form control is variable-length and we
can't deserialize it in reverse-order, we change the on-memory
representation from Vector<> to Deque<>.

Test: fast/forms/state-restore-to-non-edited-controls.html

* html/FormController.cpp:
(WebCore::FormControlState::serializeTo):
Added. Serialize a state for a form control to a string vector.
(WebCore::FormControlState::deserialize):
Added. Produce a FormControlState object from the specified string vector.
It can produce a FromControlState of the failure type.
(WebCore::formStateSignature): The signature string of the serialized state.
(WebCore::FormController::formElementsState):
 - Capacity:
  The size of seirlized data for one form control is typically 4.
  +1 for the signature.
 - We need to store a FormControlState with no values.
(WebCore::FormController::setStateForNewFormElements):
 - We can't iterate over the stateVector in reverse order any more
   because serialized control state is variable-length.
 - We put FormControlState objects to HashMap instead of String objects.
(WebCore::FormController::takeStateForFormElement):
 Updated for Deque<>.
* html/FormController.h:
(FormControlState): Declare deserialize() and serializeTo().
(WebCore::FormControlState::isFailure): Added.
(WebCore::FormControlState::FormControlState):
Added to create a FormControlState with failure type.
(FormController):
Change the value type of m_stateForNewFormElements from Vector<String>
to Deque<FormControlState>.

LayoutTests:

* fast/forms/resources/state-restore-broken-state-2.html:
Take care of the signature string at the beginning of the array.
* fast/forms/state-restore-broken-state-expected.txt:
Updated for the serialized format change.
* fast/forms/state-restore-to-non-edited-controls-expected.txt:
* fast/forms/state-restore-to-non-edited-controls.html:
Add a test for a case of duplicated names.

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

8 years agoUnskip fast/hidpi/device-scale-factor-paint.html
abarth@webkit.org [Thu, 21 Jun 2012 01:29:36 +0000 (01:29 +0000)]
Unskip fast/hidpi/device-scale-factor-paint.html
https://bugs.webkit.org/show_bug.cgi?id=89618

Reviewed by Beth Dakin.

Now that this test doesn't cause WebKit2 to crash, we can unskip it.

* fast/hidpi/device-scale-factor-paint-expected.html: Removed.
    - Previously, this test was a reftest, but the reference also tried
      to set the device scale factor, which seems problematic. This
      patch converts the test to a normal image test. There aren't any
      scrollbars or text, so many platforms should be able to use the
      same expected PNG file.
* fast/hidpi/device-scale-factor-paint.html:
    - Wrap the call to notifyDone in a thunk because it doesn't work otherwise.
* platform/mac/Skipped:
* platform/mac/fast/hidpi/device-scale-factor-paint-expected.png: Added.
* platform/mac/fast/hidpi/device-scale-factor-paint-expected.txt: Added.
* platform/wk2/Skipped:

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

8 years ago[CSS Shaders] Rename CustomFilterShader class name to CustomFilterCompiledProgram
achicu@adobe.com [Thu, 21 Jun 2012 01:13:56 +0000 (01:13 +0000)]
[CSS Shaders] Rename CustomFilterShader class name to CustomFilterCompiledProgram
https://bugs.webkit.org/show_bug.cgi?id=89578

Reviewed by Dean Jackson.

I've renamed CustomFilterShader to CustomFilterCompiledProgram to make it obvious that it is the result of
calling CustomFilterProgram::compileProgramWithContext.

No new tests, just renamed an existing class.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.gypi:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.xcodeproj/project.pbxproj:
* platform/graphics/filters/CustomFilterCompiledProgram.cpp: Renamed from Source/WebCore/platform/graphics/filters/CustomFilterShader.cpp.
(WebCore):
(WebCore::CustomFilterCompiledProgram::defaultVertexShaderString):
(WebCore::CustomFilterCompiledProgram::defaultFragmentShaderString):
(WebCore::CustomFilterCompiledProgram::CustomFilterCompiledProgram):
(WebCore::CustomFilterCompiledProgram::compileShader):
(WebCore::CustomFilterCompiledProgram::linkProgram):
(WebCore::CustomFilterCompiledProgram::initializeParameterLocations):
(WebCore::CustomFilterCompiledProgram::uniformLocationByName):
(WebCore::CustomFilterCompiledProgram::~CustomFilterCompiledProgram):
* platform/graphics/filters/CustomFilterCompiledProgram.h: Renamed from Source/WebCore/platform/graphics/filters/CustomFilterShader.h.
(WebCore):
* platform/graphics/filters/CustomFilterProgram.cpp:
(WebCore::CustomFilterProgram::compileProgramWithContext): Renamed method from createShaderWithContext to compileProgramWithContext.
* platform/graphics/filters/CustomFilterProgram.h:
(WebCore):
* platform/graphics/filters/FECustomFilter.cpp: Renamed m_shader to m_compiledProgram.
(WebCore::FECustomFilter::platformApplySoftware):
(WebCore::FECustomFilter::initializeContext):
(WebCore::FECustomFilter::bindProgramParameters):
(WebCore::FECustomFilter::bindProgramAndBuffers):
* platform/graphics/filters/FECustomFilter.h:
(WebCore):
(FECustomFilter):

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

8 years agoAdd a performance test for paths in SVG
pdr@google.com [Thu, 21 Jun 2012 01:03:59 +0000 (01:03 +0000)]
Add a performance test for paths in SVG
https://bugs.webkit.org/show_bug.cgi?id=89547

Reviewed by Ryosuke Niwa.

This change adds the first performance test for SVG paths.
In the test we modify complex cubic paths in several ways, testing:
transformations, clipping, d attribute changes, stroke properties,
text on a path, and opacity.

Sample test results on my Linux desktop:
    RESULT SVG: SvgCubics= 68.85 ms
    median= 69.5 ms, stdev= 4.70398767005 ms, min= 56.0 ms, max= 75.0 ms

    RESULT SVG: SvgCubics= 68.4 ms
    median= 69.0 ms, stdev= 3.51283361405 ms, min= 59.0 ms, max= 74.0 ms

    RESULT SVG: SvgCubics= 66.95 ms
    median= 67.0 ms, stdev= 3.4420197559 ms, min= 59.0 ms, max= 74.0 ms

    RESULT SVG: SvgCubics= 70.2 ms
    median= 71.5 ms, stdev= 3.23419232576 ms, min= 63.0 ms, max= 74.0 ms

* SVG: Added.
* SVG/SvgCubics.html: Added.

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

8 years agoWeb Inspector: reduce timeline refresh rate
caseq@chromium.org [Thu, 21 Jun 2012 00:53:25 +0000 (00:53 +0000)]
Web Inspector: reduce timeline refresh rate
https://bugs.webkit.org/show_bug.cgi?id=89548

Reviewed by Pavel Feldman.

Minimize resource contention with the inspected page during refresh:

- reduce refresh for both overview and main panes to 300ms
- automatically limit window size to approximately one pageful of events in the lower pane
- do not refresh lower pane for events that are outside of the window

* inspector/front-end/TimelineOverviewPane.js:
(WebInspector.TimelineOverviewPane.prototype._update):
(WebInspector.TimelineOverviewPane.prototype._onWindowChanged):
(WebInspector.TimelineOverviewPane.prototype.setWindowTimes): Set overview window by times.
(WebInspector.TimelineOverviewPane.prototype._updateWindow):
(WebInspector.TimelineOverviewPane.prototype._scheduleRefresh): Refresh once in 300ms (insted of once in 100ms).
(WebInspector.TimelineOverviewWindow.prototype._setWindow):
* inspector/front-end/TimelinePanel.js:
(WebInspector.TimelinePanel.prototype._onTimelineEventRecorded): Do not refresh if the new record is outside of window.
(WebInspector.TimelinePanel.prototype._innerAddRecordToTimeline):
(WebInspector.TimelinePanel.prototype._resetPanel):
(WebInspector.TimelinePanel.prototype._scheduleRefresh): Refresh rate: 100ms -> 300ms.
(WebInspector.TimelinePanel.prototype._refreshRecords): Automatically set overview window.
* inspector/front-end/TimelinePresentationModel.js: Expose filterRecords
(WebInspector.TimelinePresentationModel.prototype.filteredRecords):
(WebInspector.TimelinePresentationModel.prototype.filterRecords):
(WebInspector.TimelinePresentationModel.prototype._innerFilterRecords):

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

8 years ago[WK2] Color chooser API missing
commit-queue@webkit.org [Thu, 21 Jun 2012 00:43:59 +0000 (00:43 +0000)]
[WK2] Color chooser API missing
https://bugs.webkit.org/show_bug.cgi?id=87495

Patch by Thiago Marcos P. Santos <thiago.santos@intel.com> on 2012-06-20
Reviewed by Andreas Kling.

Added ColorChooser API to WebKit2. This API allows the
embedder to define a custom color picker for <input type="color">.

Only one ColorChooser can be active for a page at a time. Although
the implementation doesn't not assume a modal dialog, no other
color chooser will be created until the active one is closed.

Also added stubs for all platforms, so it wont break the build when
enabling color chooser, even though they don't have the backend
implemented yet.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* UIProcess/API/efl/PageClientImpl.cpp:
(WebKit):
(WebKit::PageClientImpl::createColorChooserProxy):
* UIProcess/API/efl/PageClientImpl.h:
(PageClientImpl):
* UIProcess/API/gtk/PageClientImpl.cpp:
(WebKit):
(WebKit::PageClientImpl::createColorChooserProxy):
* UIProcess/API/gtk/PageClientImpl.h:
(PageClientImpl):
* UIProcess/API/mac/PageClientImpl.h:
(PageClientImpl):
* UIProcess/API/mac/PageClientImpl.mm:
(WebKit):
(WebKit::PageClientImpl::createColorChooserProxy):
* UIProcess/PageClient.h:
(WebKit):
(PageClient):
* UIProcess/WebColorChooserProxy.h: Added.
(WebCore):
(WebKit):
(WebColorChooserProxy):
(Client):
(WebKit::WebColorChooserProxy::Client::~Client):
(WebKit::WebColorChooserProxy::~WebColorChooserProxy):
(WebKit::WebColorChooserProxy::invalidate):
(WebKit::WebColorChooserProxy::WebColorChooserProxy):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::close):
(WebKit):
(WebKit::WebPageProxy::showColorChooser):
(WebKit::WebPageProxy::setColorChooserColor):
(WebKit::WebPageProxy::endColorChooser):
(WebKit::WebPageProxy::didChooseColor):
(WebKit::WebPageProxy::didEndColorChooser):
(WebKit::WebPageProxy::processDidCrash):
* UIProcess/WebPageProxy.h:
(WebPageProxy):
* UIProcess/WebPageProxy.messages.in:
* UIProcess/qt/QtPageClient.cpp:
(WebKit):
(WebKit::QtPageClient::createColorChooserProxy):
* UIProcess/qt/QtPageClient.h:
(QtPageClient):
* UIProcess/win/WebView.cpp:
(WebKit):
(WebKit::WebView::createColorChooserProxy):
* UIProcess/win/WebView.h:
(WebView):
* WebKit2.xcodeproj/project.pbxproj:
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::createColorChooser):
* WebProcess/WebCoreSupport/WebColorChooser.cpp: Added.
(WebKit):
(WebKit::WebColorChooser::WebColorChooser):
(WebKit::WebColorChooser::~WebColorChooser):
(WebKit::WebColorChooser::didChooseColor):
(WebKit::WebColorChooser::didEndChooser):
(WebKit::WebColorChooser::disconnectFromPage):
(WebKit::WebColorChooser::setSelectedColor):
(WebKit::WebColorChooser::endChooser):
* WebProcess/WebCoreSupport/WebColorChooser.h: Added.
(WebCore):
(WebKit):
(WebColorChooser):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage):
(WebKit::WebPage::close):
(WebKit):
(WebKit::WebPage::setActiveColorChooser):
(WebKit::WebPage::didEndColorChooser):
(WebKit::WebPage::didChooseColor):
* WebProcess/WebPage/WebPage.h:
(WebKit):
(WebPage):
(WebKit::WebPage::activeColorChooser):
* WebProcess/WebPage/WebPage.messages.in:
* win/WebKit2.vcproj:

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

8 years ago[Chromium] Damage tracker is not used without partial swap, causing valid render...
commit-queue@webkit.org [Thu, 21 Jun 2012 00:43:08 +0000 (00:43 +0000)]
[Chromium] Damage tracker is not used without partial swap, causing valid render passes to be removed
https://bugs.webkit.org/show_bug.cgi?id=89589

Patch by Zeev Lieber <zlieber@chromium.org> on 2012-06-20
Reviewed by Adrienne Walker.

Source/WebCore:

When not using partial swap, the CCDamageTracker was not used, and
its m_currentDamageRect was always empty. As a result,
CCLayerTreeHostImpl was thinking no content was changed and was
removing more textures than needed. Fixed this by turning on
CCDamageTracker usage even if not using partial swap, but
overwriting the rootScissorRect with viewport rect if required.

Added unit tests to exercise this scenario.

* platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
(WebCore::CCLayerTreeHostImpl::calculateRenderSurfaceLayerList):

Source/WebKit/chromium:

Added unit tests to check surface texture caching when partial
swap is not used.

* tests/CCLayerTreeHostImplTest.cpp:

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

8 years agoIndexedDB: Remove redundant IDBObjectStore.delete() overloads
jsbell@chromium.org [Thu, 21 Jun 2012 00:31:41 +0000 (00:31 +0000)]
IndexedDB: Remove redundant IDBObjectStore.delete() overloads
https://bugs.webkit.org/show_bug.cgi?id=89587

Reviewed by Darin Fisher.

Source/WebCore:

The IDBObjectStore.delete(IDBKey) overload can delegate to the delete(IDBKeyRange)
overload. Also cleaned up redundant checks in related overloads.

Test: storage/indexeddb/deleted-objects.html

* Modules/indexeddb/IDBCursorBackendImpl.cpp:
(WebCore::IDBCursorBackendImpl::deleteFunction): Call keyRange variant instead.
* Modules/indexeddb/IDBIndex.cpp:
(WebCore::IDBIndex::get): Remove redundant deleted/invalid IDBKey checks.
(WebCore::IDBIndex::getKey): Remove redundant deleted/invalid IDBKey checks.
* Modules/indexeddb/IDBKeyRange.cpp: Null IDBKeys are not acceptable; currently
not passed in by any callers.
(WebCore::IDBKeyRange::only):
(WebCore::IDBKeyRange::lowerBound):
(WebCore::IDBKeyRange::upperBound):
(WebCore::IDBKeyRange::bound):
* Modules/indexeddb/IDBObjectStore.cpp:
(WebCore::IDBObjectStore::get): Was missing deleted check in IDBKeyRange overload.
Removed redundant checks in IDBKey overload.
(WebCore::IDBObjectStore::deleteFunction): Delegate to IDBKeyRange overload.
* Modules/indexeddb/IDBObjectStoreBackendImpl.cpp: Remove IDBKey overload.
* Modules/indexeddb/IDBObjectStoreBackendImpl.h: Remove IDBKey overload.
(IDBObjectStoreBackendImpl):
* Modules/indexeddb/IDBObjectStoreBackendInterface.h: Remove IDBKey overload.

Source/WebKit/chromium:

* public/WebIDBObjectStore.h: Add note to remove overload when Chromium is updated.
(WebIDBObjectStore):
* src/IDBObjectStoreBackendProxy.cpp: Delete IDBKey overload.
* src/IDBObjectStoreBackendProxy.h: Delete IDBKey overload.
(IDBObjectStoreBackendProxy):
* src/WebIDBObjectStoreImpl.cpp: Delete IDBKey overload.
* src/WebIDBObjectStoreImpl.h: Delete IDBKey overload.
(WebIDBObjectStoreImpl):

LayoutTests:

* storage/indexeddb/deleted-objects-expected.txt:
* storage/indexeddb/resources/deleted-objects.js: Test IDBKeyRange overloads.
(openDatabase.request.onsuccess.request.onsuccess):
(openDatabase.request.onsuccess):
(openDatabase):

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

8 years ago[Shadow][Editing] Selection will break editing boundaries in Shadow DOM.
shinyak@chromium.org [Thu, 21 Jun 2012 00:10:42 +0000 (00:10 +0000)]
[Shadow][Editing] Selection will break editing boundaries in Shadow DOM.
https://bugs.webkit.org/show_bug.cgi?id=89075

Reviewed by Antti Koivisto.

Source/WebCore:

At the shadow boundary, some styles (e.g. user-modify, text-decoration) cannot be inherited
from the shadow host. However, when style property cache is used, such styles are wrongly
inherited from the cache.

So this patch makes not to use cache for inehrited styles at the shadow boundary.

Tests: editing/shadow/breaking-editing-boundary-with-table.html
       editing/shadow/contenteditable-propagation-at-shadow-boundary.html

* css/StyleResolver.cpp:
(WebCore::StyleResolver::collectMatchingRulesForList):

LayoutTests:

Test cases to confirm that (1) selection does not break editing boundary,
and (2) content-editable is not propagated from shadow host to shadow DOM.

Actually a patch for Bug 88514 contains a test for (2), but it is not enough.

* editing/shadow/breaking-editing-boundary-with-table.html: Added.
* editing/shadow/contenteditable-propagation-at-shadow-boundary.html: Added.

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

8 years agoFunctions on global objects should be specializable
fpizlo@apple.com [Wed, 20 Jun 2012 23:55:18 +0000 (23:55 +0000)]
Functions on global objects should be specializable
https://bugs.webkit.org/show_bug.cgi?id=89615

Reviewed by Oliver Hunt.

I tested to see if this brought back the bug in https://bugs.webkit.org/show_bug.cgi?id=33343,
and it didn't. Bug 33343 was the reason why we disabled global object function specialization
to begin with. So I'm guessing this is safe.

* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):

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

8 years agoSource/WebCore: Moving cookieEnabled/setCookieEnabled from Page to Settings.
commit-queue@webkit.org [Wed, 20 Jun 2012 23:49:53 +0000 (23:49 +0000)]
Source/WebCore: Moving cookieEnabled/setCookieEnabled from Page to Settings.
https://bugs.webkit.org/show_bug.cgi?id=89545

Patch by Garret Kelly <gdk@chromium.org> on 2012-06-20
Reviewed by Adam Barth.

* dom/Document.cpp:
(WebCore::Document::cookie):
(WebCore::Document::setCookie):
* page/Navigator.cpp:
(WebCore::Navigator::cookieEnabled):
* page/Page.h:
(Page):
* page/Settings.cpp:
(WebCore::Settings::Settings):
* page/Settings.h:
(WebCore::Settings::setCookieEnabled):
(WebCore::Settings::cookieEnabled):
(Settings):
* platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
(WebCore::MediaPlayerPrivateQuickTimeVisualContext::setUpCookiesForQuickTime):

Source/WebKit/chromium: Moving cookieEnabled/setCookieEnabled from Page to Settings, and
exposing through WebSettings.
https://bugs.webkit.org/show_bug.cgi?id=89545

Patch by Garret Kelly <gdk@chromium.org> on 2012-06-20
Reviewed by Adam Barth.

* public/WebSettings.h:
* src/WebSettingsImpl.cpp:
(WebKit::WebSettingsImpl::setCookieEnabled):
* src/WebSettingsImpl.h:
(WebSettingsImpl):

Source/WebKit/mac: Moving cookieEnabled/setCookieEnabled from Page to Settings.
https://bugs.webkit.org/show_bug.cgi?id=89545

Patch by Garret Kelly <gdk@chromium.org> on 2012-06-20
Reviewed by Adam Barth.

* WebView/WebView.mm:
(-[WebView _cookieEnabled]):
(-[WebView _setCookieEnabled:]):

Source/WebKit/win: Moving cookieEnabled/setCookieEnabled from Page to Settings.
https://bugs.webkit.org/show_bug.cgi?id=89545

Patch by Garret Kelly <gdk@chromium.org> on 2012-06-20
Reviewed by Adam Barth.

* WebView.cpp:
(WebView::setCookieEnabled):
(WebView::cookieEnabled):

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

8 years agointernals.settings.setDeviceScaleFactor doesn't work for WebKit2 and must be removed
abarth@webkit.org [Wed, 20 Jun 2012 23:37:47 +0000 (23:37 +0000)]
internals.settings.setDeviceScaleFactor doesn't work for WebKit2 and must be removed
https://bugs.webkit.org/show_bug.cgi?id=89274

Reviewed by James Robinson.

Source/WebCore:

Using this window.internals API causes the apple-mac port to ASSERT in
WebKit2 because WebKit2 keeps a copy of this state in the UI process.
When a test uses this internals API, the WebCore state gets out of sync
with the state in the UI process.

Tests should use setBackingScaleFactor instead.

* testing/InternalSettings.cpp:
(WebCore):
* testing/InternalSettings.h:
(InternalSettings):
* testing/InternalSettings.idl:

LayoutTests:

* fast/hidpi/device-scale-factor-paint.html:

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

8 years agoWeb Inspector: persist timeline panel overview mode
caseq@chromium.org [Wed, 20 Jun 2012 23:36:06 +0000 (23:36 +0000)]
Web Inspector: persist timeline panel overview mode
https://bugs.webkit.org/show_bug.cgi?id=88711

Reviewed by Pavel Feldman.

- replace all internal methods of switching to a new mode of TimelineOverviewPane with setMode();
- make current mode a persistent setting;

* inspector/front-end/TimelineOverviewPane.js:
(WebInspector.TimelineOverviewPane):
(WebInspector.TimelineOverviewPane.prototype.setMode):
* inspector/front-end/TimelinePanel.js:
(WebInspector.TimelinePanel):

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

8 years agoPerform hit-test from correct frame in isRectTopmost()
commit-queue@webkit.org [Wed, 20 Jun 2012 23:31:17 +0000 (23:31 +0000)]
Perform hit-test from correct frame in isRectTopmost()
https://bugs.webkit.org/show_bug.cgi?id=89492

Patch by Raymes Khoury <raymes@chromium.org> on 2012-06-20
Reviewed by Levi Weintraub.

Hit-testing was being performed from the main frame, which gave the
incorrect result if the plugin was in a different frame.

* src/WebPluginContainerImpl.cpp:
(WebKit::WebPluginContainerImpl::isRectTopmost):

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

8 years ago<rdar://problem/11653784> and https://bugs.webkit.org/show_bug.cgi?id=89590
beidson@apple.com [Wed, 20 Jun 2012 23:05:04 +0000 (23:05 +0000)]
<rdar://problem/11653784> and https://bugs.webkit.org/show_bug.cgi?id=89590
showModalDialog message handling is flaky in WebKit2

Because RunLoop::performWork() swaps the function queue to a temporary Vector before calling
the functions an inner run-loop - such as we see with running a modal dialog - does not have
a change to handle any of the functions that were queued after the WebPageProxy::RunModal message.

By servicing the functions in the queue one at a time we can give the RunLoop a chance to pick up
where it left off if RunLoop::performWork is re-entered.

To guarantee RunLoop::performWork is re-entered to handle those functions we also need to signal
its source before entering the modal run loop so our RunLoop is woken up.

Reviewed by Darin Adler.

Source/WebCore:

* WebCore.exp.in:
* platform/RunLoop.cpp:
(WebCore::RunLoop::performWork): Take the first function off the queue one at a time so subsequent
  functions remain in the queue and can be handled by an inner modal run loop.
* platform/RunLoop.h:
(RunLoop): Change the function queue to be a Deque to efficiently support "takeFirst"

Source/WebKit2:

* Platform/CoreIPC/Connection.cpp:
(CoreIPC::Connection::wakeUpRunLoop): Added so the WebPageProxy can signal the runloop to be woken up
  before it enters the modal dialog run loop.
* Platform/CoreIPC/Connection.h:

* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::runModal): Call wakeUpRunLoop() before entering the modal dialog run loop.

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

8 years ago<http://webkit.org/b/89606> Teach run-safari and debug-safari to work with a Safari...
mrowe@apple.com [Wed, 20 Jun 2012 23:01:14 +0000 (23:01 +0000)]
<webkit.org/b/89606> Teach run-safari and debug-safari to work with a Safari.app that has entitlements

Reviewed by Dan Bernstein.

* Scripts/webkitdirs.pm:
(executableHasEntitlements):
(safariPathFromSafariBundle):

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

8 years ago[chromium] Support mobile device rotation resizing
commit-queue@webkit.org [Wed, 20 Jun 2012 22:57:58 +0000 (22:57 +0000)]
[chromium] Support mobile device rotation resizing
https://bugs.webkit.org/show_bug.cgi?id=86819

Patch by Alexandre Elias <aelias@google.com> on 2012-06-20
Reviewed by Adam Barth.

Resizes on a mobile device are caused either by rotation or
on-screen-keyboard bringup, and need different treatment to remain
naturally laid out, scaled and scrolled without disorienting the user.

* src/WebViewImpl.cpp:
(WebKit::WebViewImpl::resize):

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

8 years agoAccount for device scale factor when creating image for dragging.
commit-queue@webkit.org [Wed, 20 Jun 2012 22:49:13 +0000 (22:49 +0000)]
Account for device scale factor when creating image for dragging.
https://bugs.webkit.org/show_bug.cgi?id=89489

Patch by Varun Jain <varunjain@chromium.org> on 2012-06-20
Reviewed by Adam Barth.

.:

* ManualTests/chromium/drag-image-accounts-for-device-scale.html: Added.

Source/WebCore:

Manual Test: ManualTests/chromium/drag-image-accounts-for-device-scale.html

* page/Frame.cpp:
(WebCore::Frame::nodeImage):
(WebCore::Frame::dragImageForSelection):

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

8 years agoFixed typos in the change log.
mitz@apple.com [Wed, 20 Jun 2012 22:36:50 +0000 (22:36 +0000)]
Fixed typos in the change log.

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

8 years agoAdd a != operator to ViewportArguments
zhajiang@rim.com [Wed, 20 Jun 2012 22:35:33 +0000 (22:35 +0000)]
Add a != operator to ViewportArguments
https://bugs.webkit.org/show_bug.cgi?id=87505

Reviewed by Antonio Gomes.
Patch by Jacky Jiang  <zhajiang@rim.com>

Source/WebCore:

Add a != operator to ViewportArguments for convenience.

* dom/ViewportArguments.h:
(ViewportArguments):
(WebCore::ViewportArguments::operator!=):

Source/WebKit/blackberry:

Use != operator of ViewportArguments.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::setLoadState):
(BlackBerry::WebKit::WebPagePrivate::setViewportSize):
* Api/WebViewportArguments.cpp:
(BlackBerry::WebKit::WebViewportArguments::operator!=):

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

8 years ago[Qt] Unreviewed gardening, skip new failing tests.
ossy@webkit.org [Wed, 20 Jun 2012 22:25:12 +0000 (22:25 +0000)]
[Qt] Unreviewed gardening, skip new failing tests.

* platform/qt/Skipped:

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

8 years agoComputed style tests are a maintenance burden on the project
tony@chromium.org [Wed, 20 Jun 2012 22:15:10 +0000 (22:15 +0000)]
Computed style tests are a maintenance burden on the project
https://bugs.webkit.org/show_bug.cgi?id=87991

Reviewed by Eric Seidel.

Convert computed-style.html, computed-style-without-renderer.html and getComputedStyle-basic.xhtml
to use a whitelist of properties rather than a blacklist. The whitelist includes all properties
that are supported based on the checked in results so all ports can share the same values. Adding
new properties won't cause these tests to be rebaselined.

* fast/css/getComputedStyle/computed-style-expected.txt:
* fast/css/getComputedStyle/computed-style-without-renderer-expected.txt:
* fast/css/getComputedStyle/computed-style-without-renderer.html: Remove indenting and use a fixed
width for the middle div so we don't get fractional pixel values for ports with fractional pixel
values enabled.
* fast/css/getComputedStyle/computed-style.html:
* fast/css/getComputedStyle/resources/property-names.js: Whitelist of common CSS properties.
* platform/chromium-linux-x86/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/chromium-linux/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/chromium-mac-leopard/fast/css/getComputedStyle/computed-style-expected.txt: Removed.
* platform/chromium-mac-leopard/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/chromium-mac-snowleopard/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/chromium-mac/fast/css/getComputedStyle/computed-style-expected.txt: Removed.
* platform/chromium-mac/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt: Removed.
* platform/chromium-mac/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/chromium-win-vista/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/chromium-win-xp/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/chromium-win/fast/css/getComputedStyle/computed-style-expected.txt: Removed.
* platform/chromium-win/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt: Removed.
* platform/chromium-win/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/gtk/fast/css/getComputedStyle/computed-style-expected.txt: Removed.
* platform/gtk/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/mac/fast/css/getComputedStyle/computed-style-expected.txt: Removed.
* platform/mac/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt: Removed.
* platform/mac/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/qt/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt: Removed.
* platform/qt/svg/css/getComputedStyle-basic-expected.png: Removed.
* platform/qt/svg/css/getComputedStyle-basic-expected.txt: Removed.
* platform/win/fast/css/getComputedStyle/computed-style-expected.txt: Removed.
* platform/win/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt: Removed.
* svg/css/getComputedStyle-basic-expected.txt:
* svg/css/getComputedStyle-basic.xhtml:

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

8 years agoLet XCode have its own way.
rniwa@webkit.org [Wed, 20 Jun 2012 22:08:15 +0000 (22:08 +0000)]
Let XCode have its own way.

* WebCore.xcodeproj/project.pbxproj:

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

8 years agoMove m_listsInvalidatedAtDocument from NodeListsNodeData to Document
rniwa@webkit.org [Wed, 20 Jun 2012 22:05:12 +0000 (22:05 +0000)]
Move m_listsInvalidatedAtDocument from NodeListsNodeData to Document
https://bugs.webkit.org/show_bug.cgi?id=89603

Reviewed by Andreas Kling.

Moved the variable. m_listsInvalidatedAtDocument is never used in non-Document nodes
so it was just wasting memory space.

* dom/Document.cpp:
(WebCore::Document::registerDynamicSubtreeNodeList):
(WebCore::Document::unregisterDynamicSubtreeNodeList):
(WebCore):
(WebCore::Document::clearNodeListCaches):
* dom/Document.h:
(Document):
* dom/DynamicNodeList.h:
(DynamicSubtreeNodeList):
* dom/Node.cpp:
(WebCore::Node::invalidateNodeListsCacheAfterAttributeChanged):
(WebCore::Node::invalidateNodeListsCacheAfterChildrenChanged):
(WebCore):
(WebCore::NodeListsNodeData::invalidateCachesThatDependOnAttributes): RadioNodeList
is invalidated at document level. No need to invalidate it again here.
(WebCore::NodeListsNodeData::isEmpty):
* dom/NodeRareData.h:
(NodeListsNodeData):

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

8 years agoUnreviewed, rolling out r120821.
commit-queue@webkit.org [Wed, 20 Jun 2012 22:02:41 +0000 (22:02 +0000)]
Unreviewed, rolling out r120821.
http://trac.webkit.org/changeset/120821
https://bugs.webkit.org/show_bug.cgi?id=89605

It made duplicated reviewer entries (Requested by Ossy on
#webkit).

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

* Scripts/webkitpy/common/checkout/changelog.py:
(ChangeLog.set_reviewer):
* Scripts/webkitpy/common/checkout/changelog_unittest.py:
(test_set_reviewer):
(test_set_short_description_and_bug_url):

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

8 years agoUnreviewed, rolling out r120854.
commit-queue@webkit.org [Wed, 20 Jun 2012 21:58:18 +0000 (21:58 +0000)]
Unreviewed, rolling out r120854.
http://trac.webkit.org/changeset/120854
https://bugs.webkit.org/show_bug.cgi?id=89604

Broke Chromium WebKit Linux (dbg) (Requested by arv on
#webkit).

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

* Target.pri:
* UseV8.cmake:
* WebCore.gypi:
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateHeader):
(GenerateImplementation):
* bindings/scripts/CodeGeneratorV8.pm:
(GenerateHeader):
(GenerateNamedConstructorCallback):
(GenerateImplementation):
* bindings/scripts/IDLAttributes.txt:
* bindings/scripts/test/V8/V8Float64Array.cpp:
(WebCore):
* bindings/scripts/test/V8/V8Float64Array.h:
(V8Float64Array):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestActiveDOMObject.h:
(V8TestActiveDOMObject):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
(V8TestCustomNamedGetter):
* bindings/scripts/test/V8/V8TestEventConstructor.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestEventConstructor.h:
(V8TestEventConstructor):
* bindings/scripts/test/V8/V8TestEventTarget.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestEventTarget.h:
(V8TestEventTarget):
* bindings/scripts/test/V8/V8TestException.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestException.h:
(V8TestException):
* bindings/scripts/test/V8/V8TestInterface.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestInterface.h:
(V8TestInterface):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
(V8TestMediaQueryListListener):
* bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestNamedConstructor.h:
(V8TestNamedConstructor):
* bindings/scripts/test/V8/V8TestNode.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestNode.h:
(V8TestNode):
* bindings/scripts/test/V8/V8TestObj.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestObj.h:
(V8TestObj):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
(V8TestSerializedScriptValueInterface):
* bindings/v8/NPV8Object.cpp:
(WebCore::npObjectTypeInfo):
* bindings/v8/V8GCController.cpp:
(WebCore::GrouperVisitor::visitDOMWrapper):
* bindings/v8/WrapperTypeInfo.h:
(WebCore):
(WrapperTypeInfo):
* bindings/v8/custom/V8CSSStyleSheetCustom.cpp: Copied from Source/WebCore/bindings/v8/custom/V8StyleSheetCustom.cpp.
(WebCore):
(WebCore::toV8):
* bindings/v8/custom/V8DOMStringMapCustom.cpp:
(WebCore::toV8):
(WebCore):
* bindings/v8/custom/V8DOMTokenListCustom.cpp: Copied from Source/WebCore/bindings/v8/custom/V8StyleSheetCustom.cpp.
(WebCore):
(WebCore::toV8):
* bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
(WebCore):
* bindings/v8/custom/V8NamedNodeMapCustom.cpp:
(WebCore::toV8):
(WebCore):
* bindings/v8/custom/V8StyleSheetCustom.cpp:
(WebCore::toV8):
* bindings/v8/custom/V8TextTrackListCustom.cpp: Copied from Source/WebCore/bindings/v8/custom/V8StyleSheetCustom.cpp.
(WebCore):
(WebCore::toV8):
* css/CSSStyleSheet.idl:
* css/StyleSheet.idl:
* dom/DOMStringMap.idl:
* dom/NamedNodeMap.idl:
* html/DOMTokenList.idl:
* html/track/TextTrackList.idl:

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

8 years agonrwt outputs empty files for wdiff output if wdiff is not installed
dpranke@chromium.org [Wed, 20 Jun 2012 21:30:13 +0000 (21:30 +0000)]
nrwt outputs empty files for wdiff output if wdiff is not installed
https://bugs.webkit.org/show_bug.cgi?id=88709

Reviewed by Tony Chang.

Reviewed by Tony Chang.

Don't write -wdiff or -pretty.html files if wdiff or prettypatch
aren't available, and clean up the handling for them in the port
code.

* Scripts/webkitpy/run_webkit_tests_integrationtest.py:
(MainTest.test_output_diffs):
* Scripts/webkitpy/layout_tests/controllers/test_result_writer.py:
(TestResultWriter.create_text_diff_and_write_result):
* Scripts/webkitpy/layout_tests/port/base.py:
(Port.check_pretty_patch):
(Port.check_wdiff):
(Port._wdiff_missing_message):
* Scripts/webkitpy/layout_tests/port/chromium_linux.py:
(ChromiumLinuxPort.check_build):
(ChromiumLinuxPort._wdiff_missing_message):
* Scripts/webkitpy/layout_tests/port/chromium_mac.py:
(ChromiumMacPort.check_build):
(ChromiumMacPort):
(ChromiumMacPort._wdiff_missing_message):
* Scripts/webkitpy/layout_tests/port/chromium_mac_unittest.py:
(ChromiumMacPortTest):

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

8 years agonrwt: fix unit tests for ensuring svn revision is correct
dpranke@chromium.org [Wed, 20 Jun 2012 21:25:08 +0000 (21:25 +0000)]
nrwt: fix unit tests for ensuring svn revision is correct
https://bugs.webkit.org/show_bug.cgi?id=89498

Reviewed by Eric Seidel.

Reviewed by Eric Seidel.

Fix the unit tests for testing that we are embedding the SVN
revision in the results json for NRWT properly; this was broken
in r120646 but because the MockHost worked differently than the
real one (by always initializing the MockSCM object) we didn't
notice. Unfortunately, just changing the default breaks all
sorts of unit tests ...

* Scripts/webkitpy/common/host_mock.py:
(MockHost.__init__):
(MockHost._initialize_scm):
* Scripts/webkitpy/layout_tests/controllers/manager_unittest.py:
(ResultSummaryTest.test_no_svn_revision):
(ResultSummaryTest.test_svn_revision):

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

8 years agonew-run-webkit-tests appends "/Debug" or "/Release" to $WEBKITOUTPUTDIR
dpranke@chromium.org [Wed, 20 Jun 2012 21:22:35 +0000 (21:22 +0000)]
new-run-webkit-tests appends "/Debug" or "/Release" to $WEBKITOUTPUTDIR
https://bugs.webkit.org/show_bug.cgi?id=69360

Reviewed by Eric Seidel.

Reviewed by Eric Seidel.

Propagate the 'port_implementation' part of the platform (i.e.,
gtk,qt,chromium) to webkit-build-directory so that we can pick
up the gtk-specific handling of WEBKITOUTPUTDIR ...

I didn't write any additional tests for this; testing it
properly is an integration test between the python code and the
perl code, which I verified by hand.

* Scripts/webkitpy/layout_tests/port/base.py:
(Port.__init__):
* Scripts/webkitpy/layout_tests/port/config.py:
(Config.__init__):
(Config.build_directory):
* Scripts/webkitpy/layout_tests/port/config_mock.py:
(MockConfig.__init__):
* Scripts/webkitpy/layout_tests/port/config_unittest.py:
(ConfigTest.test_build_directory_passes_port_implementation):

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

8 years agoCrash on accessing a removed renderer from percent height descendant map.
inferno@chromium.org [Wed, 20 Jun 2012 21:20:29 +0000 (21:20 +0000)]
Crash on accessing a removed renderer from percent height descendant map.
https://bugs.webkit.org/show_bug.cgi?id=88017

Reviewed by Eric Seidel.

Source/WebCore:

Test: fast/block/percent-height-descendant-not-removed-crash2.html

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::hasPercentHeightContainerMap): helper to tell
if we have a height container map.
(WebCore):
(WebCore::RenderBlock::hasPercentHeightDescendant): change from a debug
only function to a regular function for use. no need to null check
for a percent height container map in this function.
(WebCore::RenderBlock::clearPercentHeightDescendantsFrom): helper to
clear all percent height descendants under us.
(WebCore::RenderBlock::removePercentHeightDescendantIfNeeded): helper to
clear the box if it exists in the percent height descendant map.
* rendering/RenderBlock.h:
(RenderBlock):
* rendering/RenderBox.cpp:
(WebCore::RenderBox::willBeDestroyed): remove the assert and change the
percent height detection check to use removePercentHeightDescendantIfNeeded.
We shouldn't rely on logicalHeight().isPercent() as it can change when our
writing mode changes. Instead, just query the map directly to see if we exist.
(WebCore::RenderBox::styleDidChange): when our writing mode changes from
horizontal to vertical or vice versa, we clear all our descendants from
the percent height descendant map. Cache the value of isHorizontalWritingMode()
before it changes in styleDidChange and compare it with the new value
(can't use oldStyle->isHorizontalWritingMode() since it can be inherited
and already updated).

LayoutTests:

* fast/block/percent-height-descendant-not-removed-crash2-expected.txt: Added.
* fast/block/percent-height-descendant-not-removed-crash2.html: Added.

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

8 years ago[BlackBerry] Add an API to immediately enable cross-site XHR
commit-queue@webkit.org [Wed, 20 Jun 2012 21:15:18 +0000 (21:15 +0000)]
[BlackBerry] Add an API to immediately enable cross-site XHR
https://bugs.webkit.org/show_bug.cgi?id=89594

Internally Reviewed by Yong Li.
Patch by Christopher Hutten-Czapski <chutten@rim.com> on 2012-06-20
Reviewed by Rob Buis.

There is no API to disable it as clients may rely on legacy behaviour
of not disabling until the next frame load.

* Api/WebPage.cpp:
(BlackBerry::WebKit::enableCrossSiteXHRRecursively):
(WebKit):
(BlackBerry::WebKit::WebPagePrivate::enableCrossSiteXHR):
(BlackBerry::WebKit::WebPage::enableCrossSiteXHR):
* Api/WebPage.h:
* Api/WebPage_p.h:
(WebPagePrivate):

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

8 years agobuild-webkit failure due to illegal 32-bit integer constants in code
fpizlo@apple.com [Wed, 20 Jun 2012 21:07:33 +0000 (21:07 +0000)]
build-webkit failure due to illegal 32-bit integer constants in code
generated by offlineasm
https://bugs.webkit.org/show_bug.cgi?id=89347

Reviewed by Geoffrey Garen.

The offending constants are the magic numbers used by offlineasm to find
offsets in the generated machine code. Added code to turn them into what
the C++ compiler will believe to be valid 32-bit values.

* offlineasm/offsets.rb:

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

8 years agoREGRESSION(r113885): Margin not properly applied to elements with align=center
jchaffraix@webkit.org [Wed, 20 Jun 2012 21:04:16 +0000 (21:04 +0000)]
REGRESSION(r113885): Margin not properly applied to elements with align=center
https://bugs.webkit.org/show_bug.cgi?id=89515

Reviewed by Levi Weintraub.

Reviewed by Levi Weintraub.

Source/WebCore:

Tests: fast/block/negative-margin-start-positive-margin-end.html
       fast/block/negative-start-margin-align-center.html
       fast/block/positive-margin-block-child-align-center-rtl.html
       fast/block/positive-margin-block-child-align-center.html
       fast/block/positive-margin-start-align-center.html
       fast/block/positive-margin-start-negative-margin-end-align-center.html
       fast/table/table-cell-negative-start-margin-align-center.html

r113885 changed the code-path for elements with auto width to call computeInlineDirectionMargins.
However this uncovered an existing bug in the function when dealing with align="center" (text-align: -webkit-center)
where we would ignore the margin. This goes against what other browsers are doing and our previous behavior.

Note that align="left" and "right" are likely impacted too and will be investigated / fixed in follow-up changes.

* rendering/RenderBox.cpp:
(WebCore::RenderBox::computeInlineDirectionMargins):
To match other browsers' behavior, changed the function to include margin in our computations.

LayoutTests:

* fast/block/negative-margin-start-positive-margin-end-expected.html: Added.
* fast/block/negative-margin-start-positive-margin-end.html: Added.
* fast/block/negative-start-margin-align-center-expected.html: Added.
* fast/block/negative-start-margin-align-center.html: Added.
* fast/block/positive-margin-block-child-align-center-expected.html: Added.
* fast/block/positive-margin-block-child-align-center.html: Added.
* fast/block/positive-margin-start-align-center-expected.html: Added.
* fast/block/positive-margin-start-align-center.html: Added.
* fast/block/positive-margin-start-negative-margin-end-align-center-expected.html: Added.
* fast/block/positive-margin-start-negative-margin-end-align-center.html: Added.
Those checks the combination of margin start / end both positive and negative.

* fast/block/positive-margin-block-child-align-center-rtl-expected.html: Added.
* fast/block/positive-margin-block-child-align-center-rtl.html: Added.
One ltr test as I didn't find any.

* fast/table/table-cell-negative-start-margin-align-center-expected.html: Added.
* fast/table/table-cell-negative-start-margin-align-center.html: Added.
This test is very similar to the one above but involves a table.

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

8 years ago[chromium] Separate LayerRenderer initialization from updateLayers
jamesr@google.com [Wed, 20 Jun 2012 20:48:07 +0000 (20:48 +0000)]
[chromium] Separate LayerRenderer initialization from updateLayers
https://bugs.webkit.org/show_bug.cgi?id=89525

Reviewed by Adrienne Walker.

Source/WebCore:

This adds an explicit call to initialize the layer renderer of a given CCLayerTreeHost instead of having it be
implicit in updateLayers(). This way the proxies can control the initialization sequence more closely and do
useful work between the two calls.

Refactor, no change in behavior. Covered by existing tests.

* platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
(WebCore::CCLayerTreeHost::compositeAndReadback):
(WebCore::CCLayerTreeHost::initializeLayerRendererIfNeeded):
(WebCore):
(WebCore::CCLayerTreeHost::updateLayers):
* platform/graphics/chromium/cc/CCLayerTreeHost.h:
(CCLayerTreeHost):
* platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
(WebCore::CCSingleThreadProxy::commitAndComposite):
* platform/graphics/chromium/cc/CCThreadProxy.cpp:
(WebCore::CCThreadProxy::compositeAndReadback):
(WebCore::CCThreadProxy::beginFrame):

Source/WebKit/chromium:

Update tests to call initializeLayerRendererIfNeeded() before calling updateLayers() to reflect what the proxies
do.

* tests/CCLayerTreeHostTest.cpp:
(WTF::CCLayerTreeHostTestLayerOcclusion::beginTest):
(WTF::CCLayerTreeHostTestLayerOcclusionWithFilters::beginTest):
(WTF::CCLayerTreeHostTestManySurfaces::beginTest):
* tests/TiledLayerChromiumTest.cpp:

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

8 years agor120844: Skip two tests on Qt
robert@webkit.org [Wed, 20 Jun 2012 20:25:07 +0000 (20:25 +0000)]
r120844: Skip two tests on Qt

The tests fast/block/float/previous-sibling-abspos-001.html and
fast/block/float/previous-sibling-float-001.html have pixel differences
on Qt. Skip them for now - bug 89597 opened.

Unreviewed, gardening.

* platform/qt/Skipped:

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

8 years agoSecurityOrigin::canDisplay() should return true when m_universalAccess is true
commit-queue@webkit.org [Wed, 20 Jun 2012 20:23:51 +0000 (20:23 +0000)]
SecurityOrigin::canDisplay() should return true when m_universalAccess is true
https://bugs.webkit.org/show_bug.cgi?id=84865

Patch by Yong Li <yoli@rim.com> on 2012-06-20
Reviewed by Adam Barth.

Add an early return (true) in canDisplay() for if (m_universalAccess),
as we did for canAccess() and canRequest().

No new tests. We should be good as long as this change doesn't break existing
tests, which means the contents supposed to be blocked are still blocked when
m_universalAccess is false.

* page/SecurityOrigin.cpp:
(WebCore::SecurityOrigin::canDisplay):

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

8 years ago[V8] Use v8::V8::AddImplicitReferences instead of SetHiddenValue
arv@chromium.org [Wed, 20 Jun 2012 20:16:41 +0000 (20:16 +0000)]
[V8] Use v8::V8::AddImplicitReferences instead of SetHiddenValue
https://bugs.webkit.org/show_bug.cgi?id=80880

Reviewed by Adam Barth.

We used to add a hidden property in the getter to the returned wrapper.
With this patch we instead handle the liveness of the wrapper in the GC phase by
calling v8::V8::AddHiddenReference.

To reduce the amount of custom code we need, the V8 code generator now supports
GenerateIsReachable (as well as CustomIsReachable) which, even though different
from the JSC attribute, is used in the same cases and takes the same values (even though
at the moment not all JSC values are supported by V8). Interfaces that have *IsReachable
also have a dependent life time (just like if V8DependentLifetime was present).

Retry. Last time we got ASAN issues on some Cromium Linux bots.

No new tests. Covered by existing tests.

* Target.pri:
* UseV8.cmake:
* WebCore.gypi:
* bindings/scripts/CodeGeneratorJS.pm:
(GetGenerateIsReachable): Abstracted GenerateIsReachable and JSGenerateIsReachable.
(GetCustomIsReachable): Ditto.
(GenerateHeader):
(GenerateImplementation):
* bindings/scripts/CodeGeneratorV8.pm:
(NeedsToVisitDOMWrapper):
(GetGenerateIsReachable):
(GetCustomIsReachable):
(GenerateVisitDOMWrapper):
(GenerateHeader):
(GenerateNamedConstructorCallback):
(GenerateImplementation):
* bindings/scripts/IDLAttributes.txt:
* bindings/scripts/test/V8/V8Float64Array.cpp:
(WebCore):
* bindings/scripts/test/V8/V8Float64Array.h:
(V8Float64Array):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestActiveDOMObject.h:
(V8TestActiveDOMObject):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
(V8TestCustomNamedGetter):
* bindings/scripts/test/V8/V8TestEventConstructor.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestEventConstructor.h:
(V8TestEventConstructor):
* bindings/scripts/test/V8/V8TestEventTarget.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestEventTarget.h:
(V8TestEventTarget):
* bindings/scripts/test/V8/V8TestException.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestException.h:
(V8TestException):
* bindings/scripts/test/V8/V8TestInterface.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestInterface.h:
(V8TestInterface):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
(V8TestMediaQueryListListener):
* bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestNamedConstructor.h:
(V8TestNamedConstructor):
* bindings/scripts/test/V8/V8TestNode.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestNode.h:
(V8TestNode):
* bindings/scripts/test/V8/V8TestObj.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestObj.h:
(V8TestObj):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
(WebCore):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
(V8TestSerializedScriptValueInterface):
* bindings/v8/NPV8Object.cpp:
(WebCore::npObjectTypeInfo):
* bindings/v8/V8GCController.cpp:
(WebCore::GrouperVisitor::visitDOMWrapper):
* bindings/v8/WrapperTypeInfo.h:
(WebCore):
(WrapperTypeInfo):
* bindings/v8/custom/V8CSSStyleSheetCustom.cpp: Removed.
* bindings/v8/custom/V8DOMStringMapCustom.cpp:
* bindings/v8/custom/V8DOMTokenListCustom.cpp: Removed.
* bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
(WebCore):
* bindings/v8/custom/V8NamedNodeMapCustom.cpp:
* bindings/v8/custom/V8StyleSheetCustom.cpp:
(WebCore::toV8):
* bindings/v8/custom/V8TextTrackListCustom.cpp: Removed.
* css/CSSStyleSheet.idl:
* css/StyleSheet.idl:
* dom/DOMStringMap.idl:
* dom/NamedNodeMap.idl:
* html/DOMTokenList.idl:
* html/track/TextTrackList.idl:

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

8 years agoFix import sorting missed in r120846
dpranke@chromium.org [Wed, 20 Jun 2012 20:00:19 +0000 (20:00 +0000)]
Fix import sorting missed in r120846

Reviewed by Tony Chang.

* Scripts/webkitpy/layout_tests/servers/apache_http_server_unittest.py:

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

8 years agoFix chromium win http servers after breakage introduced in r120846.
dpranke@chromium.org [Wed, 20 Jun 2012 19:53:21 +0000 (19:53 +0000)]
Fix chromium win http servers after breakage introduced in r120846.

Unreviewed, build fix.

* Scripts/webkitpy/layout_tests/port/base.py:
(Port.to.start_http_server):
* Scripts/webkitpy/layout_tests/servers/http_server.py:
(Lighttpd.__init__):

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

8 years agotweak output of webkit-patch print-{baselines,expectations}
dpranke@chromium.org [Wed, 20 Jun 2012 19:47:23 +0000 (19:47 +0000)]
tweak output of webkit-patch print-{baselines,expectations}
https://bugs.webkit.org/show_bug.cgi?id=89588

Reviewed by Tony Chang.

Minor tweaks to the output to make it more readable, including
turning off csv by default for print-baselines with multiple ports.

* Scripts/webkitpy/layout_tests/port/test.py:
(TestPort):
* Scripts/webkitpy/tool/commands/queries.py:
(PrintExpectations.execute):
(PrintBaselines.execute):
* Scripts/webkitpy/tool/commands/queries_unittest.py:
(PrintExpectationsTest.run_test):
(PrintExpectationsTest.test_multiple):
(PrintBaselinesTest.setUp):
(PrintBaselinesTest.test_multiple):

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

8 years agoRegression(r116408): Ctrl-A (select all) on large text file hangs the tab with high...
tony@chromium.org [Wed, 20 Jun 2012 19:33:02 +0000 (19:33 +0000)]
Regression(r116408): Ctrl-A (select all) on large text file hangs the tab with high CPU usage
https://bugs.webkit.org/show_bug.cgi?id=89562

Reviewed by Ryosuke Niwa.

Rather than replace the newlines in-place (in O(n^2)), build a new string using StringBuilder, which takes O(n).

No new tests, this is a perf improvement.

* platform/chromium/ClipboardUtilitiesChromium.cpp:
(WebCore::replaceNewlinesWithWindowsStyleNewlines):
* platform/win/ClipboardUtilitiesWin.cpp:
(WebCore::replaceNewlinesWithWindowsStyleNewlines):

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

8 years agoAdd support for fit-content etc
commit-queue@webkit.org [Wed, 20 Jun 2012 19:28:50 +0000 (19:28 +0000)]
Add support for fit-content etc
https://bugs.webkit.org/show_bug.cgi?id=38919

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

Source/WebCore:

Implement the CSS3 intrinsic dimension keywords for width properties and
add most of the plumbing for height properties but don't expose them
yet since this patch doesn't enforce them (matching current Gecko).
http://dev.w3.org/csswg/css3-writing-modes/#intrinsic-sizing

This patch implements -webkit-min-content, -webkit-max-content,
-webkit-fill-available and -webkit-fit-content for all width
properties.

Tests: fast/css-intrinsic-dimensions/height-dynamic-property-value.html
       fast/css-intrinsic-dimensions/height-property-value.html
       fast/css-intrinsic-dimensions/max-width-constrained.html
       fast/css-intrinsic-dimensions/max-width-unconstrained.html
       fast/css-intrinsic-dimensions/min-width.html
       fast/css-intrinsic-dimensions/width-avoid-floats.html
       fast/css-intrinsic-dimensions/width-dynamic-property-value.html
       fast/css-intrinsic-dimensions/width-property-value.html
       fast/css-intrinsic-dimensions/width.html

* css/CSSParser.cpp: Add parser support for the new keywords.
(WebCore::CSSParser::parseValue):
* css/CSSPrimitiveValue.cpp:
(WebCore):
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
* css/CSSValueKeywords.in:
* css/LengthFunctions.cpp: Implement conversion functions.
(WebCore::minimumValueForLength):
(WebCore::valueForLength):
(WebCore::floatValueForLength):
* css/StyleBuilder.cpp:
(WebCore::ApplyPropertyLength::applyValue):
(WebCore::StyleBuilder::StyleBuilder): Clean up the template for old
   intrinsic values and add new values. Rename old intrinsic to
   LegacyIntrinsic and add support for the new dimension keywords as
   Intrinsic.
* platform/Length.h:
(WebCore::Length::isIntrinsicOrAuto):
(WebCore::Length::isLegacyIntrinsic): New method to check for old
    min-intrinsic and intrinsic keywords.
(WebCore::Length::isIntrinsic): New method to check for CSS3 intrinsic
    dimension keywords like min-content.
* rendering/RenderBox.cpp:
(WebCore::RenderBox::computeLogicalWidthInRegionUsing): Expose the max
   and min logical preferred widths as the new keywords.
(WebCore::RenderBox::sizesLogicalWidthToFitContent): Renamed method to
   be more consistent with the new MinContent naming in the spec.
* rendering/RenderBox.h:
(RenderBox):

LayoutTests:

Tests for CSS3 intrinsic dimension keywords as defined in the
writing modes spec. This tests the implementation for width and
ensures that height properties don't allow the new keywords yet
since they're not implemented by this patch.

* fast/css-intrinsic-dimensions/height-dynamic-property-value-expected.txt: Added.
* fast/css-intrinsic-dimensions/height-dynamic-property-value.html: Added.
* fast/css-intrinsic-dimensions/height-property-value-expected.txt: Added.
* fast/css-intrinsic-dimensions/height-property-value.html: Added.
* fast/css-intrinsic-dimensions/max-width-constrained-expected.html: Added.
* fast/css-intrinsic-dimensions/max-width-constrained.html: Added.
* fast/css-intrinsic-dimensions/max-width-unconstrained-expected.html: Added.
* fast/css-intrinsic-dimensions/max-width-unconstrained.html: Added.
* fast/css-intrinsic-dimensions/min-width-expected.html: Added.
* fast/css-intrinsic-dimensions/min-width.html: Added.
* fast/css-intrinsic-dimensions/width-avoid-floats-expected.html: Added.
* fast/css-intrinsic-dimensions/width-avoid-floats.html: Added.
* fast/css-intrinsic-dimensions/width-dynamic-property-value-expected.txt: Added.
* fast/css-intrinsic-dimensions/width-dynamic-property-value.html: Added.
* fast/css-intrinsic-dimensions/width-expected.html: Added.
* fast/css-intrinsic-dimensions/width-keyword-classes.css: Added.
(.min-content):
(.max-content):
(.fill-available):
(.fit-content):
(.max-width-min-content):
(.max-width-max-content):
(.max-width-fill-available):
(.max-width-fit-content):
(.min-width-min-content):
(.min-width-max-content):
(.min-width-fill-available):
(.min-width-fit-content):
* fast/css-intrinsic-dimensions/width-property-value-expected.txt: Added.
* fast/css-intrinsic-dimensions/width-property-value.html: Added.
* fast/css-intrinsic-dimensions/width.html: Added.

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

8 years ago[chromium] webkit-backface-visibility doesn't work with video
commit-queue@webkit.org [Wed, 20 Jun 2012 19:17:43 +0000 (19:17 +0000)]
[chromium] webkit-backface-visibility doesn't work with video
https://bugs.webkit.org/show_bug.cgi?id=88908

When determining a contents layer's backface culling, use the parent
layer's transform and backface-visibility properties. Track which
layers need this special treatment with useParentBackfaceVisibility
and setUseParentBackfaceVisibility functions in WebCore::LayerChromium,
WebKit::WebLayer, and WebCore::CCLayerImpl.

Patch by Christopher Cameron <ccameron@chromium.org> on 2012-06-20
Reviewed by Adrienne Walker.

Source/Platform:

* chromium/public/WebLayer.h:
    (WebLayer):
        Add an accessor to specify that a layer should use its parent's
        backface culling behavior.

Source/WebCore:

Tests: compositing/backface-visibility/backface-visibility-image.html
       compositing/backface-visibility/backface-visibility-webgl.html

* platform/graphics/chromium/GraphicsLayerChromium.cpp:
(WebCore::GraphicsLayerChromium::setupContentsLayer):
    When a contents layer is added, tag it as inheriting its backface
    culling from its parent.
* platform/graphics/chromium/LayerChromium.cpp:
    (WebCore::LayerChromium::LayerChromium):
        Initialize new m_useParentBackfaceVisibility member variable.
    (WebCore::LayerChromium::pushPropertiesTo):
        Propagate m_useParentBackfaceVisibility to CCLayerImpl.
* platform/graphics/chromium/LayerChromium.h:
    (WebCore::LayerChromium::setUseParentBackfaceVisibility):
    (WebCore::LayerChromium::useParentBackfaceVisibility):
    (LayerChromium):
        Add m_useParentBackfaceVisibility member variable and modify
        and query accessors.
* platform/graphics/chromium/cc/CCLayerImpl.cpp:
    (WebCore::CCLayerImpl::CCLayerImpl):
        Initialize new m_useParentBackfaceVisibility member variable.
* platform/graphics/chromium/cc/CCLayerImpl.h:
    (WebCore::CCLayerImpl::setUseParentBackfaceVisibility):
    (WebCore::CCLayerImpl::useParentBackfaceVisibility):
    (CCLayerImpl):
        Add m_useParentBackfaceVisibility member variable and modify
        and query accessors.
* platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
    (WebCore::layerShouldBeSkipped):
        When examining a layer, if the layer has
        useParentBackfaceVisibility set then use the layer's parent
        layer to determine backface culling.

Source/WebKit/chromium:

* src/WebLayer.cpp:
    (WebKit::WebLayer::setUseParentBackfaceVisibility):
        Add an accessor to specify that a layer should use its parent's
        backface culling behavior.

LayoutTests:

* compositing/backface-visibility/backface-visibility-image-expected.png: Added.
* compositing/backface-visibility/backface-visibility-image-expected.txt: Added.
* compositing/backface-visibility/backface-visibility-image.html: Added.
* compositing/backface-visibility/backface-visibility-webgl-expected.png: Added.
* compositing/backface-visibility/backface-visibility-webgl-expected.txt: Added.
* compositing/backface-visibility/backface-visibility-webgl.html: Added.

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

8 years agonew-run-webkit-tests should spin-up enough httpd processes to avoid timeouts
dpranke@chromium.org [Wed, 20 Jun 2012 19:00:48 +0000 (19:00 +0000)]
new-run-webkit-tests should spin-up enough httpd processes to avoid timeouts
https://bugs.webkit.org/show_bug.cgi?id=88134

Reviewed by Tony Chang.

Change NRWT to spin up 2*min(child_processes, locked_shards)
http servers by default so that we are less likely to get a
bunch of http timeouts at the beginning of a test run.

Note that I had to tweak executive_mock to support mocked stderr
because the apache_http_server code reads stderr when starting a
process to ensure it started okay.

* Scripts/webkitpy/common/system/executive_mock.py:
(MockProcess.__init__):
* Scripts/webkitpy/common/system/outputcapture.py:
* Scripts/webkitpy/layout_tests/controllers/manager.py:
(Manager._run_tests):
(Manager.start_servers_with_lock):
* Scripts/webkitpy/layout_tests/port/base.py:
(Port.to.start_http_server):
* Scripts/webkitpy/layout_tests/port/test.py:
(TestPort.start_http_server):
(TestPort._path_to_apache):
(TestPort):
(TestPort._path_to_apache_config_file):
* Scripts/webkitpy/layout_tests/servers/apache_http_server.py:
(LayoutTestApacheHttpd.__init__):
* Scripts/webkitpy/layout_tests/servers/apache_http_server_unittest.py: Added
(LayoutTestApacheHttpd.__init__):
* Scripts/webkitpy/layout_tests/servers/http_server.py:
(Lighttpd.__init__):
* Scripts/webkitpy/layout_tests/servers/http_server_base.py:
(HttpServerBase.__init__):

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

8 years agoSource/WebCore: Don't re-enter CachedResource::removeClient() if an XHR
japhet@chromium.org [Wed, 20 Jun 2012 18:42:51 +0000 (18:42 +0000)]
Source/WebCore: Don't re-enter CachedResource::removeClient() if an XHR
is canceled and restarted multiple times.
https://bugs.webkit.org/show_bug.cgi?id=89378

Reviewed by Eric Seidel.

Test: http/tests/xmlhttprequest/reentrant-cancel.html

* loader/DocumentThreadableLoader.cpp:
(WebCore::DocumentThreadableLoader::cancel):
(WebCore::DocumentThreadableLoader::clearResource): Save off a copy of m_resource
   then clear it, so we don't call clearResource() multiple times for the same resource.

LayoutTests: Test for https://bugs.webkit.org/show_bug.cgi?id=89378.
Reviewed by Eric Seidel.

* http/tests/xmlhttprequest/reentrant-cancel-expected.txt: Added.
* http/tests/xmlhttprequest/reentrant-cancel.html: Added.

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

8 years agoNegative margin block doesn't properly clear a float enclosed by a previous sibling
robert@webkit.org [Wed, 20 Jun 2012 18:40:09 +0000 (18:40 +0000)]
Negative margin block doesn't properly clear a float enclosed by a previous sibling
https://bugs.webkit.org/show_bug.cgi?id=10900

Reviewed by Eric Seidel.

Source/WebCore:

Tests: fast/block/float/previous-sibling-abspos-001.html
       fast/block/float/previous-sibling-abspos-002.html
       fast/block/float/previous-sibling-float-001.html
       fast/block/float/previous-sibling-float-002.html
       fast/css/clear-float-sibling.html

Parent blocks keep a list of child floats that extend out of the parent block and
by implication overhang into the parent's siblings. But this doesn't work if the
sibling has collapsing margins - it will not find the float in the previous block's
list so will ignore the float and fail to clear it.

RenderBlock:collapseMargins() needs to check if a child's collapsing margin has
reduced the height of the parent up past the bottom of its previous sibling's lowest float
and add the now overhanging float to the parent's float list if appropriate. No need to do
this if the previous sibling is a float or is positioned - the child will clear/avoid it anyway
and attempting to avoid floated children of floats causes incorrect layout.

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

LayoutTests:

* fast/block/float/previous-sibling-abspos-001-expected.html: Added.
* fast/block/float/previous-sibling-abspos-001.html: Added.
* fast/block/float/previous-sibling-abspos-002-expected.html: Added.
* fast/block/float/previous-sibling-abspos-002.html: Added.
* fast/block/float/previous-sibling-float-001-expected.html: Added.
* fast/block/float/previous-sibling-float-001.html: Added.
* fast/block/float/previous-sibling-float-002-expected.html: Added.
* fast/block/float/previous-sibling-float-002.html: Added.
* fast/css/clear-float-sibling-expected.html: Added.
* fast/css/clear-float-sibling.html: Added.

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

8 years agoWeb Inspector: Allow module injections into the InjectedScript
commit-queue@webkit.org [Wed, 20 Jun 2012 18:28:05 +0000 (18:28 +0000)]
Web Inspector: Allow module injections into the InjectedScript
https://bugs.webkit.org/show_bug.cgi?id=89530

Add a new InjectedScriptModule abstract class that inherits InjectedScriptBase
to reuse implementation, and which javascript code is injected via
InjectedScript.

Patch by Andrey Adaikin <aandrey@chromium.org> on 2012-06-20
Reviewed by Pavel Feldman.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.gypi:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.xcodeproj/project.pbxproj:
* bindings/js/ScriptObject.cpp:
(WebCore::ScriptObject::ScriptObject):
(WebCore):
* bindings/js/ScriptObject.h:
(ScriptObject):
(WebCore::ScriptObject::ScriptObject):
* bindings/v8/ScriptObject.cpp:
(WebCore::ScriptObject::ScriptObject):
(WebCore):
* bindings/v8/ScriptObject.h:
(ScriptObject):
(WebCore::ScriptObject::~ScriptObject):
* inspector/InjectedScript.cpp:
* inspector/InjectedScript.h:
(WebCore):
(WebCore::InjectedScript::name):
(InjectedScript):
* inspector/InjectedScriptBase.cpp:
(WebCore::InjectedScriptBase::callFunctionWithEvalEnabled):
* inspector/InjectedScriptBase.h:
(WebCore):
(InjectedScriptBase):
* inspector/InjectedScriptManager.h:
(InjectedScriptManager):
(WebCore::InjectedScriptManager::inspectedStateAccessCheck):
* inspector/InjectedScriptModule.cpp: Copied from Source/WebCore/inspector/InjectedScriptBase.h.
(WebCore):
(WebCore::InjectedScriptModule::InjectedScriptModule):
(WebCore::InjectedScriptModule::ensureInjected):
* inspector/InjectedScriptModule.h: Copied from Source/WebCore/bindings/js/ScriptObject.h.
(WebCore):
(InjectedScriptModule):
* inspector/InjectedScriptSource.js:
(.):

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

8 years agoMade the incremental sweeper more aggressive
ggaren@apple.com [Wed, 20 Jun 2012 18:24:02 +0000 (18:24 +0000)]
Made the incremental sweeper more aggressive
https://bugs.webkit.org/show_bug.cgi?id=89527

Reviewed by Oliver Hunt.

This is a pre-requisite to getting rid of "berzerker GC" because we need
the sweeper to reclaim memory in a timely fashion, or we'll see a memory
footprint regression.

* heap/IncrementalSweeper.h:
* heap/IncrementalSweeper.cpp:
(JSC::IncrementalSweeper::scheduleTimer): Since the time slice is predictable,
no need to use a data member to record it.

(JSC::IncrementalSweeper::doSweep): Sweep as many blocks as we can in a
small time slice. This is better than sweeping only one block per timer
fire because that strategy has a heavy timer overhead, and artificially
delays memory reclamation.

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

8 years ago[BlackBerry] Enable setAcceleratedCompositingForFixedPositionEnabled
commit-queue@webkit.org [Wed, 20 Jun 2012 18:18:47 +0000 (18:18 +0000)]
[BlackBerry] Enable setAcceleratedCompositingForFixedPositionEnabled
https://bugs.webkit.org/show_bug.cgi?id=89575

Patch by Konrad Piascik <kpiascik@rim.com> on 2012-06-20
Reviewed by Antonio Gomes.

Enable the flag so that we get position:fixed elemetns to be rendered
using accelerated compositing.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::init):

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

8 years agoWeb Inspector: Timeline label bar jiggles when scrolling
pfeldman@chromium.org [Wed, 20 Jun 2012 18:11:09 +0000 (18:11 +0000)]
Web Inspector: Timeline label bar jiggles when scrolling
https://bugs.webkit.org/show_bug.cgi?id=89579

Reviewed by Vsevolod Vlasov.

Adding timeline header into the timeline panel and settings its position
to absolute. Drive-by fix that updates rulers on sidebar resize.

* inspector/front-end/TimelineGrid.js:
(WebInspector.TimelineGrid):
(WebInspector.TimelineGrid.prototype.get gridHeaderElement):
(WebInspector.TimelineGrid.prototype.addEventDividers):
(WebInspector.TimelineGrid.prototype.setScrollAndDividerTop):
* inspector/front-end/TimelineOverviewPane.js:
(WebInspector.TimelineOverviewPane.prototype.sidebarResized):
* inspector/front-end/TimelinePanel.js:
(WebInspector.TimelinePanel):
(WebInspector.TimelinePanel.prototype.sidebarResized):
(WebInspector.TimelinePanel.prototype.onResize):
* inspector/front-end/timelinePanel.css:
(#timeline-grid-header):

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

8 years ago[chromium] Make sure that render surfaces are not pixel doubled with a device scale...
commit-queue@webkit.org [Wed, 20 Jun 2012 17:58:09 +0000 (17:58 +0000)]
[chromium] Make sure that render surfaces are not pixel doubled with a device scale factor of 2
https://bugs.webkit.org/show_bug.cgi?id=86882

Patch by Ian Vollick <vollick@chromium.org> on 2012-06-20
Reviewed by Adrienne Walker.

To ensure that render surfaces are not pixel doubled when device scale factor is
two, the render surface's owning layer's draw transform is scaled by the
contents scale (in the same way that the parent matrix is scaled by the device
scale factor). The transformedLayerRect's dimensions also need to be in pixel
space. The surface origin transform should not scale, but needs to offset the
correct number of pixels, and the replica transforms need to be modified to
account for the scaling.

Source/WebCore:

To accomplish this, CCLayerImpl's needed to be made aware of contentsScale.

Thanks to Adrienne Walker for the computation of the replica draw transform.

Unit test: CCLayerTreeHostCommonTest.verifyRenderSurfaceTranformsInHighDPI

* platform/graphics/chromium/LayerChromium.cpp:
(WebCore::LayerChromium::pushPropertiesTo):
* platform/graphics/chromium/LayerChromium.h:
(LayerChromium):
* platform/graphics/chromium/cc/CCLayerImpl.cpp:
(WebCore::CCLayerImpl::CCLayerImpl):
* platform/graphics/chromium/cc/CCLayerImpl.h:
(WebCore::CCLayerImpl::setContentsScale):
(WebCore::CCLayerImpl::contentsScale):
(CCLayerImpl):
* platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
(WebCore::calculateDrawTransformsInternal):
* platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
(WebCore::CCScrollbarLayerImpl::CCScrollbar::totalSize):

Source/WebKit/chromium:

* tests/CCLayerTreeHostCommonTest.cpp:

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

8 years agoFix JSC ChangeLog, forgot to add a comment to the ChangeLog before committing.
fpizlo@apple.com [Wed, 20 Jun 2012 17:51:07 +0000 (17:51 +0000)]
Fix JSC ChangeLog, forgot to add a comment to the ChangeLog before committing.

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

8 years ago[CSS3 Backgrounds and Borders] Implement box-decoration-break rendering.
alexis.menard@openbossa.org [Wed, 20 Jun 2012 17:49:18 +0000 (17:49 +0000)]
[CSS3 Backgrounds and Borders] Implement box-decoration-break rendering.
https://bugs.webkit.org/show_bug.cgi?id=88228

Reviewed by Eric Seidel.

Source/WebCore:

Implement the new CSS property box-decoration-break. It modifies
where we decide whether the borders needs to be sliced or not by
checking if the box-decoration-break is set to clone. If it's the case
then we need to explicitely redraw all edges.

Test: fast/box-decoration-break/box-decoration-break-rendering.html

* rendering/InlineFlowBox.cpp:
(WebCore::InlineFlowBox::determineSpacingForFlowBoxes):
(WebCore::InlineFlowBox::paintFillLayer):

LayoutTests:

Add new tests to cover the feature.

* fast/box-decoration-break/box-decoration-break-rendering-expected.html: Added.
* fast/box-decoration-break/box-decoration-break-rendering.html: Added.

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

8 years agoDFG should be able to print disassembly interleaved with the IR
fpizlo@apple.com [Wed, 20 Jun 2012 17:48:23 +0000 (17:48 +0000)]
DFG should be able to print disassembly interleaved with the IR
https://bugs.webkit.org/show_bug.cgi?id=89551

Reviewed by Geoffrey Garen.

* CMakeLists.txt:
* GNUmakefile.list.am:
* JavaScriptCore.xcodeproj/project.pbxproj:
* Target.pri:
* assembler/ARMv7Assembler.h:
(JSC::ARMv7Assembler::labelIgnoringWatchpoints):
(ARMv7Assembler):
* assembler/AbstractMacroAssembler.h:
(AbstractMacroAssembler):
(JSC::AbstractMacroAssembler::labelIgnoringWatchpoints):
* assembler/X86Assembler.h:
(X86Assembler):
(JSC::X86Assembler::labelIgnoringWatchpoints):
* dfg/DFGCommon.h:
(JSC::DFG::shouldShowDisassembly):
(DFG):
* dfg/DFGDisassembler.cpp: Added.
(DFG):
(JSC::DFG::Disassembler::Disassembler):
(JSC::DFG::Disassembler::dump):
(JSC::DFG::Disassembler::dumpDisassembly):
* dfg/DFGDisassembler.h: Added.
(DFG):
(Disassembler):
(JSC::DFG::Disassembler::setStartOfCode):
(JSC::DFG::Disassembler::setForBlock):
(JSC::DFG::Disassembler::setForNode):
(JSC::DFG::Disassembler::setEndOfMainPath):
(JSC::DFG::Disassembler::setEndOfCode):
* dfg/DFGDriver.cpp:
(JSC::DFG::compile):
* dfg/DFGGraph.cpp:
(JSC::DFG::Graph::dumpCodeOrigin):
(JSC::DFG::Graph::amountOfNodeWhiteSpace):
(DFG):
(JSC::DFG::Graph::printNodeWhiteSpace):
(JSC::DFG::Graph::dump):
(JSC::DFG::Graph::dumpBlockHeader):
* dfg/DFGGraph.h:
* dfg/DFGJITCompiler.cpp:
(JSC::DFG::JITCompiler::JITCompiler):
(DFG):
(JSC::DFG::JITCompiler::compile):
(JSC::DFG::JITCompiler::compileFunction):
* dfg/DFGJITCompiler.h:
(JITCompiler):
(JSC::DFG::JITCompiler::setStartOfCode):
(JSC::DFG::JITCompiler::setForBlock):
(JSC::DFG::JITCompiler::setForNode):
(JSC::DFG::JITCompiler::setEndOfMainPath):
(JSC::DFG::JITCompiler::setEndOfCode):
* dfg/DFGNode.h:
(Node):
(JSC::DFG::Node::willHaveCodeGen):
* dfg/DFGNodeFlags.cpp:
(JSC::DFG::nodeFlagsAsString):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT.h:
(SpeculativeJIT):
* runtime/Options.cpp:
(Options):
(JSC::Options::initializeOptions):
* runtime/Options.h:
(Options):

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