Remove enable_brave_sync buildflag

This commit is contained in:
Anthony Tseng
2021-08-17 16:13:57 -07:00
parent 8b80ad0a0e
commit bee6c98a61
21 changed files with 65 additions and 220 deletions
@@ -21,15 +21,12 @@ public class BraveSyncReflectionUtils {
public static Object getSyncWorker() {
// May be invoked in non-UI thread when we do validation for camera QR in callback
if (!sInitialized) {
if (BraveConfig.SYNC_ENABLED) {
try {
sBraveSyncWorker =
Class.forName("org.chromium.chrome.browser.BraveSyncWorker")
.getConstructor()
.newInstance();
} catch (Exception e) {
Log.e(TAG, "Cannot create BraveSyncWorker ", e);
}
try {
sBraveSyncWorker = Class.forName("org.chromium.chrome.browser.BraveSyncWorker")
.getConstructor()
.newInstance();
} catch (Exception e) {
Log.e(TAG, "Cannot create BraveSyncWorker ", e);
}
sInitialized = true;
}
@@ -37,10 +34,6 @@ public class BraveSyncReflectionUtils {
}
public static void showInformers() {
if (!BraveConfig.SYNC_ENABLED) {
return;
}
try {
Method method = Class.forName("org.chromium.chrome.browser.BraveSyncInformers").getDeclaredMethod("show");
method.invoke(null);
@@ -228,11 +228,6 @@ public class BraveMainPreferencesBase
int order = findPreference(PREF_CLOSING_ALL_TABS_CLOSES_BRAVE).getOrder();
// If gn flag enable_brave_sync is false, hide Sync pref
if (BraveConfig.SYNC_ENABLED == false) {
removePreferenceIfPresent(PREF_SYNC);
}
// We don't have home button on top toolbar at the moment
if (!DeviceFormFactor.isTablet() && !BottomToolbarConfiguration.isBottomToolbarEnabled()) {
removePreferenceIfPresent(PREF_HOMEPAGE);