Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(140)

Unified Diff: third_party/WebKit/public/web/WebLocalFrame.h

Issue 1959183002: Multi-Process Find-in-Page. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/public/web/WebLocalFrame.h
diff --git a/third_party/WebKit/public/web/WebLocalFrame.h b/third_party/WebKit/public/web/WebLocalFrame.h
index 1b47bdfa652ead547059ffba359dc912d5970c47..03f39d50a0690ddd2537ed176735a50ae09ae227 100644
--- a/third_party/WebKit/public/web/WebLocalFrame.h
+++ b/third_party/WebKit/public/web/WebLocalFrame.h
@@ -71,6 +71,9 @@ public:
// navigation. This matches the in-process frame behavior.
virtual void setFrameOwnerProperties(const WebFrameOwnerProperties&) = 0;
+ // Returns true if the frame is focused.
+ virtual bool isFocused() const = 0;
+
// Hierarchy ----------------------------------------------------------
// Get the highest-level LocalFrame in this frame's in-process subtree.
@@ -294,24 +297,32 @@ public:
virtual WebFloatRect activeFindMatchRect() = 0;
// Swaps the contents of the provided vector with the bounding boxes of the
- // find-in-page match markers from all frames. The bounding boxes are returned
- // in find-in-page coordinates. This method should be called only on the main frame.
+ // find-in-page match markers from all frames. The bounding boxes are
+ // returned in find-in-page coordinates. This method should be called only
+ // on the main frame.
virtual void findMatchRects(WebVector<WebFloatRect>&) = 0;
- // Selects the find-in-page match in the appropriate frame closest to the
- // provided point in find-in-page coordinates. Returns the ordinal of such
- // match or -1 if none could be found. If not null, selectionRect is set to
- // the bounding box of the selected match in window coordinates.
- // This method should be called only on the main frame.
+ // Selects the find-in-page match closest to the provided point in
+ // find-in-page coordinates. Returns the ordinal of such match or -1 if none
+ // could be found. If not null, selectionRect is set to the bounding box of
+ // the selected match in window coordinates. This method should be called
+ // only on the main frame.
virtual int selectNearestFindMatch(const WebFloatPoint&,
WebRect* selectionRect)
= 0;
+ // Returns the distance (squared) to the closest find-in-page match from the
+ // provided point, in find-in-page coordinates.
+ virtual float nearestFindMatch(const WebFloatPoint&) = 0;
+
// Set the tickmarks for the frame. This will override the default tickmarks
// generated by find results. If this is called with an empty array, the
// default behavior will be restored.
virtual void setTickmarks(const WebVector<WebRect>&) = 0;
+ // Clears the active find match in the frame, if one exists.
+ virtual void clearActiveFindMatch() = 0;
+
// Context menu -----------------------------------------------------------
// Returns the node that the context menu opened over.

Powered by Google App Engine
This is Rietveld 408576698