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

Unified Diff: content/common/view_messages.h

Issue 10941015: [Android] Upstream the WebView find-in-page API implementation. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: nit fixes. Created 8 years, 3 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
« no previous file with comments | « content/browser/renderer_host/render_view_host_impl.cc ('k') | content/public/browser/render_view_host.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/view_messages.h
diff --git a/content/common/view_messages.h b/content/common/view_messages.h
index 6751e30f02349f71dc8b5d3d78057d876e5048f2..f4e12ad3eff11d6d4a62e98966e39305329b8ddc 100644
--- a/content/common/view_messages.h
+++ b/content/common/view_messages.h
@@ -867,28 +867,6 @@ IPC_SYNC_MESSAGE_CONTROL0_1(ViewHostMsg_GetMonitorColorProfile,
IPC_MESSAGE_CONTROL1(ViewMsg_New,
ViewMsg_New_Params)
-#if defined(OS_ANDROID)
-// Sent when the user clicks on the find result bar to activate a find result.
-// The point (x,y) is in fractions of the content document's width and height.
-IPC_MESSAGE_ROUTED3(ViewMsg_ActivateNearestFindResult,
- int /* request_id */,
- float /* x */,
- float /* y */)
-
-// Sent when the browser wants the bounding boxes of the current find matches.
-//
-// If match rects are already cached on the browser side, |current_version|
-// should be the version number from the ViewHostMsg_FindMatchRects_Reply
-// they came in, so the renderer can tell if it needs to send updated rects.
-// Otherwise just pass -1 to always receive the list of rects.
-//
-// There must be an active search string (it is probably most useful to call
-// this immediately after a ViewHostMsg_Find_Reply message arrives with
-// final_update set to true).
-IPC_MESSAGE_ROUTED1(ViewMsg_FindMatchRects,
- int /* current_version */)
-#endif
-
// Reply in response to ViewHostMsg_ShowView or ViewHostMsg_ShowWidget.
// similar to the new command, but used when the renderer created a view
// first, and we need to update it.
@@ -1134,16 +1112,6 @@ IPC_MESSAGE_ROUTED2(ViewMsg_CSSInsertRequest,
string16, /* frame_xpath */
std::string /* css string */)
-// External popup menus.
-#if defined(OS_MACOSX)
-IPC_MESSAGE_ROUTED1(ViewMsg_SelectPopupMenuItem,
- int /* selected index, -1 means no selection */)
-#elif defined(OS_ANDROID)
-IPC_MESSAGE_ROUTED2(ViewMsg_SelectPopupMenuItems,
- bool /* user canceled the popup */,
- std::vector<int> /* selected indices */)
-#endif
-
// Change the zoom level for the current main frame. If the level actually
// changes, a ViewHostMsg_DidZoomURL message will be sent back to the browser
// telling it what url got zoomed and what its current zoom level is.
@@ -1351,27 +1319,6 @@ IPC_MESSAGE_ROUTED1(ViewMsg_SetActive,
IPC_MESSAGE_ROUTED1(ViewMsg_SetNavigationStartTime,
base::TimeTicks /* browser_navigation_start */)
-#if defined(OS_MACOSX)
-// Let the RenderView know its window has changed visibility.
-IPC_MESSAGE_ROUTED1(ViewMsg_SetWindowVisibility,
- bool /* visibile */)
-
-// Let the RenderView know its window's frame has changed.
-IPC_MESSAGE_ROUTED2(ViewMsg_WindowFrameChanged,
- gfx::Rect /* window frame */,
- gfx::Rect /* content view frame */)
-
-// Message sent from the browser to the renderer when the user starts or stops
-// resizing the view.
-IPC_MESSAGE_ROUTED1(ViewMsg_SetInLiveResize,
- bool /* enable */)
-
-// Tell the renderer that plugin IME has completed.
-IPC_MESSAGE_ROUTED2(ViewMsg_PluginImeCompositionCompleted,
- string16 /* text */,
- int /* plugin_id */)
-#endif
-
// Response message to ViewHostMsg_CreateShared/DedicatedWorker.
// Sent when the worker has started.
IPC_MESSAGE_ROUTED0(ViewMsg_WorkerCreated)
@@ -1426,6 +1373,72 @@ IPC_MESSAGE_CONTROL1(ViewMsg_TempCrashWithData,
IPC_MESSAGE_ROUTED1(ViewMsg_SetAccessibilityMode,
AccessibilityMode)
+#if defined(OS_ANDROID)
+// Sent when the user clicks on the find result bar to activate a find result.
+// The point (x,y) is in fractions of the content document's width and height.
+IPC_MESSAGE_ROUTED3(ViewMsg_ActivateNearestFindResult,
+ int /* request_id */,
+ float /* x */,
+ float /* y */)
+
+// Sent when the browser wants the bounding boxes of the current find matches.
+//
+// If match rects are already cached on the browser side, |current_version|
+// should be the version number from the ViewHostMsg_FindMatchRects_Reply
+// they came in, so the renderer can tell if it needs to send updated rects.
+// Otherwise just pass -1 to always receive the list of rects.
+//
+// There must be an active search string (it is probably most useful to call
+// this immediately after a ViewHostMsg_Find_Reply message arrives with
+// final_update set to true).
+IPC_MESSAGE_ROUTED1(ViewMsg_FindMatchRects,
+ int /* current_version */)
+
+// Sent when the user wants to search for all occurrences of a word or find
+// the next result in a synchronous way. This method forces the UI thread in
+// the browser to wait for the renderer to reply, therefore blocking the UI.
+//
+// This functionality is required for compatibility with the legacy Android
+// WebView API. As this goes strongly against the Chromium design guidelines,
+// don't use this as inspiration.
+//
+IPC_SYNC_MESSAGE_ROUTED3_2(ViewMsg_SynchronousFind,
+ int /* request_id */,
+ string16 /* search_string */,
+ WebKit::WebFindOptions /* options */,
+ int /* match_count */,
+ int /* active_ordinal */)
+
+// External popup menus.
+IPC_MESSAGE_ROUTED2(ViewMsg_SelectPopupMenuItems,
+ bool /* user canceled the popup */,
+ std::vector<int> /* selected indices */)
+
+#elif defined(OS_MACOSX)
+// Let the RenderView know its window has changed visibility.
+IPC_MESSAGE_ROUTED1(ViewMsg_SetWindowVisibility,
+ bool /* visibile */)
+
+// Let the RenderView know its window's frame has changed.
+IPC_MESSAGE_ROUTED2(ViewMsg_WindowFrameChanged,
+ gfx::Rect /* window frame */,
+ gfx::Rect /* content view frame */)
+
+// Message sent from the browser to the renderer when the user starts or stops
+// resizing the view.
+IPC_MESSAGE_ROUTED1(ViewMsg_SetInLiveResize,
+ bool /* enable */)
+
+// Tell the renderer that plugin IME has completed.
+IPC_MESSAGE_ROUTED2(ViewMsg_PluginImeCompositionCompleted,
+ string16 /* text */,
+ int /* plugin_id */)
+
+// External popup menus.
+IPC_MESSAGE_ROUTED1(ViewMsg_SelectPopupMenuItem,
+ int /* selected index, -1 means no selection */)
+#endif
+
// -----------------------------------------------------------------------------
// Messages sent from the renderer to the browser.
@@ -1984,15 +1997,6 @@ IPC_SYNC_MESSAGE_ROUTED1_0(ViewHostMsg_DestroyPluginContainer,
gfx::PluginWindowHandle /* id */)
#endif
-#if defined(OS_MACOSX)
-// Request that the browser load a font into shared memory for us.
-IPC_SYNC_MESSAGE_CONTROL1_3(ViewHostMsg_LoadFont,
- FontDescriptor /* font to load */,
- uint32 /* buffer size */,
- base::SharedMemoryHandle /* font data */,
- uint32 /* font id */)
-#endif
-
// Send the tooltip text for the current mouse position to the browser.
IPC_MESSAGE_ROUTED2(ViewHostMsg_SetTooltipText,
string16 /* tooltip text string */,
@@ -2124,6 +2128,13 @@ IPC_MESSAGE_CONTROL1(ViewHostMsg_SuddenTerminationChanged,
bool /* enabled */)
#if defined(OS_MACOSX)
+// Request that the browser load a font into shared memory for us.
+IPC_SYNC_MESSAGE_CONTROL1_3(ViewHostMsg_LoadFont,
+ FontDescriptor /* font to load */,
+ uint32 /* buffer size */,
+ base::SharedMemoryHandle /* font data */,
+ uint32 /* font id */)
+
// On OSX, we cannot allocated shared memory from within the sandbox, so
// this call exists for the renderer to ask the browser to allocate memory
// on its behalf. We return a file descriptor to the POSIX shared memory.
@@ -2292,12 +2303,6 @@ IPC_MESSAGE_ROUTED3(ViewHostMsg_SendSerializedHtmlData,
std::string /* data buffer */,
int32 /* complete status */)
-#if defined(OS_ANDROID)
-// Start an android intent with the given URI.
-IPC_MESSAGE_ROUTED1(ViewHostMsg_StartContentIntent,
- GURL /* content_url */)
-#endif
-
// Notifies the browser of an event occurring in the media pipeline.
IPC_MESSAGE_CONTROL1(ViewHostMsg_MediaLogEvent,
media::MediaLogEvent /* event */)
@@ -2391,6 +2396,10 @@ IPC_MESSAGE_ROUTED3(ViewHostMsg_FindMatchRects_Reply,
std::vector<gfx::RectF> /* rects */,
gfx::RectF /* active_rect */)
+// Start an android intent with the given URI.
+IPC_MESSAGE_ROUTED1(ViewHostMsg_StartContentIntent,
+ GURL /* content_url */)
+
// Messages for notifying the render process of media playback status -------
// Media buffering has updated.
« no previous file with comments | « content/browser/renderer_host/render_view_host_impl.cc ('k') | content/public/browser/render_view_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698