[BlackBerry] Find-on-page should be able to convert the active match to selection when clearing all matches
https://bugs.webkit.org/show_bug.cgi?id=116837

Patch by Andy Chen <andchen@blackberry.com> on 2013-05-27
Reviewed by Rob Buis.

PR 291903
Internally reviewed by Mike Fenton.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPage::findNextString):
* Api/WebPage.h:
* WebKitSupport/InPageSearchManager.cpp:
(BlackBerry::WebKit::InPageSearchManager::findNextString):
(BlackBerry::WebKit::InPageSearchManager::clearTextMatches):
* WebKitSupport/InPageSearchManager.h:
(InPageSearchManager):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@150770 268f45cc-cd09-0410-ab3c-d52691b4dbfc
PDFPlugin: Main-frame PDFPlugin Accessibility
https://bugs.webkit.org/show_bug.cgi?id=116563
<rdar://problem/13458534>

Reviewed by Sam Weinig.

* WebProcess/Plugins/PDF/PDFLayerControllerDetails.h:
Forward-declare a variety of accessibility methods.

* WebProcess/Plugins/PDF/PDFPlugin.h:
Add convertFromPDFViewToScreen, boundsOnScreen, accessibilityObject, and
storage for our accessibility wrapper.
* WebProcess/Plugins/PDF/PDFPlugin.mm:
Add WKPDFPluginAccessibilityObject.

(-[WKPDFPluginAccessibilityObject accessibilityIsIgnored]):
We want to be included in the accessibility tree.

(-[WKPDFPluginAccessibilityObject accessibilityAttributeValue:]):
(-[WKPDFPluginAccessibilityObject accessibilityAttributeValue:forParameter:]):
Grab values for accessibility attributes from the relevant sources
(mostly from PDFLayerController).

(-[WKPDFPluginAccessibilityObject readingModel]): Ditto.
(-[WKPDFPluginAccessibilityObject accessibilityAttributeNames]):
(-[WKPDFPluginAccessibilityObject accessibilityParameterizedAttributeNames]):
(-[WKPDFPluginAccessibilityObject accessibilityActionNames]):
Return the set of accessibility attributes, actions, and parameterized
attributes that we support.

(-[WKPDFPluginAccessibilityObject accessibilityIsAttributeSettable:]):
(-[WKPDFPluginAccessibilityObject accessibilitySetValue:forAttribute:]):
Forward some other accessibility methods to PDFLayerController.

(-[WKPDFPluginAccessibilityObject accessibilityFocusedUIElement]):
(-[WKPDFPluginAccessibilityObject accessibilityHitTest:]):
We have no children, so if a hit test makes it to us, it's ours.

(WebKit::PDFPlugin::PDFPlugin):
Make a WKPDFPluginAccessibilityObject and hook it up.
[FIXME: this could use some de-crapifying]

(WebKit::PDFPlugin::convertFromPluginToPDFView):
Transform a point from plugin space to PDFLayerController space.

(WebKit::PDFPlugin::convertFromPDFViewToRootView):
(WebKit::PDFPlugin::convertFromPDFViewToScreen): Added.
(WebKit::PDFPlugin::boundsOnScreen):
Return the PDFPlugin's frame in screen coordinates.

(WebKit::PDFPlugin::accessibilityObject):
Return our accessibility wrapper.

* WebProcess/Plugins/PDF/SimplePDFPlugin.h:
* WebProcess/Plugins/Plugin.h:
(WebKit::Plugin::accessibilityObject):
* WebProcess/Plugins/PluginView.cpp:
(WebKit::PluginView::accessibilityObject):
* WebProcess/Plugins/PluginView.h:
Add accessibilityObject(), to acquire accessibility wrappers from plugins.

* WebProcess/WebPage/WebPage.h:
(WebPage): Add accessibilityObjectForMainFramePlugin();
* WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm:
(-[WKAccessibilityWebPageObject accessibilityRootObjectWrapper]):
If the main frame has a PluginDocument that has an accessibilityObject,
use that one instead of the WebPage's.

* WebProcess/WebPage/mac/WebPageMac.mm:
(WebKit::WebPage::accessibilityObjectForMainFramePlugin):
Return the accessibilityObject from the main-frame PluginDocument, if
there is one.

* WebCore.exp.in: Export AffineTransform::mapRect.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@150771 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Move Windows port off legacy clipboard.
https://bugs.webkit.org/show_bug.cgi?id=116258

Patch by Xueqing Huang <huangxueqing@baidu.com> on 2013-05-27
Reviewed by Darin Adler.

Source/WebCore:

Clipboard refactor, no new tests.

