Java Code Examples for org.chromium.chrome.browser.signin.SigninManager#isSigninDisabledByPolicy()
The following examples show how to use
org.chromium.chrome.browser.signin.SigninManager#isSigninDisabledByPolicy() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: RecentTabsManager.java From AndroidChromium with Apache License 2.0 | 5 votes |
/** * Determine whether the sync promo needs to be displayed. * * @return Whether sync promo should be displayed. */ public boolean shouldDisplaySyncPromo() { SigninManager signinManager = SigninManager.get(mContext); if (signinManager.isSigninDisabledByPolicy() || !signinManager.isSigninSupported()) { return false; } if (ContextUtils.getAppSharedPreferences().getBoolean( PREF_SIGNIN_PROMO_DECLINED, false)) { return false; } return !AndroidSyncSettings.isSyncEnabled(mContext) || mForeignSessions.isEmpty(); }
Example 2
Source File: RecentTabsManager.java From 365browser with Apache License 2.0 | 5 votes |
/** * Determine whether the sync promo needs to be displayed. * * @return Whether sync promo should be displayed. */ public boolean shouldDisplaySyncPromo() { SigninManager signinManager = SigninManager.get(mContext); if (signinManager.isSigninDisabledByPolicy() || !signinManager.isSigninSupported()) { return false; } if (ContextUtils.getAppSharedPreferences().getBoolean( PREF_SIGNIN_PROMO_DECLINED, false)) { return false; } return !AndroidSyncSettings.isSyncEnabled(mContext) || mForeignSessions.isEmpty(); }
Example 3
Source File: FirstRunFlowSequencer.java From AndroidChromium with Apache License 2.0 | 4 votes |
@VisibleForTesting protected boolean isSyncAllowed() { SigninManager signinManager = SigninManager.get(mActivity.getApplicationContext()); return FeatureUtilities.canAllowSync(mActivity) && !signinManager.isSigninDisabledByPolicy() && signinManager.isSigninSupported(); }
Example 4
Source File: FirstRunFlowSequencer.java From 365browser with Apache License 2.0 | 4 votes |
@VisibleForTesting protected boolean isSyncAllowed() { SigninManager signinManager = SigninManager.get(mActivity.getApplicationContext()); return FeatureUtilities.canAllowSync(mActivity) && !signinManager.isSigninDisabledByPolicy() && signinManager.isSigninSupported(); }