OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_PUBLIC_BROWSER_RENDER_VIEW_HOST_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_RENDER_VIEW_HOST_H_ |
6 #define CONTENT_PUBLIC_BROWSER_RENDER_VIEW_HOST_H_ | 6 #define CONTENT_PUBLIC_BROWSER_RENDER_VIEW_HOST_H_ |
7 | 7 |
8 #include "base/callback_forward.h" | 8 #include "base/callback_forward.h" |
9 #include "content/common/content_export.h" | 9 #include "content/common/content_export.h" |
10 #include "content/public/browser/render_widget_host.h" | 10 #include "content/public/browser/render_widget_host.h" |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 // If any state that affects the webkit preferences changed, this method must | 190 // If any state that affects the webkit preferences changed, this method must |
191 // be called. This triggers recomputing preferences. | 191 // be called. This triggers recomputing preferences. |
192 virtual void OnWebkitPreferencesChanged() = 0; | 192 virtual void OnWebkitPreferencesChanged() = 0; |
193 | 193 |
194 // Passes a list of Webkit preferences to the renderer. | 194 // Passes a list of Webkit preferences to the renderer. |
195 virtual void UpdateWebkitPreferences(const WebPreferences& prefs) = 0; | 195 virtual void UpdateWebkitPreferences(const WebPreferences& prefs) = 0; |
196 | 196 |
197 // Notify the render view host to select the word around the caret. | 197 // Notify the render view host to select the word around the caret. |
198 virtual void SelectWordAroundCaret() = 0; | 198 virtual void SelectWordAroundCaret() = 0; |
199 | 199 |
| 200 // Notify the render view host to adjust the expand selection by the given |
| 201 // amounts. |
| 202 virtual void ExpandSelectionByCharacterOffset(int start_adjust, |
| 203 int end_adjust) = 0; |
| 204 |
200 #if defined(OS_ANDROID) | 205 #if defined(OS_ANDROID) |
201 // Selects and zooms to the find result nearest to the point (x,y) | 206 // Selects and zooms to the find result nearest to the point (x,y) |
202 // defined in find-in-page coordinates. | 207 // defined in find-in-page coordinates. |
203 virtual void ActivateNearestFindResult(int request_id, float x, float y) = 0; | 208 virtual void ActivateNearestFindResult(int request_id, float x, float y) = 0; |
204 | 209 |
205 // Asks the renderer to send the rects of the current find matches. | 210 // Asks the renderer to send the rects of the current find matches. |
206 virtual void RequestFindMatchRects(int current_version) = 0; | 211 virtual void RequestFindMatchRects(int current_version) = 0; |
207 #endif | 212 #endif |
208 | 213 |
209 private: | 214 private: |
210 // This interface should only be implemented inside content. | 215 // This interface should only be implemented inside content. |
211 friend class RenderViewHostImpl; | 216 friend class RenderViewHostImpl; |
212 RenderViewHost() {} | 217 RenderViewHost() {} |
213 }; | 218 }; |
214 | 219 |
215 } // namespace content | 220 } // namespace content |
216 | 221 |
217 #endif // CONTENT_PUBLIC_BROWSER_RENDER_VIEW_HOST_H_ | 222 #endif // CONTENT_PUBLIC_BROWSER_RENDER_VIEW_HOST_H_ |
OLD | NEW |