Add a missing semicolon in WKContentViewInteraction

* UIProcess/ios/WKContentViewInteraction.mm:
(nsSizeForTapHighlightBorderRadius):
I messed up this when fixing the patch on landing.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170612 268f45cc-cd09-0410-ab3c-d52691b4dbfc
WebBackForwardListItems should hold on to PageState objects
https://bugs.webkit.org/show_bug.cgi?id=134467

Reviewed by Darin Adler.

* Shared/WebBackForwardListItem.cpp:
(WebKit::WebBackForwardListItem::WebBackForwardListItem):
(WebKit::WebBackForwardListItem::encode):
* Shared/WebBackForwardListItem.h:
(WebKit::WebBackForwardListItem::setOriginalURL):
(WebKit::WebBackForwardListItem::originalURL):
(WebKit::WebBackForwardListItem::setURL):
(WebKit::WebBackForwardListItem::url):
(WebKit::WebBackForwardListItem::setTitle):
(WebKit::WebBackForwardListItem::title):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170613 268f45cc-cd09-0410-ab3c-d52691b4dbfc
WebBackForwardListItem should not store back-forward data
https://bugs.webkit.org/show_bug.cgi?id=134469

Reviewed by Darin Adler.

Change WebBackForwardListItem::backForwardData to encode the main frame state lazily,
and change WebBackForwardListItem::setBackForwardData to decode it into the main frame state.

* Shared/WebBackForwardListItem.cpp:
(WebKit::WebBackForwardListItem::backForwardData):
(WebKit::WebBackForwardListItem::setBackForwardData):
(WebKit::WebBackForwardListItem::encode):
* Shared/WebBackForwardListItem.h:
(WebKit::WebBackForwardListItem::backForwardData): Deleted.
* UIProcess/cf/WebBackForwardListCF.cpp:
(WebKit::WebBackForwardList::createCFDictionaryRepresentation):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::restoreSession):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170614 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Make TransformIterator::TransformIterator() take rvalue references
https://bugs.webkit.org/show_bug.cgi?id=134468

Reviewed by Darin Adler.

It's unnecessary to support TransformIterator::TransformIterator() taking const lvalue references
as we only call it with rvalues. As a side benefit, we can use move semantics to initialize the
members of TransformIterator.

* wtf/IteratorAdaptors.h:
(WTF::TransformIterator::TransformIterator): Make constructor take arguments as rvalue references.
(WTF::makeTransformIterator): Substitute std::move() for std::forward().

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170615 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Avoid copying function object in lambda function in ScrollingThread::dispatchBarrier(); actually use move semantics
https://bugs.webkit.org/show_bug.cgi?id=134470

Reviewed by Anders Carlsson.

Currently we always copy construct the captured std::function object when calling callOnMainThread()
in the lambda function created in ScrollingThread::dispatchBarrier() because captured variables are
const in a lambda expression's body by default. That is, the std::function object is captured as const.
Instead, we should mark this lambda expression as mutable so the captured std::function object is
non-const and hence we can use move semantics when passing it to callOnMainThread().

* page/scrolling/ScrollingThread.cpp:
(WebCore::ScrollingThread::dispatchBarrier):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170616 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Win] Unreviewed gardening.

* WebCore.vcxproj/WebCore.vcxproj: Do not compile JSFileException
and JSFileReaderSync multiple times.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170617 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS] languageSpecificFallbackFont() is not consistent
https://bugs.webkit.org/show_bug.cgi?id=134473

Reviewed by Darin Adler.

It can use "<" throughout the function as well as keeping the fallthrough behavior consistent.

No tests because there is no behavior change.

* platform/graphics/ios/FontCacheIOS.mm:
(WebCore::languageSpecificFallbackFont):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170618 268f45cc-cd09-0410-ab3c-d52691b4dbfc
All Indic text is rendered as boxes on iOS
https://bugs.webkit.org/show_bug.cgi?id=134464

Reviewed by Simon Fraser.

