Index: components/web_view/public/interfaces/frame.mojom |
diff --git a/components/web_view/public/interfaces/frame.mojom b/components/web_view/public/interfaces/frame.mojom |
index d1a8f807d534260783d2a4a4360947c4c1cd74ef..a98c5f67c2cffbd6d4074bdfbf188327c196dc89 100644 |
--- a/components/web_view/public/interfaces/frame.mojom |
+++ b/components/web_view/public/interfaces/frame.mojom |
@@ -110,6 +110,13 @@ interface Frame { |
// Dispatches a load event to the parent of the frame. |
DispatchLoadEventToParent(); |
+ |
+ // Reports the number of matches for a given find. |
+ OnReportFindInFrameMatchCount(int32 request_id, int32 count, |
+ bool final_update); |
+ |
+ // Reports which match is currently highlighted. |
+ OnReportFindInPageSelection(int32 request_id, int32 active_match_ordinal); |
}; |
enum ViewConnectType { |
@@ -166,4 +173,20 @@ interface FrameClient { |
// Called to dispatch a load event of |frame_id| in its parent. This is only |
// called on the FrameClient rendering the parent of |frame_id|. |
OnDispatchFrameLoadEvent(uint32 frame_id); |
+ |
+ // TODO(erg): Several of these take a WebFindOptions struct; we probably need |
+ // to build a Frame version of that struct. |
+ |
+ // Searches for a given string synchronously. If a match is found, it will be |
+ // selected. Returns true if the search string was found, false otherwise. |
+ Find(int32 request_id, string search_text) => |
+ (int32 request_id, string search_text, bool found); |
sky
2015/10/02 16:03:40
Does the callback really need a request_id too? Ca
Elliot Glaysher
2015/10/02 21:42:33
I put that data in a Bind() on the mojo::WebView s
|
+ |
+ // Stop highlighting the find results on the page. |
+ StopFinding(bool clear_selection); |
+ |
+ // Counts how many times a particular string occurs within a frame. |
+ ScopeStringMatches(int32 request_id, string search_test, bool reset); |
sky
2015/10/02 16:03:40
What does 'Scope' mean in this context?
Could thi
Elliot Glaysher
2015/10/02 21:42:33
It's an opaque name from blink. I totally agree wi
|
+ |
+ CancelPendingScopingEffort(); |
}; |