| Code-Review | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Callback<Runnable> softInputCallback =
((PartialCustomTabDisplayManager) mCustomTabHeightStrategy)::onShowSoftInput;
var tabController = mTabController.get();
tabController.registerTabObserver(new PartialCustomTabTabObserver(softInputCallback));
var csManager = mContextualSearchManagerSupplier.get();
if (csManager != null) {
tabController.registerTabObserver(
new EmptyTabObserver() {
@Override
public void didFirstVisuallyNonEmptyPaint(Tab tab) {
csManager.setCanHideAndroidBrowserControls(false);
}
});
}@jins...@chromium.org I just wanted to make sure we didn't miss anything here. I don't recognize this part.
switch (OPTIONAL_BUTTON_FOR_METRIC) {Is this right? This is always UNKNOWN afaict.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Callback<Runnable> softInputCallback =
((PartialCustomTabDisplayManager) mCustomTabHeightStrategy)::onShowSoftInput;
var tabController = mTabController.get();
tabController.registerTabObserver(new PartialCustomTabTabObserver(softInputCallback));
var csManager = mContextualSearchManagerSupplier.get();
if (csManager != null) {
tabController.registerTabObserver(
new EmptyTabObserver() {
@Override
public void didFirstVisuallyNonEmptyPaint(Tab tab) {
csManager.setCanHideAndroidBrowserControls(false);
}
});
}@jins...@chromium.org I just wanted to make sure we didn't miss anything here. I don't recognize this part.
Thanks for calling this out. I checked again: the code kept here is the old `if (ChromeFeatureList.sCctToolbarRefactor.isEnabled())` branch around lines 440-478, which used to return before the fallback below. The deleted block was the old disabled-flag fallback path.
switch (OPTIONAL_BUTTON_FOR_METRIC) {Is this right? This is always UNKNOWN afaict.
Good point. This used to be updated by the old optional-button path, which this CL removes, so it now effectively stays `UNKNOWN`.
Do you prefer simplifying this metric logic here, or keeping the metric cleanup for a follow-up CL?
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Callback<Runnable> softInputCallback =
((PartialCustomTabDisplayManager) mCustomTabHeightStrategy)::onShowSoftInput;
var tabController = mTabController.get();
tabController.registerTabObserver(new PartialCustomTabTabObserver(softInputCallback));
var csManager = mContextualSearchManagerSupplier.get();
if (csManager != null) {
tabController.registerTabObserver(
new EmptyTabObserver() {
@Override
public void didFirstVisuallyNonEmptyPaint(Tab tab) {
csManager.setCanHideAndroidBrowserControls(false);
}
});
}jingjing gu@jins...@chromium.org I just wanted to make sure we didn't miss anything here. I don't recognize this part.
Thanks for calling this out. I checked again: the code kept here is the old `if (ChromeFeatureList.sCctToolbarRefactor.isEnabled())` branch around lines 440-478, which used to return before the fallback below. The deleted block was the old disabled-flag fallback path.
Thanks for catching this part. It it still required code, accidentally skipped with the refactor flag. PCCT usage is relatively low and this path is also rarely taken but it is important logic to sort out the conflict between contextual search bottom sheet and PCCT. Please keep this in the new code.
switch (OPTIONAL_BUTTON_FOR_METRIC) {jingjing guIs this right? This is always UNKNOWN afaict.
Good point. This used to be updated by the old optional-button path, which this CL removes, so it now effectively stays `UNKNOWN`.
Do you prefer simplifying this metric logic here, or keeping the metric cleanup for a follow-up CL?
The entire |logActionButtonComboMetric| can be removed as it was added to do the analysis in stable exp. Not needed any more.
Callback<Runnable> softInputCallback =
((PartialCustomTabDisplayManager) mCustomTabHeightStrategy)::onShowSoftInput;
var tabController = mTabController.get();
tabController.registerTabObserver(new PartialCustomTabTabObserver(softInputCallback));
var csManager = mContextualSearchManagerSupplier.get();
if (csManager != null) {
tabController.registerTabObserver(
new EmptyTabObserver() {
@Override
public void didFirstVisuallyNonEmptyPaint(Tab tab) {
csManager.setCanHideAndroidBrowserControls(false);
}
});
}jingjing gu@jins...@chromium.org I just wanted to make sure we didn't miss anything here. I don't recognize this part.
Jinsuk KimThanks for calling this out. I checked again: the code kept here is the old `if (ChromeFeatureList.sCctToolbarRefactor.isEnabled())` branch around lines 440-478, which used to return before the fallback below. The deleted block was the old disabled-flag fallback path.
Thanks for catching this part. It it still required code, accidentally skipped with the refactor flag. PCCT usage is relatively low and this path is also rarely taken but it is important logic to sort out the conflict between contextual search bottom sheet and PCCT. Please keep this in the new code.
Thanks, I kept the refactored toolbar initialization path and only carried over the PartialCustomTab contextual search observer setup from the old fallback, since that logic is still required.
Could you please take another look?
switch (OPTIONAL_BUTTON_FOR_METRIC) {jingjing guIs this right? This is always UNKNOWN afaict.
Jinsuk KimGood point. This used to be updated by the old optional-button path, which this CL removes, so it now effectively stays `UNKNOWN`.
Do you prefer simplifying this metric logic here, or keeping the metric cleanup for a follow-up CL?
The entire |logActionButtonComboMetric| can be removed as it was added to do the analysis in stable exp. Not needed any more.
Thanks, removed the obsolete action button combo metric code from CustomTabToolbar.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
Thanks for addressing the feedback. LGTM % one more
Callback<Runnable> softInputCallback =
((PartialCustomTabDisplayManager) mCustomTabHeightStrategy)::onShowSoftInput;
var tabController = mTabController.get();
tabController.registerTabObserver(new PartialCustomTabTabObserver(softInputCallback));
var csManager = mContextualSearchManagerSupplier.get();
if (csManager != null) {
tabController.registerTabObserver(
new EmptyTabObserver() {
@Override
public void didFirstVisuallyNonEmptyPaint(Tab tab) {
csManager.setCanHideAndroidBrowserControls(false);
}
});
}jingjing gu@jins...@chromium.org I just wanted to make sure we didn't miss anything here. I don't recognize this part.
Jinsuk KimThanks for calling this out. I checked again: the code kept here is the old `if (ChromeFeatureList.sCctToolbarRefactor.isEnabled())` branch around lines 440-478, which used to return before the fallback below. The deleted block was the old disabled-flag fallback path.
jingjing guThanks for catching this part. It it still required code, accidentally skipped with the refactor flag. PCCT usage is relatively low and this path is also rarely taken but it is important logic to sort out the conflict between contextual search bottom sheet and PCCT. Please keep this in the new code.
Thanks, I kept the refactored toolbar initialization path and only carried over the PartialCustomTab contextual search observer setup from the old fallback, since that logic is still required.
Could you please take another look?
Acknowledged
// LINT.ThenChange(//tools/metrics/histograms/metadata/custom_tabs/enums.xml:CustomTabsToolbarButtons)You also need to update (remove) tools/metrics/histograms/metadata/custom_tabs/enums.xml:CustomTabsToolbarButtons
switch (OPTIONAL_BUTTON_FOR_METRIC) {jingjing guIs this right? This is always UNKNOWN afaict.
Jinsuk KimGood point. This used to be updated by the old optional-button path, which this CL removes, so it now effectively stays `UNKNOWN`.
Do you prefer simplifying this metric logic here, or keeping the metric cleanup for a follow-up CL?
jingjing guThe entire |logActionButtonComboMetric| can be removed as it was added to do the analysis in stable exp. Not needed any more.
Thanks, removed the obsolete action button combo metric code from CustomTabToolbar.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
// LINT.ThenChange(//tools/metrics/histograms/metadata/custom_tabs/enums.xml:CustomTabsToolbarButtons)You also need to update (remove) tools/metrics/histograms/metadata/custom_tabs/enums.xml:CustomTabsToolbarButtons
thanks, fixed. Removed CustomTabsToolbarButtons and the corresponding CustomTab.AdaptiveToolbarButton.ActionButtons histogram entry
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
Thanks for handling the feedback. LGTM again
// LINT.ThenChange(//tools/metrics/histograms/metadata/custom_tabs/enums.xml:CustomTabsToolbarButtons)jingjing guYou also need to update (remove) tools/metrics/histograms/metadata/custom_tabs/enums.xml:CustomTabsToolbarButtons
thanks, fixed. Removed CustomTabsToolbarButtons and the corresponding CustomTab.AdaptiveToolbarButton.ActionButtons histogram entry
Marked as resolved.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +1 |
if (omniboxParams != null && shouldEnableOmnibox) {nit: We set omniboxParams only if shouldEnableOmnibox is true, so this can be simplified.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
| Commit-Queue | +0 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
nit: We set omniboxParams only if shouldEnableOmnibox is true, so this can be simplified.
Thanks, fixed. Simplified the guard to `omniboxParams != null`.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +2 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
[customtabs] Remove old CCT toolbar coordinator paths (2/4)
CCTToolbarRefactor has been enabled by default. Remove the runtime flag
branches from the toolbar coordinator and root UI initialization path,
making the refactored toolbar setup unconditional.
- BaseCustomTabRootUiCoordinator: remove the old initializeToolbar()
fallback while keeping required PartialCustomTab contextual search
observer setup in the refactored path
- CloseButtonVisibilityManager: use the toolbar buttons coordinator path
directly
- CustomTabToolbarCoordinator: remove old toolbar manager branches
- CustomTabToolbarCoordinatorUnitTest: remove flag-parameterized
expectations
- CustomTabToolbar: remove obsolete action button combo metric code and
metadata
OBSOLETE_HISTOGRAM[CustomTab.AdaptiveToolbarButton.ActionButtons]=Removed because the stable CCT toolbar refactor analysis metric is no longer recorded.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |