Add support for using the current text selection as the find string on iOS
[WebKit-https.git] / Source / WebKit / UIProcess / ios / WebPageProxyIOS.mm
index f6d304b..d33263d 100644 (file)
@@ -31,6 +31,7 @@
 #import "APIUIClient.h"
 #import "DataReference.h"
 #import "EditingRange.h"
+#import "GlobalFindInPageState.h"
 #import "InteractionInformationAtPosition.h"
 #import "Logging.h"
 #import "NativeWebKeyboardEvent.h"
@@ -226,6 +227,14 @@ void WebPageProxy::resendLastVisibleContentRects()
     m_process->send(Messages::ViewUpdateDispatcher::VisibleContentRectUpdate(m_pageID, m_lastVisibleContentRectUpdate), 0);
 }
 
+void WebPageProxy::updateStringForFind(const String& string)
+{
+    if (!isValid())
+        return;
+
+    WebKit::updateStringForFind(string);
+}
+
 static inline float adjustedUnexposedEdge(float documentEdge, float exposedRectEdge, float factor)
 {
     if (exposedRectEdge < documentEdge)