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

Side by Side Diff: android_webview/native/aw_contents.h

Issue 893343002: Update {virtual,override,final} to follow C++11 style. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 10 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 unified diff | Download patch
OLDNEW
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 ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_ 5 #ifndef ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_
6 #define ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_ 6 #define ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_
7 7
8 #include <jni.h> 8 #include <jni.h>
9 #include <list> 9 #include <list>
10 #include <string> 10 #include <string>
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 public AwBrowserPermissionRequestDelegate { 62 public AwBrowserPermissionRequestDelegate {
63 public: 63 public:
64 // Returns the AwContents instance associated with |web_contents|, or NULL. 64 // Returns the AwContents instance associated with |web_contents|, or NULL.
65 static AwContents* FromWebContents(content::WebContents* web_contents); 65 static AwContents* FromWebContents(content::WebContents* web_contents);
66 66
67 // Returns the AwContents instance associated with with the given 67 // Returns the AwContents instance associated with with the given
68 // render_process_id and render_view_id, or NULL. 68 // render_process_id and render_view_id, or NULL.
69 static AwContents* FromID(int render_process_id, int render_view_id); 69 static AwContents* FromID(int render_process_id, int render_view_id);
70 70
71 AwContents(scoped_ptr<content::WebContents> web_contents); 71 AwContents(scoped_ptr<content::WebContents> web_contents);
72 virtual ~AwContents(); 72 ~AwContents() override;
73 73
74 AwRenderViewHostExt* render_view_host_ext() { 74 AwRenderViewHostExt* render_view_host_ext() {
75 return render_view_host_ext_.get(); 75 return render_view_host_ext_.get();
76 } 76 }
77 77
78 // |handler| is an instance of 78 // |handler| is an instance of
79 // org.chromium.android_webview.AwHttpAuthHandler. 79 // org.chromium.android_webview.AwHttpAuthHandler.
80 bool OnReceivedHttpAuthRequest(const base::android::JavaRef<jobject>& handler, 80 bool OnReceivedHttpAuthRequest(const base::android::JavaRef<jobject>& handler,
81 const std::string& host, 81 const std::string& host,
82 const std::string& realm); 82 const std::string& realm);
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 void ClearView(JNIEnv* env, jobject obj); 132 void ClearView(JNIEnv* env, jobject obj);
133 void SetExtraHeadersForUrl(JNIEnv* env, jobject obj, 133 void SetExtraHeadersForUrl(JNIEnv* env, jobject obj,
134 jstring url, jstring extra_headers); 134 jstring url, jstring extra_headers);
135 135
136 void InvokeGeolocationCallback(JNIEnv* env, 136 void InvokeGeolocationCallback(JNIEnv* env,
137 jobject obj, 137 jobject obj,
138 jboolean value, 138 jboolean value,
139 jstring origin); 139 jstring origin);
140 140
141 // PermissionRequestHandlerClient implementation. 141 // PermissionRequestHandlerClient implementation.
142 virtual void OnPermissionRequest(AwPermissionRequest* request) override; 142 void OnPermissionRequest(AwPermissionRequest* request) override;
143 virtual void OnPermissionRequestCanceled( 143 void OnPermissionRequestCanceled(AwPermissionRequest* request) override;
144 AwPermissionRequest* request) override;
145 144
146 PermissionRequestHandler* GetPermissionRequestHandler() { 145 PermissionRequestHandler* GetPermissionRequestHandler() {
147 return permission_request_handler_.get(); 146 return permission_request_handler_.get();
148 } 147 }
149 148
150 void PreauthorizePermission(JNIEnv* env, 149 void PreauthorizePermission(JNIEnv* env,
151 jobject obj, 150 jobject obj,
152 jstring origin, 151 jstring origin,
153 jlong resources); 152 jlong resources);
154 153
155 // AwBrowserPermissionRequestDelegate implementation. 154 // AwBrowserPermissionRequestDelegate implementation.
156 virtual void RequestProtectedMediaIdentifierPermission( 155 void RequestProtectedMediaIdentifierPermission(
157 const GURL& origin, 156 const GURL& origin,
158 const base::Callback<void(bool)>& callback) override; 157 const base::Callback<void(bool)>& callback) override;
159 virtual void CancelProtectedMediaIdentifierPermissionRequests( 158 void CancelProtectedMediaIdentifierPermissionRequests(
160 const GURL& origin) override; 159 const GURL& origin) override;
161 virtual void RequestGeolocationPermission( 160 void RequestGeolocationPermission(
162 const GURL& origin, 161 const GURL& origin,
163 const base::Callback<void(bool)>& callback) override; 162 const base::Callback<void(bool)>& callback) override;
164 virtual void CancelGeolocationPermissionRequests( 163 void CancelGeolocationPermissionRequests(const GURL& origin) override;
165 const GURL& origin) override;
166
167 164
168 // Find-in-page API and related methods. 165 // Find-in-page API and related methods.
169 void FindAllAsync(JNIEnv* env, jobject obj, jstring search_string); 166 void FindAllAsync(JNIEnv* env, jobject obj, jstring search_string);
170 void FindNext(JNIEnv* env, jobject obj, jboolean forward); 167 void FindNext(JNIEnv* env, jobject obj, jboolean forward);
171 void ClearMatches(JNIEnv* env, jobject obj); 168 void ClearMatches(JNIEnv* env, jobject obj);
172 FindHelper* GetFindHelper(); 169 FindHelper* GetFindHelper();
173 170
174 // Per WebView Cookie Policy 171 // Per WebView Cookie Policy
175 bool AllowThirdPartyCookies(); 172 bool AllowThirdPartyCookies();
176 173
177 // FindHelper::Listener implementation. 174 // FindHelper::Listener implementation.
178 virtual void OnFindResultReceived(int active_ordinal, 175 void OnFindResultReceived(int active_ordinal,
179 int match_count, 176 int match_count,
180 bool finished) override; 177 bool finished) override;
181 // IconHelper::Listener implementation. 178 // IconHelper::Listener implementation.
182 virtual bool ShouldDownloadFavicon(const GURL& icon_url) override; 179 bool ShouldDownloadFavicon(const GURL& icon_url) override;
183 virtual void OnReceivedIcon(const GURL& icon_url, 180 void OnReceivedIcon(const GURL& icon_url, const SkBitmap& bitmap) override;
184 const SkBitmap& bitmap) override; 181 void OnReceivedTouchIconUrl(const std::string& url,
185 virtual void OnReceivedTouchIconUrl(const std::string& url, 182 const bool precomposed) override;
186 const bool precomposed) override;
187 183
188 // AwRenderViewHostExtClient implementation. 184 // AwRenderViewHostExtClient implementation.
189 virtual void OnWebLayoutPageScaleFactorChanged( 185 void OnWebLayoutPageScaleFactorChanged(float page_scale_factor) override;
190 float page_scale_factor) override; 186 void OnWebLayoutContentsSizeChanged(const gfx::Size& contents_size) override;
191 virtual void OnWebLayoutContentsSizeChanged(
192 const gfx::Size& contents_size) override;
193 187
194 // BrowserViewRendererClient implementation. 188 // BrowserViewRendererClient implementation.
195 virtual bool RequestDrawGL(bool wait_for_completion) override; 189 bool RequestDrawGL(bool wait_for_completion) override;
196 virtual void PostInvalidate() override; 190 void PostInvalidate() override;
197 virtual void InvalidateOnFunctorDestroy() override; 191 void InvalidateOnFunctorDestroy() override;
198 virtual void OnNewPicture() override; 192 void OnNewPicture() override;
199 virtual gfx::Point GetLocationOnScreen() override; 193 gfx::Point GetLocationOnScreen() override;
200 virtual void ScrollContainerViewTo(gfx::Vector2d new_value) override; 194 void ScrollContainerViewTo(gfx::Vector2d new_value) override;
201 virtual bool IsFlingActive() const override; 195 bool IsFlingActive() const override;
202 virtual void UpdateScrollState(gfx::Vector2d max_scroll_offset, 196 void UpdateScrollState(gfx::Vector2d max_scroll_offset,
203 gfx::SizeF contents_size_dip, 197 gfx::SizeF contents_size_dip,
204 float page_scale_factor, 198 float page_scale_factor,
205 float min_page_scale_factor, 199 float min_page_scale_factor,
206 float max_page_scale_factor) override; 200 float max_page_scale_factor) override;
207 virtual void DidOverscroll(gfx::Vector2d overscroll_delta) override; 201 void DidOverscroll(gfx::Vector2d overscroll_delta) override;
208 202
209 const BrowserViewRenderer* GetBrowserViewRenderer() const; 203 const BrowserViewRenderer* GetBrowserViewRenderer() const;
210 204
211 void ClearCache(JNIEnv* env, jobject obj, jboolean include_disk_files); 205 void ClearCache(JNIEnv* env, jobject obj, jboolean include_disk_files);
212 void SetPendingWebContentsForPopup(scoped_ptr<content::WebContents> pending); 206 void SetPendingWebContentsForPopup(scoped_ptr<content::WebContents> pending);
213 jlong ReleasePopupAwContents(JNIEnv* env, jobject obj); 207 jlong ReleasePopupAwContents(JNIEnv* env, jobject obj);
214 208
215 void ScrollTo(JNIEnv* env, jobject obj, jint x, jint y); 209 void ScrollTo(JNIEnv* env, jobject obj, jint x, jint y);
216 void SetDipScale(JNIEnv* env, jobject obj, jfloat dip_scale); 210 void SetDipScale(JNIEnv* env, jobject obj, jfloat dip_scale);
217 void SetSaveFormData(bool enabled); 211 void SetSaveFormData(bool enabled);
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
259 GLViewRendererManager::Key renderer_manager_key_; 253 GLViewRendererManager::Key renderer_manager_key_;
260 254
261 DISALLOW_COPY_AND_ASSIGN(AwContents); 255 DISALLOW_COPY_AND_ASSIGN(AwContents);
262 }; 256 };
263 257
264 bool RegisterAwContents(JNIEnv* env); 258 bool RegisterAwContents(JNIEnv* env);
265 259
266 } // namespace android_webview 260 } // namespace android_webview
267 261
268 #endif // ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_ 262 #endif // ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_H_
OLDNEW
« no previous file with comments | « android_webview/native/aw_autofill_client.h ('k') | android_webview/native/aw_contents_client_bridge.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698