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

Side by Side Diff: chrome/browser/prerender/external_prerender_handler_android.h

Issue 1767243002: Update prerender policy for custom tabs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Dan's comments Created 4 years, 9 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 CHROME_BROWSER_PRERENDER_EXTERNAL_PRERENDER_HANDLER_ANDROID_H_ 5 #ifndef CHROME_BROWSER_PRERENDER_EXTERNAL_PRERENDER_HANDLER_ANDROID_H_
6 #define CHROME_BROWSER_PRERENDER_EXTERNAL_PRERENDER_HANDLER_ANDROID_H_ 6 #define CHROME_BROWSER_PRERENDER_EXTERNAL_PRERENDER_HANDLER_ANDROID_H_
7 7
8 #include <jni.h> 8 #include <jni.h>
9 9
10 #include "base/android/scoped_java_ref.h" 10 #include "base/android/scoped_java_ref.h"
(...skipping 17 matching lines...) Expand all
28 28
29 // Add a prerender with the given url and referrer on the PrerenderManager of 29 // Add a prerender with the given url and referrer on the PrerenderManager of
30 // the given profile. This is restricted to a single prerender at a time. 30 // the given profile. This is restricted to a single prerender at a time.
31 bool AddPrerender(JNIEnv* env, 31 bool AddPrerender(JNIEnv* env,
32 const base::android::JavaParamRef<jobject>& obj, 32 const base::android::JavaParamRef<jobject>& obj,
33 const base::android::JavaParamRef<jobject>& profile, 33 const base::android::JavaParamRef<jobject>& profile,
34 const base::android::JavaParamRef<jobject>& jweb_contents, 34 const base::android::JavaParamRef<jobject>& jweb_contents,
35 const base::android::JavaParamRef<jstring>& url, 35 const base::android::JavaParamRef<jstring>& url,
36 const base::android::JavaParamRef<jstring>& referrer, 36 const base::android::JavaParamRef<jstring>& referrer,
37 jint width, 37 jint width,
38 jint height); 38 jint height,
39 bool prerender_on_mobile);
Benoit L 2016/03/10 13:58:30 nit: jboolean.
Yusuf 2016/03/10 18:55:53 Done.
39 40
40 // Cancel the prerender associated with the prerender_handle_ 41 // Cancel the prerender associated with the prerender_handle_
41 void CancelCurrentPrerender( 42 void CancelCurrentPrerender(
42 JNIEnv* env, 43 JNIEnv* env,
43 const base::android::JavaParamRef<jobject>& object); 44 const base::android::JavaParamRef<jobject>& object);
44 45
45 // Whether the PrerenderManager associated with the given profile has any 46 // Whether the PrerenderManager associated with the given profile has any
46 // prerenders for the url. 47 // prerenders for the url.
47 static bool HasPrerenderedUrl(Profile* profile, 48 static bool HasPrerenderedUrl(Profile* profile,
48 GURL url, 49 GURL url,
(...skipping 11 matching lines...) Expand all
60 private: 61 private:
61 virtual ~ExternalPrerenderHandlerAndroid(); 62 virtual ~ExternalPrerenderHandlerAndroid();
62 scoped_ptr<prerender::PrerenderHandle> prerender_handle_; 63 scoped_ptr<prerender::PrerenderHandle> prerender_handle_;
63 64
64 DISALLOW_COPY_AND_ASSIGN(ExternalPrerenderHandlerAndroid); 65 DISALLOW_COPY_AND_ASSIGN(ExternalPrerenderHandlerAndroid);
65 }; 66 };
66 67
67 } // namespace prerender 68 } // namespace prerender
68 69
69 #endif // CHROME_BROWSER_PRERENDER_EXTERNAL_PRERENDER_HANDLER_ANDROID_H_ 70 #endif // CHROME_BROWSER_PRERENDER_EXTERNAL_PRERENDER_HANDLER_ANDROID_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698