[Android] Changes to Share button id/methods.
Update BookmarkButton that pretends to be the share button. Needs a followup to potentially implement the new methods. Chromium changes: https://chromium.googlesource.com/chromium/src/+/5188059fe28691427b2a77858b1f7a4963640384 commit 5188059fe28691427b2a77858b1f7a4963640384 Author: Mia Glaese <glamia@chromium.org> Date: Tue Jan 7 12:25:45 2020 +0000 [Start Surface] Update button states in bottom bar. Disable Share button when showing Start. Disable Home button when showing Start in HOMEPAGE state. Disable Tabswitcher button when showing Start in TABSWITCHER state. Screenshots here: https://drive.google.com/drive/folders/1ss-vhR0cMl6L6KovZXijvIdkvNEr2nzi?usp=sharing Before: Crash when tapping Share button in Start. After: Nothing happens when tapping disabled buttons. Bug: 1025296, 1038270 https://chromium.googlesource.com/chromium/src/+/29eefa75481973f38041100a94eea264e744c5ca commit 29eefa75481973f38041100a94eea264e744c5ca Author: Lijin Shen <lazzzis@google.com> Date: Tue Jan 14 16:53:08 2020 +0000 [duet] Add three new variations of bottom toolbar Three brand new variations of bottom toolbar: 1. Home, search and tab switcher on bottom 2. Home, search and share on bottom 3. New tab, search and share on bottom Bug: 1036474, 1036467, 1036469, 1036471
This commit is contained in:
committed by
mkarolin
parent
0b687e858b
commit
fbfe6b6706
@@ -16,6 +16,8 @@ import android.widget.TextView;
|
||||
import org.chromium.base.ApiCompatibilityUtils;
|
||||
import org.chromium.chrome.R;
|
||||
import org.chromium.chrome.browser.ActivityTabProvider;
|
||||
import org.chromium.chrome.browser.compositor.layouts.OverviewModeBehavior;
|
||||
import org.chromium.chrome.browser.tab.Tab;
|
||||
import org.chromium.chrome.browser.ThemeColorProvider;
|
||||
import org.chromium.chrome.browser.ThemeColorProvider.ThemeColorObserver;
|
||||
import org.chromium.chrome.browser.ThemeColorProvider.TintObserver;
|
||||
@@ -102,4 +104,10 @@ public class BookmarksButton extends ChromeImageButton implements ThemeColorObse
|
||||
public void setActivityTabProvider(ActivityTabProvider activityTabProvider) {
|
||||
// sergz: Do nothing here, was added just to avoid extra patching
|
||||
}
|
||||
|
||||
public void setOverviewModeBehavior(OverviewModeBehavior overviewModeBehavior) {
|
||||
}
|
||||
|
||||
public void updateButtonEnabledState(Tab tab) {
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -85,7 +85,7 @@ public class BraveBottomToolbarCoordinator
|
||||
mHomeButton.setOnLongClickListener(this);
|
||||
}
|
||||
|
||||
mBookmarksButton = bottom_toolbar_browsing.findViewById(R.id.share_button);
|
||||
mBookmarksButton = bottom_toolbar_browsing.findViewById(R.id.bottom_share_button);
|
||||
if (mBookmarksButton != null) {
|
||||
mBookmarksButton.setOnLongClickListener(this);
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
style="@style/BottomToolbarButtonWrapper">
|
||||
|
||||
<org.chromium.chrome.browser.toolbar.bottom.BookmarksButton
|
||||
android:id="@+id/share_button"
|
||||
android:id="@+id/bottom_share_button"
|
||||
app:tint="@color/standard_mode_tint"
|
||||
style="@style/SplitToolbarButton"
|
||||
android:layout_gravity="center"
|
||||
|
||||
Reference in New Issue
Block a user