Source/WebCore:
I made a typo in r170207.

Test: fast/text/indic.html

* platform/graphics/ios/FontCacheIOS.mm:
(WebCore::languageSpecificFallbackFont):

LayoutTests:
Simply draw some indic text and test that against currently good metric values.

* fast/text/indic.html: Added
* platform/ios-sim/fast/text/indic-expected.txt: Added.
* platform/mac/fast/text/indic-expected.txt: Added.
* platform/mac/fast/text/indic-expected.png: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170619 268f45cc-cd09-0410-ab3c-d52691b4dbfc
REGRESSION (WK2): Weird selection behavior on autos.yahoo.com, en.wikipedia.org.
https://bugs.webkit.org/show_bug.cgi?id=134466
<rdar://problem/16817263>

Reviewed by Benjamin Poulain.

Avoid selecting blocks across frame boundaries and skip non-selectable
blocks. If the only block we find is almost the same height as the
visible area, we should not select at all.
This patch also fixes the logic to compute the next block when
shrinking the selection. When calculating the new range after shrinking,
we should not include the block that corresponds to the current handle position.

* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::rangeForWebSelectionAtPosition):
(WebKit::WebPage::expandedRangeFromHandle):
(WebKit::WebPage::contractedRangeFromHandle):
(WebKit::WebPage::updateSelectionWithTouches):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170620 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS][WK2] Do not put tap highlight on images that are not in links, and on applet/embed/object
https://bugs.webkit.org/show_bug.cgi?id=134471
<rdar://problem/17513542>

Reviewed by Enrica Casucci.

UIKit has some special code to avoid tap highlight on certain type of object. This is not very flexible
since the page has no way of overriding that behavior.

This patch implement the same feature by changing the default stylesheet. The tap highlight is disabled
by default for those object, and enabled for images that are in a link.

* css/html.css:
(applet, embed, object, img):
(:-webkit-any-link img):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170621 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS][WK2] Improve double-tap-to-scroll on image documents
https://bugs.webkit.org/show_bug.cgi?id=134474
<rdar://problem/17496778>

Reviewed by Enrica Casucci.

On image document, we were always rendering the center of the image as the origin, which broke
double tap to scroll.

This patch improves on this in two ways:
1) If the hit testing already got the image, only change the type to replaced (to get the right
   scaling behavior for images since the type is block on iOS's image document).
2) If the hit testing is outside the image, only center the axis that is not in the image.
   This way, we "fix" the component that is not valid, and keep the vali component.
   This works great for viewing comics on iPad.

* WebProcess/WebPage/ViewGestureGeometryCollector.cpp:
(WebKit::ViewGestureGeometryCollector::collectGeometryForSmartMagnificationGesture):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170622 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS] GSFontAddCGFont is deprecated and we use it in DumpRenderTree
https://bugs.webkit.org/show_bug.cgi?id=134133

Reviewed by Simon Fraser.

Replace it with CTFontManagerRegisterGraphicsFont

* DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
* DumpRenderTree/mac/DumpRenderTree.mm:
(activateFontIOS):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170623 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[WK2] Add a flatter find-in-page current match indicator style
https://bugs.webkit.org/show_bug.cgi?id=134434
<rdar://problem/16225673>

Reviewed by Simon Fraser.

* UIProcess/FindIndicator.cpp:
(WebKit::findIndicatorsForTextRectsOverlap):
(WebKit::FindIndicator::frameRect):
(WebKit::flatHighlightColor):
(WebKit::flatRimShadowColor):
(WebKit::flatDropShadowColor):
(WebKit::FindIndicator::draw):
Add a flatter find indicator, with a bigger shadow.

* WebProcess/WebPage/FindController.cpp:
(WebKit::FindController::updateFindUIAfterPageScroll):
(WebKit::FindController::getFindIndicatorBitmapAndRect):
(WebKit::FindController::hideFindIndicator):
(WebKit::FindController::drawRect):
Don't paint a shadow behind the secondary matches if we're using the new style.


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