Remove PLATFORM(IOS) from WebCore/editing (Part 2).
https://bugs.webkit.org/show_bug.cgi?id=136474

Reviewed by Tim Horton.

Removing some more PLATFORM(IOS) from the editing code.
Most of these changes are fixes that were made for IOS but never merged
to OpenSource.

* editing/ApplyStyleCommand.cpp:
(WebCore::ApplyStyleCommand::applyBlockStyle):
* editing/ReplaceSelectionCommand.cpp:
(WebCore::ReplaceSelectionCommand::doApply):
* editing/VisibleSelection.cpp:
(WebCore::VisibleSelection::setStartAndEndFromBaseAndExtentRespectingGranularity):
(WebCore::VisibleSelection::adjustSelectionToAvoidCrossingEditingBoundaries):
* editing/VisibleUnits.cpp:
(WebCore::startOfDocument):
(WebCore::endOfDocument):
* editing/ios/EditorIOS.mm: No need for platform guard, this file is not built for Mac.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@173287 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Address additional review feedback after landing r173283.

Reviewed by Daniel Bates.

* DumpRenderTree/config.h: Removed redundant includes.
* TestWebKitAPI/config.h: Ditto.
* WebKitTestRunner/config.h: Ditto.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@173288 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Clicking on a select element should never hide the popup menu.
https://bugs.webkit.org/show_bug.cgi?id=136548.
<rdar://problem/10215926>
Reviewed by Simon Fraser.
* html/HTMLSelectElement.cpp:
(WebCore::HTMLSelectElement::menuListDefaultEventHandler):
Never call hidePopup as a result of a click on a select element.
The only way you can properly hide a popup is to click again or lose focus on the popup itself.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@173289 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Win] webkitpy test suite frequently fails to complete
https://bugs.webkit.org/show_bug.cgi?id=136546

Reviewed by Daniel Bates.

Properly convert the ASCII crash log produced by ntsd into
a unicode string as early as possible so that we handle it
properly when generating our logs and other test support output.

We were mixing ASCII/unicode strings under Windows, which was
causing test system failures when we processed some crash logs.

Also do a better job of handling garbage pid entries in the
Cygwin lock files.

* Scripts/webkitpy/common/system/crashlogs.py:
(CrashLogs._find_newest_log_win): The ntsd '.logopen' command
creates an ASCII file. Decode it as ASCII, not 'utf-8', and
handle the strings as unicode from that point on.
* Scripts/webkitpy/port/http_lock.py:
(HttpLock._current_lock_pid): Add logging and handle case of
the current_pid failing to cleanly convert to 'int'.
* Scripts/webkitpy/port/win.py:
(WinPort): Add 64-bit architecture as a known target for the
Windows build.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@173290 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Another speculative fix for the bots.

* platform/mac-wk2/tiled-drawing/scrolling/root-overflow-with-mousewheel.html:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@173291 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS] Fix the iOS build after <http://trac.webkit.org/changeset/173258>
(https://bugs.webkit.org/show_bug.cgi?id=136494)

Use ENABLE_TOUCH_EVENT instead of ENABLE(TOUCH_EVENT) as the latter isn't available
to some clients of this private header.

* platform/ios/wak/WAKResponder.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@173292 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Improve the logic for compositing backing store avoidance
https://bugs.webkit.org/show_bug.cgi?id=136556

Reviewed by Dean Jackson.

Source/WebCore:

Avoid backing store allocation in more cases by improving the logic that detects
whether a RenderLayer has any painted, non-layer descendent renderers.

Rename RenderLayer::hasNonEmptyChildRenderers() to hasPaintingNonLayerDescendants(),
and make it recur 3 levels deep, walking child lists of up to 20 siblings looking
for renderers that paint anything. Any renderer with box decorations paints;
replaced elements paint, and non-whitespace text nodes paint. We can avoid
making backing store when whitespace nodes are present only when user-select is none,
since we have to ensure that there's backing store to paint the selection into.

Tests: compositing/backing/inline-block-no-backing.html
       compositing/backing/whitespace-nodes-no-backing.html

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::hasNonEmptyChildRenderers): Call the recursive hasPaintingNonLayerDescendants().
(WebCore::RenderLayer::hasBoxDecorationsOrBackground):
(WebCore::RenderLayer::isVisuallyNonEmpty): Do the cheap tests first. Use isRenderReplaced()
rather than isReplaced(), since the latter includes inline-blocks.
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::updateConfiguration): Don't run the isSimpleContainerCompositingLayer()
logic in the root layer, since it always wants backing store.
(WebCore::RenderLayerBacking::updateAfterDescendents): Ditto.
(WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer): isReplaced() includes
inline-block, so use isRenderReplaced() instead.

LayoutTests:

Tests that dump the layer tree (showing backing store) for various combinations
of child renderers and whitespace.

* compositing/backing/inline-block-no-backing-expected.txt: Added.
* compositing/backing/inline-block-no-backing.html: Added.
* compositing/backing/whitespace-nodes-no-backing-expected.txt: Added.
* compositing/backing/whitespace-nodes-no-backing.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@173293 268f45cc-cd09-0410-ab3c-d52691b4dbfc
CSS filter on a compositing layer should not cause unncessary backing store allocation
https://bugs.webkit.org/show_bug.cgi?id=136557

Reviewed by Dean Jackson.

Source/WebCore:

Remove the style.hasFilter() check from hasBoxDecorations(), since filters aren't
a box decoration. This allows creation of simple container layers with composited filters.

Test: compositing/backing/filter-no-backing.html

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::calculateClipRects):

LayoutTests:

Dump the layer tree on some layer configs with filters.

* compositing/backing/filter-no-backing-expected.txt: Added.
* compositing/backing/filter-no-backing.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@173294 268f45cc-cd09-0410-ab3c-d52691b4dbfc
border-radius should not force layer backing store
https://bugs.webkit.org/show_bug.cgi?id=136555

Reviewed by Dean Jackson.

Source/WebCore:

Border-radius is not a reason to allocate backing store; it's not relevant unless
we also have a border or background, and hasBoxDecorations() already checks for that.

With that gone, we can now use renderer.hasBoxDecorations() (which also checks for
a background), but it doesn't check for outlines, so do that in addition.

Test: compositing/backing/border-radius-no-backing.html

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::calculateClipRects):

LayoutTests:

Test that dumps layers on some composited elements with border-radius

* compositing/backing/border-radius-no-backing-expected.txt: Added.
* compositing/backing/border-radius-no-backing.html: Added.

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