Skip to content

Commit

Permalink
Merge pull request #4713 from brave/pr4697_android_block_chromium_par…
Browse files Browse the repository at this point in the history
…tner_customizations_1.6.x

Disabled Chromium partners customizations (uplift to 1.6.x)
  • Loading branch information
kjozwiak authored Feb 26, 2020
2 parents 07cd9d5 + 43b33d9 commit 8fc005b
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 0 deletions.
1 change: 1 addition & 0 deletions android/brave_java_sources.gni
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ brave_java_sources = [
"../../brave/android/java/org/chromium/chrome/browser/onboarding/SearchEngineEnum.java",
"../../brave/android/java/org/chromium/chrome/browser/onboarding/SearchEngineOnboardingFragment.java",
"../../brave/android/java/org/chromium/chrome/browser/onboarding/TroubleshootingOnboardingFragment.java",
"../../brave/android/java/org/chromium/chrome/browser/partnercustomizations/BravePartnerBrowserCustomizations.java",
"../../brave/android/java/org/chromium/chrome/browser/partnercustomizations/CloseBraveManager.java",
"../../brave/android/java/org/chromium/chrome/browser/preferences/BravePreferenceKeys.java",
"../../brave/android/java/org/chromium/chrome/browser/preferences/BravePrefServiceBridge.java",
Expand Down
13 changes: 13 additions & 0 deletions android/java/org/chromium/chrome/browser/BraveAppHooks.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,23 @@

import org.chromium.chrome.browser.help.BraveHelpAndFeedback;
import org.chromium.chrome.browser.help.HelpAndFeedback;
import org.chromium.chrome.browser.partnerbookmarks.PartnerBookmark;
import org.chromium.chrome.browser.partnercustomizations.BravePartnerBrowserCustomizations;
import org.chromium.chrome.browser.partnercustomizations.PartnerBrowserCustomizations;

public class BraveAppHooks extends AppHooksImpl {
@Override
public HelpAndFeedback createHelpAndFeedback() {
return new BraveHelpAndFeedback();
}

@Override
public PartnerBookmark.BookmarkIterator getPartnerBookmarkIterator() {
return null;
}

@Override
public PartnerBrowserCustomizations.Provider getCustomizationProvider() {
return new BravePartnerBrowserCustomizations.ProviderPackage();
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
/* Copyright (c) 2020 The Brave Authors. All rights reserved.
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */

package org.chromium.chrome.browser.partnercustomizations;

public class BravePartnerBrowserCustomizations
extends PartnerBrowserCustomizations {
public static class ProviderPackage implements Provider {
@Override
public String getHomepage() {
return null;
}

@Override
public boolean isIncognitoModeDisabled() {
return false;
}

@Override
public boolean isBookmarksEditingDisabled() {
return false;
}
}
}

0 comments on commit 8fc005b

Please sign in to comment.