Show different tooltips for QS features auto-added and non-auto-added

There are 2 different kinds of auto-added / non-auto-added subtext in QS tooltips for framework features. Show animation in the settings page for full flow for non-framework services.

Bug: 218968108
Test: make RunSettingsRoboTests ROBOTEST_FILTER=AccessibilityQuickSettingsTooltipWindowTest AccessibilityShortcutPreferenceFragmentTest
Change-Id: I462cfcece959df8b9d97fab8e28337bceca9e25e
This commit is contained in:
menghanli
2022-02-11 19:38:51 +08:00
parent 093a24c3eb
commit 01d02d3d8e
14 changed files with 130 additions and 99 deletions

View File

@@ -206,12 +206,6 @@ public class ToggleAccessibilityServicePreferenceFragment extends
.createDisableDialog(getPrefContext(), info,
this::onDialogButtonFromDisableToggleClicked);
return mWarningDialog;
case DialogEnums.LAUNCH_ACCESSIBILITY_TUTORIAL:
final Dialog dialog = AccessibilityGestureNavigationTutorial
.createAccessibilityTutorialDialog(getPrefContext(),
getUserShortcutTypes(), this::callOnTutorialDialogButtonClicked);
dialog.setCanceledOnTouchOutside(false);
return dialog;
default:
return super.onCreateDialog(dialogId);
}
@@ -496,23 +490,6 @@ public class ToggleAccessibilityServicePreferenceFragment extends
mWarningDialog.dismiss();
}
/**
* This method will be invoked when a button in the tutorial dialog is clicked.
*
* @param dialog The dialog that received the click
* @param which The button that was clicked
*/
private void callOnTutorialDialogButtonClicked(DialogInterface dialog, int which) {
dialog.dismiss();
showQuickSettingsTooltipIfNeeded();
}
@Override
protected void callOnAlertDialogCheckboxClicked(DialogInterface dialog, int which) {
super.callOnAlertDialogCheckboxClicked(dialog, which);
showQuickSettingsTooltipIfNeeded(getShortcutTypeCheckBoxValue());
}
void onDialogButtonFromShortcutClicked(View view) {
final int viewId = view.getId();
if (viewId == R.id.permission_enable_allow_button) {