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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/profiles/Profile.java

Issue 556083004: Add hooks to get incognito profile. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 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 | « no previous file | chrome/browser/profiles/profile_android.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/java/src/org/chromium/chrome/browser/profiles/Profile.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/profiles/Profile.java b/chrome/android/java/src/org/chromium/chrome/browser/profiles/Profile.java
index aeff4b7beb6b1a2f74f72830dad210edc4dd58cf..091d5af94788426dff6b99748ba21ffce613ca5f 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/profiles/Profile.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/profiles/Profile.java
@@ -21,6 +21,22 @@ public class Profile {
return (Profile) nativeGetLastUsedProfile();
}
+ public Profile getOriginalProfile() {
+ return (Profile) nativeGetOriginalProfile(mNativeProfileAndroid);
+ }
+
+ public Profile getOffTheRecordProfile() {
+ return (Profile) nativeGetOffTheRecordProfile(mNativeProfileAndroid);
+ }
+
+ public boolean hasOffTheRecordProfile() {
+ return nativeHasOffTheRecordProfile(mNativeProfileAndroid);
+ }
+
+ public boolean isOffTheRecord() {
+ return nativeIsOffTheRecord(mNativeProfileAndroid);
+ }
+
@CalledByNative
private static Profile create(long nativeProfileAndroid) {
return new Profile(nativeProfileAndroid);
@@ -37,4 +53,12 @@ public class Profile {
}
private static native Object nativeGetLastUsedProfile();
+ private native Object nativeGetOriginalProfile(
+ long nativeProfileAndroid);
+ private native Object nativeGetOffTheRecordProfile(
+ long nativeProfileAndroid);
+ private native boolean nativeHasOffTheRecordProfile(
+ long nativeProfileAndroid);
+ private native boolean nativeIsOffTheRecord(
+ long nativeProfileAndroid);
}
« no previous file with comments | « no previous file | chrome/browser/profiles/profile_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698