* dom/Clipboard.h:
* page/win/EventHandlerWin.cpp:
(WebCore::EventHandler::createDraggingClipboard): Create Clipboard instead of ClipboardWin.
* platform/Pasteboard.h:
(WebCore::Pasteboard::dataObject): Get IDataObject by Clipborad.
(WebCore::Pasteboard::writableDataObject): Get WCDataObject by Clipborad.
* platform/win/ClipboardWin.cpp:
(WebCore::Clipboard::createDragImage): Change parameter name loc to dragLocation.
(WebCore::Clipboard::declareAndWriteDragImage): Implement declareAndWriteDragImage use WCDataObject exposed by Pasteboard.
* platform/win/ClipboardWin.h: Removed.
* platform/win/EditorWin.cpp:
(WebCore::Editor::newGeneralClipboard): Create Clipboard instead of ClipboardWin.
* platform/win/PasteboardWin.cpp:
(WebCore::Pasteboard::createForCopyAndPaste): Create a Pasteboard.
(WebCore::Pasteboard::createPrivate): Ditto.
(WebCore::Pasteboard::createForDragAndDrop): Ditto.
(WebCore::Pasteboard::finishCreatingPasteboard): Create Pasteboard use Windows API.
(WebCore::Pasteboard::Pasteboard):
(WebCore::clipboardTypeFromMIMEType): Copied from ClipboardWin.cpp.
(WebCore::Pasteboard::clear): Ditto.
(WebCore::Pasteboard::hasData): Ditto.
(WebCore::addMimeTypesForFormat): Ditto.
(WebCore::Pasteboard::types): Ditto.
(WebCore::Pasteboard::readString): Ditto.
(WebCore::Pasteboard::readFilenames): Ditto.
(WebCore::writeURL): Ditto.
(WebCore::Pasteboard::writeString): Ditto.
(WebCore::Pasteboard::setDragImage): Ditto.
(WebCore::Pasteboard::writeRangeToDataObject): Write range to WCDataObject.
(WebCore::Pasteboard::writeSelection):
(WebCore::Pasteboard::writePlainTextToDataObject): Write PlainText to WCDataObject.
(WebCore::Pasteboard::writePlainText):
(WebCore::pathRemoveBadFSCharacters): Copied from ClipboardWin.cpp.
(WebCore::filesystemPathFromUrlOrTitle): Ditto.
(WebCore::writeFileToDataObject): Ditto.
(WebCore::Pasteboard::writeURLToDataObject): Write URL to WCDataObject.
(WebCore::Pasteboard::writeURL): Copied from ClipboardWin.cpp.
(WebCore::Pasteboard::writePasteboard): Copied from Pasteboard::writeClipboard.
(WebCore::Pasteboard::documentFragment): Copied from ClipboardWin.cpp.
(WebCore::Pasteboard::setExternalDataObject): Clipboard can set new IDataObject.
(WebCore::getCachedImage): Copied from ClipboardWin.cpp.
(WebCore::createGlobalImageFileDescriptor): Ditto.
(WebCore::createGlobalImageFileContent): Ditto.
(WebCore::createGlobalHDropContent): Ditto.
(WebCore::Pasteboard::writeImageToDataObject): Expose to make Clipboard implement declareAndWriteDragImage.
(WebCore::Pasteboard::writeURLToWritableDataObject): Ditto.

Source/WebKit/win:

* WebCoreSupport/WebDragClient.cpp:
(WebDragClient::willPerformDragSourceAction): Get IDataObject from Pasteboard instead of Clipboard.
(WebDragClient::startDrag): Ditto.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@150772 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed build fix.

* WebProcess/Plugins/PDF/PDFPlugin.mm:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@150773 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed build fix take 2.

* WebProcess/Plugins/PDF/PDFPlugin.mm:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@150774 268f45cc-cd09-0410-ab3c-d52691b4dbfc
drop-shadow filter with overflow:hidden child misbehaves.
https://bugs.webkit.org/show_bug.cgi?id=109783

Patch by Zalan Bujtas <zalan@apple.com> on 2013-05-27
Reviewed by Simon Fraser.

Applying CSS filters only to the scrollbar rect leaves rendering
artefacts. Filters should skip such partial repaints.

Tests: Test framework uses mock theme for scrollbars. Such scrollbars do not
initiate partial repaints.

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::setupFilters):
(WebCore::RenderLayer::paintLayerContents):
* rendering/RenderLayer.h:
(RenderLayer):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@150775 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CSS] -webkit-var prefix is case-sensitive
https://bugs.webkit.org/show_bug.cgi?id=116829

Reviewed by Darin Adler.

Source/WebCore:

Tests: Added case to fast/css/variables/case-sensitive.html

* css/CSSParser.cpp:
(WebCore::isEqualToCSSCaseSensitiveIdentifier): Add variant to
IsEqualToCSSIdentifier that respects case-sensitivity.
(WebCore::CSSParser::realLex): Use the above method for CSS
variable declarations.

LayoutTests:

* fast/css/variables/case-sensitive.html: Add a
check for case-sensitiveness of the prefix of
variable declarations.
* fast/css/variables/case-sensitive-expected.html: Update.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@150776 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove a leftover Pagepoup from PickerIndicatorElement.h
https://bugs.webkit.org/show_bug.cgi?id=116801

Patch by Seokju Kwon <seokju.kwon@gmail.com> on 2013-05-27
Reviewed by Anders Carlsson.

No new tests, no behavior change.

* html/shadow/PickerIndicatorElement.h:
(WebCore):

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