[automerger skipped] Import translations. DO NOT MERGE ANYWHERE am: 7bccc1b9cb -s ours
am skip reason: subject contains skip directive
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/23669869
Change-Id: Icc02c95009dbbb3eef4dcca91415129a17b4ebd2
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
diff --git a/quickstep/res/layout/redesigned_gesture_tutorial_fragment.xml b/quickstep/res/layout/redesigned_gesture_tutorial_fragment.xml
index 7d5505e..a1bcad0 100644
--- a/quickstep/res/layout/redesigned_gesture_tutorial_fragment.xml
+++ b/quickstep/res/layout/redesigned_gesture_tutorial_fragment.xml
@@ -124,7 +124,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
- android:scaleType="centerCrop"
+ android:scaleType="matrix"
app:lottie_loop="true" />
</RelativeLayout>
diff --git a/quickstep/res/values/strings.xml b/quickstep/res/values/strings.xml
index 3b82784..6d0dbae 100644
--- a/quickstep/res/values/strings.xml
+++ b/quickstep/res/values/strings.xml
@@ -98,16 +98,17 @@
<string name="gesture_tutorial_rotation_prompt_title">Rotate your device</string>
<!-- Prompt shown before the gesture navigation tutorial to users who need to rotate their screen to begin. [CHAR LIMIT=100] -->
<string name="gesture_tutorial_rotation_prompt">Please rotate your device to complete the gesture navigation tutorial</string>
+
<!-- Feedback shown during interactive parts of Back gesture tutorial for right edge when the gesture is too far from the edge. [CHAR LIMIT=100] -->
- <string name="back_gesture_feedback_swipe_too_far_from_edge">Make sure you swipe from the far-right or far-left edge.</string>
+ <string name="back_gesture_feedback_swipe_too_far_from_edge">Make sure you swipe from the far-right or far-left edge</string>
<!-- Feedback shown during interactive parts of Back gesture tutorial for right edge when the gesture is cancelled. [CHAR LIMIT=100] -->
- <string name="back_gesture_feedback_cancelled">Make sure you swipe from the right or left edge to the middle of the screen and let go.</string>
+ <string name="back_gesture_feedback_cancelled">Make sure you swipe from the right or left edge to the middle of the screen and let go</string>
<!-- Feedback shown after completing the back gesture step if the user is following the full gesture tutorial flow. [CHAR LIMIT=100] -->
<string name="back_gesture_feedback_complete_with_overview_follow_up">You learned how to swipe from the right to go back. Next up, learn how to switch apps.</string>
<!-- Feedback shown after completing the back gesture step if the user started this tutorial individually. [CHAR LIMIT=100] -->
- <string name="back_gesture_feedback_complete_without_follow_up">You completed the go back gesture.</string>
+ <string name="back_gesture_feedback_complete_without_follow_up">You completed the go back gesture</string>
<!-- Feedback shown during interactive parts of Back gesture tutorial when the gesture is within the nav bar region. [CHAR LIMIT=100] -->
- <string name="back_gesture_feedback_swipe_in_nav_bar">Make sure you don\'t swipe too close to the bottom of the screen.</string>
+ <string name="back_gesture_feedback_swipe_in_nav_bar">Make sure you don\'t swipe too close to the bottom of the screen</string>
<!-- Subtitle shown on the confirmation screen after successful gesture. [CHAR LIMIT=60] -->
<string name="back_gesture_tutorial_confirm_subtitle">To change the sensitivity of the back gesture, go to Settings</string>
<!-- Feedback shown during interactive parts of Home gesture tutorial when the gesture is started too far from the edge. [CHAR LIMIT=100] -->
@@ -119,16 +120,18 @@
<string name="back_gesture_spoken_intro_subtitle">To go back to the last screen, swipe with 2 fingers from the left or right edge to the middle of the screen.</string>
<!-- Title of the gesture tutorial section educating users on how to go back to the previous screen. [CHAR LIMIT=100] -->
<string name="back_gesture_tutorial_title">Go back</string>
+ <!-- Subtitle of the gesture tutorial section educating users on how to go to back to the previous screen [CHAR LIMIT=100] -->
+ <string name="back_gesture_tutorial_subtitle">Swipe from the left or right edge to the middle of the screen</string>
- <string name="home_gesture_feedback_swipe_too_far_from_edge">Make sure you swipe up from the bottom edge of the screen.</string>
+ <string name="home_gesture_feedback_swipe_too_far_from_edge">Make sure you swipe up from the bottom edge of the screen</string>
<!-- Feedback shown during interactive parts of Home gesture tutorial when the Overview gesture is detected. [CHAR LIMIT=100] -->
- <string name="home_gesture_feedback_overview_detected">Make sure you don\'t pause before letting go.</string>
+ <string name="home_gesture_feedback_overview_detected">Make sure you don\'t pause before letting go</string>
<!-- Feedback shown during interactive parts of Home gesture tutorial when the gesture is horizontal instead of vertical. [CHAR LIMIT=100] -->
- <string name="home_gesture_feedback_wrong_swipe_direction">Make sure you swipe straight up.</string>
+ <string name="home_gesture_feedback_wrong_swipe_direction">Make sure you swipe straight up</string>
<!-- Feedback shown after completing the home gesture step if the user is following the full gesture tutorial flow. [CHAR LIMIT=100] -->
- <string name="home_gesture_feedback_complete_with_follow_up">You completed the go Home gesture. Next up, learn how to go back.</string>
+ <string name="home_gesture_feedback_complete_with_follow_up">You completed the go home gesture. Next up, learn how to go back.</string>
<!-- Feedback shown after completing the home gesture step if the user started this tutorial individually. [CHAR LIMIT=100] -->
- <string name="home_gesture_feedback_complete_without_follow_up">You completed the go Home gesture.</string>
+ <string name="home_gesture_feedback_complete_without_follow_up">You completed the go home gesture</string>
<!-- Introduction title for the Home gesture tutorial. [CHAR LIMIT=100] -->
<string name="home_gesture_intro_title">Swipe to go home</string>
<!-- Introduction subtitle for the Home gesture tutorial. [CHAR LIMIT=100] -->
@@ -138,18 +141,20 @@
<!-- Title of the gesture tutorial section educating users on how to go to the home screen. [CHAR LIMIT=100] -->
<string name="home_gesture_tutorial_title">Go home</string>
<!-- Subtitle of the gesture tutorial section educating users on how to go to the home screen [CHAR LIMIT=100] -->
- <string name="home_gesture_tutorial_subtitle">To go to your home screen at any time, swipe up from the bottom of your screen</string>
+ <string name="home_gesture_tutorial_subtitle">Swipe up from the bottom of your screen</string>
+ <!-- Title message when users successfully learn to go to the home screen [CHAR LIMIT=100] -->
+ <string name="home_gesture_tutorial_success">Great job!</string>
<!-- Feedback shown during interactive parts of Overview gesture tutorial when the gesture is started too far from the edge. [CHAR LIMIT=100] -->
- <string name="overview_gesture_feedback_swipe_too_far_from_edge">Make sure you swipe up from the bottom edge of the screen.</string>
+ <string name="overview_gesture_feedback_swipe_too_far_from_edge">Make sure you swipe up from the bottom edge of the screen</string>
<!-- Feedback shown during interactive parts of Overview gesture tutorial when the Home gesture is detected. The window refers to the current app's window during the gesture. [CHAR LIMIT=100] -->
- <string name="overview_gesture_feedback_home_detected">Try holding the window for longer before releasing.</string>
+ <string name="overview_gesture_feedback_home_detected">Try holding the window for longer before releasing</string>
<!-- Feedback shown during interactive parts of Overview gesture tutorial when the gesture is horizontal instead of vertical. [CHAR LIMIT=100] -->
- <string name="overview_gesture_feedback_wrong_swipe_direction">Make sure you swipe straight up, then pause.</string>
+ <string name="overview_gesture_feedback_wrong_swipe_direction">Make sure you swipe straight up, then pause</string>
<!-- Feedback shown after completing the overview gesture step if the user is following the full gesture tutorial flow. [CHAR LIMIT=100] -->
<string name="overview_gesture_feedback_complete_with_follow_up">You learned how to use gestures. To turn off gestures, go to Settings.</string>
<!-- Feedback shown after completing the overview gesture step if the user started this tutorial individually. [CHAR LIMIT=100] -->
- <string name="overview_gesture_feedback_complete_without_follow_up">You completed the switch apps gesture.</string>
+ <string name="overview_gesture_feedback_complete_without_follow_up">You completed the switch apps gesture</string>
<!-- Introduction title for the Overview gesture tutorial. [CHAR LIMIT=100] -->
<string name="overview_gesture_intro_title">Swipe to switch apps</string>
<!-- Introduction subtitle for the Overview gesture tutorial. [CHAR LIMIT=100] -->
@@ -158,6 +163,11 @@
<string name="overview_gesture_spoken_intro_subtitle">To switch between apps, swipe up with 2 fingers from the bottom of your screen, hold, then release.</string>
<!-- Title of the gesture tutorial section educating users on how to switch between apps. [CHAR LIMIT=100] -->
<string name="overview_gesture_tutorial_title">Switch apps</string>
+ <!-- Subtitle of the gesture tutorial section educating users on how to switch between apps [CHAR LIMIT=100] -->
+ <string name="overview_gesture_tutorial_subtitle">Swipe up from the bottom of your screen, hold, then release</string>
+ <!-- Title message when users successfully learn to switch between apps [CHAR LIMIT=100] -->
+ <string name="overview_gesture_tutorial_success">Well done!</string>
+
<!-- Title shown during interactive part of Assistant gesture tutorial. [CHAR LIMIT=30] -->
<string name="assistant_gesture_tutorial_playground_title" translatable="false">Tutorial: Assistant</string>
diff --git a/quickstep/src/com/android/launcher3/taskbar/TaskbarAutohideSuspendController.java b/quickstep/src/com/android/launcher3/taskbar/TaskbarAutohideSuspendController.java
index c9d331b..2517ff6 100644
--- a/quickstep/src/com/android/launcher3/taskbar/TaskbarAutohideSuspendController.java
+++ b/quickstep/src/com/android/launcher3/taskbar/TaskbarAutohideSuspendController.java
@@ -41,10 +41,8 @@
public static final int FLAG_AUTOHIDE_SUSPEND_TOUCHING = 1 << 2;
// Taskbar EDU overlay is open above the Taskbar. */
public static final int FLAG_AUTOHIDE_SUSPEND_EDU_OPEN = 1 << 3;
- // Taskbar is in immersive mode in overview.
+ // Taskbar in immersive mode in overview
public static final int FLAG_AUTOHIDE_SUSPEND_IN_LAUNCHER = 1 << 4;
- // Transient Taskbar is temporarily unstashed (pending a timeout).
- public static final int FLAG_AUTOHIDE_SUSPEND_TRANSIENT_TASKBAR = 1 << 5;
@IntDef(flag = true, value = {
FLAG_AUTOHIDE_SUSPEND_FULLSCREEN,
@@ -52,7 +50,6 @@
FLAG_AUTOHIDE_SUSPEND_TOUCHING,
FLAG_AUTOHIDE_SUSPEND_EDU_OPEN,
FLAG_AUTOHIDE_SUSPEND_IN_LAUNCHER,
- FLAG_AUTOHIDE_SUSPEND_TRANSIENT_TASKBAR,
})
@Retention(RetentionPolicy.SOURCE)
public @interface AutohideSuspendFlag {}
@@ -88,21 +85,18 @@
boolean isSuspended = isSuspended();
mSystemUiProxy.notifyTaskbarAutohideSuspend(isSuspended);
- mActivity.onTransientAutohideSuspendFlagChanged(isTransientTaskbarStashingSuspended());
+ mActivity.onTransientAutohideSuspendFlagChanged(isSuspended);
}
/**
- * Returns true iff taskbar autohide is currently suspended for immersive mode.
+ * Returns true iff taskbar autohide is currently suspended.
*/
- private boolean isSuspended() {
+ public boolean isSuspended() {
return mAutohideSuspendFlags != 0;
}
- /**
- * Returns whether Transient Taskbar should avoid auto-stashing.
- */
- public boolean isTransientTaskbarStashingSuspended() {
- return (mAutohideSuspendFlags & ~FLAG_AUTOHIDE_SUSPEND_TRANSIENT_TASKBAR) != 0;
+ public boolean isSuspendedForTransientTaskbarInOverview() {
+ return (mAutohideSuspendFlags & FLAG_AUTOHIDE_SUSPEND_IN_LAUNCHER) != 0;
}
@Override
@@ -121,8 +115,6 @@
appendFlag(str, flags, FLAG_AUTOHIDE_SUSPEND_EDU_OPEN, "FLAG_AUTOHIDE_SUSPEND_EDU_OPEN");
appendFlag(str, flags, FLAG_AUTOHIDE_SUSPEND_IN_LAUNCHER,
"FLAG_AUTOHIDE_SUSPEND_IN_LAUNCHER");
- appendFlag(str, flags, FLAG_AUTOHIDE_SUSPEND_TRANSIENT_TASKBAR,
- "FLAG_AUTOHIDE_SUSPEND_TRANSIENT_TASKBAR");
return str.toString();
}
}
diff --git a/quickstep/src/com/android/launcher3/taskbar/TaskbarStashController.java b/quickstep/src/com/android/launcher3/taskbar/TaskbarStashController.java
index 7e767fa..4f2d5df 100644
--- a/quickstep/src/com/android/launcher3/taskbar/TaskbarStashController.java
+++ b/quickstep/src/com/android/launcher3/taskbar/TaskbarStashController.java
@@ -509,8 +509,10 @@
return;
}
- if (stash && mControllers.taskbarAutohideSuspendController
- .isTransientTaskbarStashingSuspended()) {
+ if (stash && mControllers.taskbarAutohideSuspendController.isSuspended()
+ && !mControllers.taskbarAutohideSuspendController
+ .isSuspendedForTransientTaskbarInOverview()) {
+ // Avoid stashing if autohide is currently suspended.
return;
}
@@ -1037,9 +1039,6 @@
mActivity.getStatsLogManager().logger().log(hasAnyFlag(FLAG_STASHED_IN_APP_AUTO)
? LAUNCHER_TRANSIENT_TASKBAR_HIDE
: LAUNCHER_TRANSIENT_TASKBAR_SHOW);
- mControllers.taskbarAutohideSuspendController.updateFlag(
- TaskbarAutohideSuspendController.FLAG_AUTOHIDE_SUSPEND_TRANSIENT_TASKBAR,
- !hasAnyFlag(FLAG_STASHED_IN_APP_AUTO));
}
}
@@ -1132,7 +1131,7 @@
}
private void onTaskbarTimeout(Alarm alarm) {
- if (mControllers.taskbarAutohideSuspendController.isTransientTaskbarStashingSuspended()) {
+ if (mControllers.taskbarAutohideSuspendController.isSuspended()) {
return;
}
updateAndAnimateTransientTaskbar(true);
diff --git a/quickstep/src/com/android/launcher3/uioverrides/states/QuickstepAtomicAnimationFactory.java b/quickstep/src/com/android/launcher3/uioverrides/states/QuickstepAtomicAnimationFactory.java
index c7cd39c..a8d7538 100644
--- a/quickstep/src/com/android/launcher3/uioverrides/states/QuickstepAtomicAnimationFactory.java
+++ b/quickstep/src/com/android/launcher3/uioverrides/states/QuickstepAtomicAnimationFactory.java
@@ -94,8 +94,12 @@
@Override
public void prepareForAtomicAnimation(LauncherState fromState, LauncherState toState,
StateAnimationConfig config) {
+
RecentsView overview = mActivity.getOverviewPanel();
if ((fromState == OVERVIEW || fromState == OVERVIEW_SPLIT_SELECT) && toState == NORMAL) {
+ overview.switchToScreenshot(() ->
+ overview.finishRecentsAnimation(true /* toRecents */, null));
+
if (fromState == OVERVIEW_SPLIT_SELECT) {
config.setInterpolator(ANIM_OVERVIEW_SPLIT_SELECT_FLOATING_TASK_TRANSLATE_OFFSCREEN,
clampToProgress(EMPHASIZED_ACCELERATE, 0, 0.4f));
diff --git a/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/StatusBarTouchController.java b/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/StatusBarTouchController.java
index 6becf0f..395833f 100644
--- a/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/StatusBarTouchController.java
+++ b/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/StatusBarTouchController.java
@@ -30,8 +30,6 @@
import android.view.Window;
import android.view.WindowManager;
-import androidx.annotation.VisibleForTesting;
-
import com.android.launcher3.AbstractFloatingView;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.Launcher;
@@ -52,13 +50,12 @@
private final Launcher mLauncher;
private final SystemUiProxy mSystemUiProxy;
- @VisibleForTesting final float mTouchSlop;
+ private final float mTouchSlop;
private int mLastAction;
private final SparseArray<PointF> mDownEvents;
/* If {@code false}, this controller should not handle the input {@link MotionEvent}.*/
- @VisibleForTesting
- boolean mCanIntercept;
+ private boolean mCanIntercept;
public StatusBarTouchController(Launcher l) {
mLauncher = l;
@@ -85,9 +82,9 @@
@Override
public final boolean onControllerInterceptTouchEvent(MotionEvent ev) {
- final int action = ev.getActionMasked();
- final int idx = ev.getActionIndex();
- final int pid = ev.getPointerId(idx);
+ int action = ev.getActionMasked();
+ int idx = ev.getActionIndex();
+ int pid = ev.getPointerId(idx);
if (action == ACTION_DOWN) {
mCanIntercept = canInterceptTouch(ev);
if (!mCanIntercept) {
@@ -95,14 +92,14 @@
}
mDownEvents.clear();
mDownEvents.put(pid, new PointF(ev.getX(), ev.getY()));
- } else if (action == MotionEvent.ACTION_POINTER_DOWN) {
+ } else if (ev.getActionMasked() == MotionEvent.ACTION_POINTER_DOWN) {
// Check!! should only set it only when threshold is not entered.
mDownEvents.put(pid, new PointF(ev.getX(idx), ev.getY(idx)));
}
if (!mCanIntercept) {
return false;
}
- if (action == ACTION_MOVE && mDownEvents.contains(pid)) {
+ if (action == ACTION_MOVE) {
float dy = ev.getY(idx) - mDownEvents.get(pid).y;
float dx = ev.getX(idx) - mDownEvents.get(pid).x;
// Currently input dispatcher will not do touch transfer if there are more than
@@ -129,6 +126,7 @@
mLauncher.getStatsLogManager().logger()
.log(LAUNCHER_SWIPE_DOWN_WORKSPACE_NOTISHADE_OPEN);
setWindowSlippery(false);
+ return true;
}
return true;
}
@@ -142,8 +140,7 @@
* Touches can slide out of the window but they cannot necessarily slide
* back in (unless the other window with touch focus permits it).
*/
- @VisibleForTesting
- void setWindowSlippery(boolean enable) {
+ private void setWindowSlippery(boolean enable) {
Window w = mLauncher.getWindow();
WindowManager.LayoutParams wlp = w.getAttributes();
if (enable) {
diff --git a/quickstep/src/com/android/quickstep/interaction/BackGestureTutorialController.java b/quickstep/src/com/android/quickstep/interaction/BackGestureTutorialController.java
index 9083d51..5d25279 100644
--- a/quickstep/src/com/android/quickstep/interaction/BackGestureTutorialController.java
+++ b/quickstep/src/com/android/quickstep/interaction/BackGestureTutorialController.java
@@ -66,7 +66,9 @@
@Override
public int getIntroductionSubtitle() {
- return R.string.back_gesture_intro_subtitle;
+ return ENABLE_NEW_GESTURE_NAV_TUTORIAL.get()
+ ? R.string.back_gesture_tutorial_subtitle
+ : R.string.back_gesture_intro_subtitle;
}
@Override
@@ -75,6 +77,11 @@
}
@Override
+ public int getSuccessFeedbackTitle() {
+ return R.string.gesture_tutorial_nice;
+ }
+
+ @Override
public int getSuccessFeedbackSubtitle() {
return mTutorialFragment.isAtFinalStep()
? R.string.back_gesture_feedback_complete_without_follow_up
diff --git a/quickstep/src/com/android/quickstep/interaction/HomeGestureTutorialController.java b/quickstep/src/com/android/quickstep/interaction/HomeGestureTutorialController.java
index 333ecbb..bce8b98 100644
--- a/quickstep/src/com/android/quickstep/interaction/HomeGestureTutorialController.java
+++ b/quickstep/src/com/android/quickstep/interaction/HomeGestureTutorialController.java
@@ -74,6 +74,13 @@
}
@Override
+ public int getSuccessFeedbackTitle() {
+ return ENABLE_NEW_GESTURE_NAV_TUTORIAL.get()
+ ? R.string.home_gesture_tutorial_success
+ : R.string.gesture_tutorial_nice;
+ }
+
+ @Override
public int getSuccessFeedbackSubtitle() {
return mTutorialFragment.isAtFinalStep()
? R.string.home_gesture_feedback_complete_without_follow_up
diff --git a/quickstep/src/com/android/quickstep/interaction/OverviewGestureTutorialController.java b/quickstep/src/com/android/quickstep/interaction/OverviewGestureTutorialController.java
index 09a6bbe..454dd17 100644
--- a/quickstep/src/com/android/quickstep/interaction/OverviewGestureTutorialController.java
+++ b/quickstep/src/com/android/quickstep/interaction/OverviewGestureTutorialController.java
@@ -77,7 +77,9 @@
@Override
public int getIntroductionSubtitle() {
- return R.string.overview_gesture_intro_subtitle;
+ return ENABLE_NEW_GESTURE_NAV_TUTORIAL.get()
+ ? R.string.overview_gesture_tutorial_subtitle
+ : R.string.overview_gesture_intro_subtitle;
}
@Override
@@ -86,6 +88,13 @@
}
@Override
+ public int getSuccessFeedbackTitle() {
+ return ENABLE_NEW_GESTURE_NAV_TUTORIAL.get()
+ ? R.string.overview_gesture_tutorial_success
+ : R.string.gesture_tutorial_nice;
+ }
+
+ @Override
public int getSuccessFeedbackSubtitle() {
return mTutorialFragment.getNumSteps() > 1 && mTutorialFragment.isAtFinalStep()
? R.string.overview_gesture_feedback_complete_with_follow_up
diff --git a/quickstep/src/com/android/quickstep/interaction/TutorialController.java b/quickstep/src/com/android/quickstep/interaction/TutorialController.java
index a58f453..16fe2d3 100644
--- a/quickstep/src/com/android/quickstep/interaction/TutorialController.java
+++ b/quickstep/src/com/android/quickstep/interaction/TutorialController.java
@@ -30,6 +30,7 @@
import android.content.Context;
import android.content.pm.PackageManager;
import android.graphics.Color;
+import android.graphics.Matrix;
import android.graphics.Outline;
import android.graphics.Rect;
import android.graphics.drawable.AnimatedVectorDrawable;
@@ -67,6 +68,7 @@
import com.android.systemui.shared.system.QuickStepContract;
import com.airbnb.lottie.LottieAnimationView;
+import com.airbnb.lottie.LottieComposition;
import java.util.ArrayList;
@@ -175,6 +177,8 @@
mExitingAppStartingCornerRadius = QuickStepContract.getWindowCornerRadius(mContext);
mExitingAppEndingCornerRadius = mContext.getResources().getDimensionPixelSize(
R.dimen.gesture_tutorial_back_gesture_end_corner_radius);
+ mAnimatedGestureDemonstration.addLottieOnCompositionLoadedListener(
+ this::createScalingMatrix);
mFeedbackTitleView.setText(getIntroductionTitle());
mFeedbackSubtitleView.setText(getIntroductionSubtitle());
@@ -214,6 +218,24 @@
};
}
+ /** Scale the Lottie gesture animation to fit the device based on device dimensions */
+ private void createScalingMatrix(LottieComposition composition) {
+ Rect animationBoundsRect = composition.getBounds();
+ if (animationBoundsRect == null) {
+ mAnimatedGestureDemonstration.setScaleType(ImageView.ScaleType.CENTER_CROP);
+ return;
+ }
+ Matrix scaleMatrix = new Matrix();
+ float pivotX = mScreenWidth / 2f;
+ float pivotY = mScreenHeight;
+ float scaleFactor = mScreenWidth / animationBoundsRect.width();
+
+ scaleMatrix.postScale(scaleFactor, scaleFactor, pivotX, pivotY);
+ scaleMatrix.postTranslate(0,
+ mTutorialFragment.getDeviceProfile().heightPx - animationBoundsRect.height());
+ mAnimatedGestureDemonstration.setImageMatrix(scaleMatrix);
+ }
+
private void showSkipTutorialDialog() {
if (mSkipTutorialDialog != null) {
mSkipTutorialDialog.show();
@@ -321,6 +343,11 @@
return NO_ID;
}
+ @StringRes
+ public int getSuccessFeedbackTitle() {
+ return NO_ID;
+ }
+
@StyleRes
public int getTitleTextAppearance() {
return NO_ID;
@@ -392,7 +419,7 @@
void showFeedback(int subtitleResId, boolean isGestureSuccessful) {
showFeedback(
isGestureSuccessful
- ? R.string.gesture_tutorial_nice : R.string.gesture_tutorial_try_again,
+ ? getSuccessFeedbackTitle() : R.string.gesture_tutorial_try_again,
subtitleResId,
NO_ID,
isGestureSuccessful,
diff --git a/quickstep/src/com/android/quickstep/views/RecentsView.java b/quickstep/src/com/android/quickstep/views/RecentsView.java
index 6d78364..0a31a62 100644
--- a/quickstep/src/com/android/quickstep/views/RecentsView.java
+++ b/quickstep/src/com/android/quickstep/views/RecentsView.java
@@ -4100,14 +4100,6 @@
alpha = Utilities.boundToRange(alpha, 0, 1);
mContentAlpha = alpha;
- runActionOnRemoteHandles(remoteTargetHandle -> {
- TransformParams params = remoteTargetHandle.getTransformParams();
- params.setTargetAlpha(mContentAlpha);
- if (params.getTargetSet() != null) {
- remoteTargetHandle.getTaskViewSimulator().apply(params);
- }
- });
-
int runningTaskId = getTaskIdsForRunningTaskView()[0];
for (int i = getTaskViewCount() - 1; i >= 0; i--) {
TaskView child = requireTaskViewAt(i);
diff --git a/quickstep/tests/src/com/android/launcher3/uioverrides/touchcontrollers/StatusBarTouchControllerTest.kt b/quickstep/tests/src/com/android/launcher3/uioverrides/touchcontrollers/StatusBarTouchControllerTest.kt
deleted file mode 100644
index b2f13c7..0000000
--- a/quickstep/tests/src/com/android/launcher3/uioverrides/touchcontrollers/StatusBarTouchControllerTest.kt
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- * Copyright (C) 202 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package com.android.launcher3.uioverrides.touchcontrollers
-
-import android.view.MotionEvent
-import android.view.WindowManager
-import androidx.test.filters.SmallTest
-import androidx.test.runner.AndroidJUnit4
-import com.android.launcher3.Launcher
-import com.android.launcher3.ui.AbstractLauncherUiTest
-import com.android.launcher3.ui.TaplTestsLauncher3
-import junit.framework.Assert.assertEquals
-import junit.framework.Assert.assertFalse
-import junit.framework.Assert.assertTrue
-import org.junit.Before
-import org.junit.Test
-import org.junit.runner.RunWith
-
-@SmallTest
-@RunWith(AndroidJUnit4::class)
-class StatusBarTouchControllerTest : AbstractLauncherUiTest() {
- @Before
- @Throws(Exception::class)
- fun setup() {
- TaplTestsLauncher3.initialize(this)
- }
-
- @Test
- fun interceptActionDown_canIntercept() {
- executeOnLauncher { launcher: Launcher? ->
- val underTest = StatusBarTouchController(launcher)
- assertFalse(underTest.mCanIntercept)
- val downEvent = MotionEvent.obtain(1, 1, MotionEvent.ACTION_DOWN, 0f, 0f, 0)
-
- underTest.onControllerInterceptTouchEvent(downEvent)
-
- assertTrue(underTest.mCanIntercept)
- }
- }
-
- @Test
- fun interceptActionMove_handledAndSetSlippery() {
- executeOnLauncher { launcher: Launcher ->
- val underTest = StatusBarTouchController(launcher)
- val downEvent = MotionEvent.obtain(1, 1, MotionEvent.ACTION_DOWN, 0f, 0f, 0)
- underTest.onControllerInterceptTouchEvent(downEvent)
- val w = launcher.window
- assertEquals(0, w.attributes.flags and WindowManager.LayoutParams.FLAG_SLIPPERY)
- val moveEvent =
- MotionEvent.obtain(
- 2,
- 2,
- MotionEvent.ACTION_MOVE,
- underTest.mTouchSlop,
- underTest.mTouchSlop + 10,
- 0
- )
-
- val handled = underTest.onControllerInterceptTouchEvent(moveEvent)
-
- assertTrue(handled)
- assertEquals(
- WindowManager.LayoutParams.FLAG_SLIPPERY,
- w.attributes.flags and WindowManager.LayoutParams.FLAG_SLIPPERY
- )
- }
- }
-
- @Test
- fun interceptActionMove_not_handled() {
- executeOnLauncher { launcher: Launcher? ->
- val underTest = StatusBarTouchController(launcher)
- val downEvent = MotionEvent.obtain(1, 1, MotionEvent.ACTION_DOWN, 0f, 0f, 0)
- underTest.onControllerInterceptTouchEvent(downEvent)
- val moveEvent =
- MotionEvent.obtain(
- 2,
- 2,
- MotionEvent.ACTION_MOVE,
- underTest.mTouchSlop + 10,
- underTest.mTouchSlop,
- 0
- )
-
- val handled = underTest.onControllerInterceptTouchEvent(moveEvent)
-
- assertFalse(handled)
- }
- }
-
- @Test
- fun interceptActionMoveAsFirstGestureEvent_notCrashedNorHandled() {
- executeOnLauncher { launcher: Launcher? ->
- val underTest = StatusBarTouchController(launcher)
- underTest.mCanIntercept = true
- val moveEvent = MotionEvent.obtain(2, 2, MotionEvent.ACTION_MOVE, 10f, 10f, 0)
-
- val handled = underTest.onControllerInterceptTouchEvent(moveEvent)
-
- assertFalse(handled)
- }
- }
-
- @Test
- fun handleActionUp_setNotSlippery() {
- executeOnLauncher { launcher: Launcher ->
- val underTest = StatusBarTouchController(launcher)
- underTest.mCanIntercept = true
- underTest.setWindowSlippery(true)
- val moveEvent = MotionEvent.obtain(2, 2, MotionEvent.ACTION_UP, 10f, 10f, 0)
-
- val handled = underTest.onControllerTouchEvent(moveEvent)
-
- assertTrue(handled)
- assertEquals(
- 0,
- launcher.window.attributes.flags and WindowManager.LayoutParams.FLAG_SLIPPERY
- )
- }
- }
-
- @Test
- fun handleActionCancel_setNotSlippery() {
- executeOnLauncher { launcher: Launcher ->
- val underTest = StatusBarTouchController(launcher)
- underTest.mCanIntercept = true
- underTest.setWindowSlippery(true)
- val moveEvent = MotionEvent.obtain(2, 2, MotionEvent.ACTION_CANCEL, 10f, 10f, 0)
-
- val handled = underTest.onControllerTouchEvent(moveEvent)
-
- assertTrue(handled)
- assertEquals(
- 0,
- launcher.window.attributes.flags and WindowManager.LayoutParams.FLAG_SLIPPERY
- )
- }
- }
-}
diff --git a/res/color-night-v31/material_color_surface.xml b/res/color-night-v31/material_color_surface.xml
new file mode 100644
index 0000000..a645f24
--- /dev/null
+++ b/res/color-night-v31/material_color_surface.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="6" />
+</selector>
\ No newline at end of file
diff --git a/res/color-night-v31/material_color_surface_bright.xml b/res/color-night-v31/material_color_surface_bright.xml
new file mode 100644
index 0000000..f34ed6c
--- /dev/null
+++ b/res/color-night-v31/material_color_surface_bright.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="24" />
+</selector>
\ No newline at end of file
diff --git a/res/color-night-v31/material_color_surface_container.xml b/res/color-night-v31/material_color_surface_container.xml
new file mode 100644
index 0000000..002b88e
--- /dev/null
+++ b/res/color-night-v31/material_color_surface_container.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="12" />
+</selector>
\ No newline at end of file
diff --git a/res/color-night-v31/material_color_surface_container_high.xml b/res/color-night-v31/material_color_surface_container_high.xml
new file mode 100644
index 0000000..002b88e
--- /dev/null
+++ b/res/color-night-v31/material_color_surface_container_high.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="12" />
+</selector>
\ No newline at end of file
diff --git a/res/color-night-v31/material_color_surface_container_highest.xml b/res/color-night-v31/material_color_surface_container_highest.xml
new file mode 100644
index 0000000..002b88e
--- /dev/null
+++ b/res/color-night-v31/material_color_surface_container_highest.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="12" />
+</selector>
\ No newline at end of file
diff --git a/res/color-night-v31/material_color_surface_container_low.xml b/res/color-night-v31/material_color_surface_container_low.xml
new file mode 100644
index 0000000..002b88e
--- /dev/null
+++ b/res/color-night-v31/material_color_surface_container_low.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="12" />
+</selector>
\ No newline at end of file
diff --git a/res/color-night-v31/material_color_surface_container_lowest.xml b/res/color-night-v31/material_color_surface_container_lowest.xml
new file mode 100644
index 0000000..002b88e
--- /dev/null
+++ b/res/color-night-v31/material_color_surface_container_lowest.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="12" />
+</selector>
\ No newline at end of file
diff --git a/res/color-night-v31/material_color_surface_dim.xml b/res/color-night-v31/material_color_surface_dim.xml
new file mode 100644
index 0000000..a645f24
--- /dev/null
+++ b/res/color-night-v31/material_color_surface_dim.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="6" />
+</selector>
\ No newline at end of file
diff --git a/res/color-night-v31/material_color_surface_inverse.xml b/res/color-night-v31/material_color_surface_inverse.xml
new file mode 100644
index 0000000..ac63072
--- /dev/null
+++ b/res/color-night-v31/material_color_surface_inverse.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="98" />
+</selector>
\ No newline at end of file
diff --git a/res/color-night-v31/material_color_surface_variant.xml b/res/color-night-v31/material_color_surface_variant.xml
new file mode 100644
index 0000000..a645f24
--- /dev/null
+++ b/res/color-night-v31/material_color_surface_variant.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="6" />
+</selector>
\ No newline at end of file
diff --git a/res/color-night-v31/surface.xml b/res/color-night-v31/surface.xml
deleted file mode 100644
index fbc9e43..0000000
--- a/res/color-night-v31/surface.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/*
-**
-** Copyright 2021, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-** http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
--->
-<selector
- xmlns:android="http://schemas.android.com/apk/res/android">
- <item android:color="@android:color/system_neutral1_800" />
-</selector>
diff --git a/res/color-v31/material_color_surface.xml b/res/color-v31/material_color_surface.xml
new file mode 100644
index 0000000..b049851
--- /dev/null
+++ b/res/color-v31/material_color_surface.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2023 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="98" />
+</selector>
\ No newline at end of file
diff --git a/res/color-v31/material_color_surface_bright.xml b/res/color-v31/material_color_surface_bright.xml
new file mode 100644
index 0000000..b049851
--- /dev/null
+++ b/res/color-v31/material_color_surface_bright.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2023 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="98" />
+</selector>
\ No newline at end of file
diff --git a/res/color-v31/material_color_surface_container.xml b/res/color-v31/material_color_surface_container.xml
new file mode 100644
index 0000000..b031c08
--- /dev/null
+++ b/res/color-v31/material_color_surface_container.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2023 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="94" />
+</selector>
\ No newline at end of file
diff --git a/res/color-v31/material_color_surface_container_high.xml b/res/color-v31/material_color_surface_container_high.xml
new file mode 100644
index 0000000..b031c08
--- /dev/null
+++ b/res/color-v31/material_color_surface_container_high.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2023 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="94" />
+</selector>
\ No newline at end of file
diff --git a/res/color-v31/material_color_surface_container_highest.xml b/res/color-v31/material_color_surface_container_highest.xml
new file mode 100644
index 0000000..b031c08
--- /dev/null
+++ b/res/color-v31/material_color_surface_container_highest.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2023 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="94" />
+</selector>
\ No newline at end of file
diff --git a/res/color-v31/material_color_surface_container_low.xml b/res/color-v31/material_color_surface_container_low.xml
new file mode 100644
index 0000000..b031c08
--- /dev/null
+++ b/res/color-v31/material_color_surface_container_low.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2023 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="94" />
+</selector>
\ No newline at end of file
diff --git a/res/color-v31/material_color_surface_container_lowest.xml b/res/color-v31/material_color_surface_container_lowest.xml
new file mode 100644
index 0000000..674fc73
--- /dev/null
+++ b/res/color-v31/material_color_surface_container_lowest.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="94" />
+</selector>
\ No newline at end of file
diff --git a/res/color-v31/material_color_surface_dim.xml b/res/color-v31/material_color_surface_dim.xml
new file mode 100644
index 0000000..e2d226f
--- /dev/null
+++ b/res/color-v31/material_color_surface_dim.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="87" />
+</selector>
\ No newline at end of file
diff --git a/res/color-v31/material_color_surface_inverse.xml b/res/color-v31/material_color_surface_inverse.xml
new file mode 100644
index 0000000..e189862
--- /dev/null
+++ b/res/color-v31/material_color_surface_inverse.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2023 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="6" />
+</selector>
\ No newline at end of file
diff --git a/res/color-v31/material_color_surface_variant.xml b/res/color-v31/material_color_surface_variant.xml
new file mode 100644
index 0000000..e2d226f
--- /dev/null
+++ b/res/color-v31/material_color_surface_variant.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/system_neutral1_500" android:lStar="87" />
+</selector>
\ No newline at end of file
diff --git a/res/color-v31/surface.xml b/res/color-v31/surface.xml
index 30f3032..da4571a 100644
--- a/res/color-v31/surface.xml
+++ b/res/color-v31/surface.xml
@@ -19,5 +19,6 @@
-->
<selector
xmlns:android="http://schemas.android.com/apk/res/android">
- <item android:color="@android:color/system_neutral1_500" android:lStar="98"/>
+ <item android:color="?attr/materialColorSurfaceContainerHighest"/>
</selector>
+
diff --git a/res/values-hi/strings.xml b/res/values-hi/strings.xml
index 533c9ee..9f74bfc 100644
--- a/res/values-hi/strings.xml
+++ b/res/values-hi/strings.xml
@@ -48,7 +48,7 @@
<string name="no_widgets_available" msgid="4337693382501046170">"विजेट और शॉर्टकट उपलब्ध नहीं हैं"</string>
<string name="no_search_results" msgid="3787956167293097509">"कोई विजेट या शॉर्टकट नहीं मिला"</string>
<string name="widgets_full_sheet_personal_tab" msgid="2743540105607120182">"निजी विजेट"</string>
- <string name="widgets_full_sheet_work_tab" msgid="3767150027110633765">"वर्क विजेट"</string>
+ <string name="widgets_full_sheet_work_tab" msgid="3767150027110633765">"ऑफ़िस"</string>
<string name="widget_category_conversations" msgid="8894438636213590446">"बातचीत"</string>
<string name="widget_category_note_taking" msgid="3469689394504266039">"नोट बनाने से जुड़े विजेट"</string>
<string name="widget_education_header" msgid="4874760613775913787">"काम की जानकारी आसानी से पाएं"</string>
diff --git a/res/values-night-v31/colors.xml b/res/values-night-v31/colors.xml
index 3453668..e462ae0 100644
--- a/res/values-night-v31/colors.xml
+++ b/res/values-night-v31/colors.xml
@@ -51,4 +51,39 @@
@android:color/system_accent1_200</color>
<color name="work_fab_icon_color">
@android:color/system_accent1_900</color>
+
+ <color name="material_color_on_secondary_fixed_variant">@android:color/system_accent2_700</color>
+ <color name="material_color_on_tertiary_fixed_variant">@android:color/system_accent3_700</color>
+ <color name="material_color_on_primary_fixed_variant">@android:color/system_accent1_700</color>
+ <color name="material_color_on_secondary_container">@android:color/system_accent2_100</color>
+ <color name="material_color_on_tertiary_container">@android:color/system_accent3_100</color>
+ <color name="material_color_on_primary_container">@android:color/system_accent1_100</color>
+ <color name="material_color_secondary_fixed_dim">@android:color/system_accent2_200</color>
+ <color name="material_color_on_error_container">#FFDAD5</color>
+ <color name="material_color_on_secondary_fixed">@android:color/system_accent2_900</color>
+ <color name="material_color_on_surface_inverse">@android:color/system_neutral1_900</color>
+ <color name="material_color_tertiary_fixed_dim">@android:color/system_accent3_200</color>
+ <color name="material_color_on_tertiary_fixed">@android:color/system_accent3_900</color>
+ <color name="material_color_primary_fixed_dim">@android:color/system_accent1_200</color>
+ <color name="material_color_secondary_container">@android:color/system_accent2_700</color>
+ <color name="material_color_error_container">#930001</color>
+ <color name="material_color_on_primary_fixed">@android:color/system_accent1_900</color>
+ <color name="material_color_primary_inverse">@android:color/system_accent1_600</color>
+ <color name="material_color_secondary_fixed">@android:color/system_accent2_100</color>
+ <color name="material_color_tertiary_container">@android:color/system_accent3_700</color>
+ <color name="material_color_tertiary_fixed">@android:color/system_accent3_100</color>
+ <color name="material_color_primary_container">@android:color/system_accent1_700</color>
+ <color name="material_color_on_background">@android:color/system_neutral1_800</color>
+ <color name="material_color_primary_fixed">@android:color/system_accent1_100</color>
+ <color name="material_color_on_secondary">@android:color/system_accent2_800</color>
+ <color name="material_color_on_tertiary">@android:color/system_accent3_800</color>
+ <color name="material_color_on_error">#690001</color>
+ <color name="material_color_on_surface_variant">@android:color/system_neutral2_200</color>
+ <color name="material_color_outline">@android:color/system_neutral2_400</color>
+ <color name="material_color_outline_variant">@android:color/system_neutral2_700</color>
+ <color name="material_color_on_primary">@android:color/system_accent1_800</color>
+ <color name="material_color_on_surface">@android:color/system_neutral1_100</color>
+ <color name="material_color_primary">@android:color/system_accent1_200</color>
+ <color name="material_color_secondary">@android:color/system_accent2_200</color>
+ <color name="material_color_tertiary">@android:color/system_accent3_200</color>
</resources>
\ No newline at end of file
diff --git a/res/values-night/colors.xml b/res/values-night/colors.xml
new file mode 100644
index 0000000..95b3a63
--- /dev/null
+++ b/res/values-night/colors.xml
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+**
+** Copyright 2023, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+<resources>
+ <color name="material_color_on_secondary_fixed_variant">#3F4759</color>
+ <color name="material_color_on_tertiary_fixed_variant">#583E5B</color>
+ <color name="material_color_surface_container_lowest">#0D0E11</color>
+ <color name="material_color_on_primary_fixed_variant">#2B4678</color>
+ <color name="material_color_on_secondary_container">#DBE2F9</color>
+ <color name="material_color_on_tertiary_container">#FBD7FC</color>
+ <color name="material_color_surface_container_low">#1B1B1F</color>
+ <color name="material_color_on_primary_container">#D8E2FF</color>
+ <color name="material_color_secondary_fixed_dim">#BFC6DC</color>
+ <color name="material_color_on_error_container">#FFDAD5</color>
+ <color name="material_color_on_secondary_fixed">#141B2C</color>
+ <color name="material_color_on_surface_inverse">#1B1B1F</color>
+ <color name="material_color_tertiary_fixed_dim">#DEBCDF</color>
+ <color name="material_color_on_tertiary_fixed">#29132D</color>
+ <color name="material_color_primary_fixed_dim">#ADC6FF</color>
+ <color name="material_color_secondary_container">#3F4759</color>
+ <color name="material_color_error_container">#930001</color>
+ <color name="material_color_on_primary_fixed">#001A41</color>
+ <color name="material_color_primary_inverse">#445E91</color>
+ <color name="material_color_secondary_fixed">#DBE2F9</color>
+ <color name="material_color_surface_inverse">#FAF9FD</color>
+ <color name="material_color_surface_variant">#44474F</color>
+ <color name="material_color_tertiary_container">#583E5B</color>
+ <color name="material_color_tertiary_fixed">#FBD7FC</color>
+ <color name="material_color_primary_container">#2B4678</color>
+ <color name="material_color_on_background">#E3E2E6</color>
+ <color name="material_color_primary_fixed">#D8E2FF</color>
+ <color name="material_color_on_secondary">#293041</color>
+ <color name="material_color_on_tertiary">#402843</color>
+ <color name="material_color_surface_dim">#121316</color>
+ <color name="material_color_surface_bright">#38393C</color>
+ <color name="material_color_on_error">#690001</color>
+ <color name="material_color_surface">#121316</color>
+ <color name="material_color_surface_container_high">#292A2D</color>
+ <color name="material_color_surface_container_highest">#343538</color>
+ <color name="material_color_on_surface_variant">#C4C6D0</color>
+ <color name="material_color_outline">#72747D</color>
+ <color name="material_color_outline_variant">#444746</color>
+ <color name="material_color_on_primary">#102F60</color>
+ <color name="material_color_on_surface">#E3E2E6</color>
+ <color name="material_color_surface_container">#1F1F23</color>
+ <color name="material_color_primary">#ADC6FF</color>
+ <color name="material_color_secondary">#BFC6DC</color>
+ <color name="material_color_tertiary">#DEBCDF</color>
+</resources>
diff --git a/res/values-or/strings.xml b/res/values-or/strings.xml
index c00b57e..04f9865 100644
--- a/res/values-or/strings.xml
+++ b/res/values-or/strings.xml
@@ -39,7 +39,7 @@
<string name="add_to_home_screen" msgid="9168649446635919791">"ହୋମ ସ୍କ୍ରିନରେ ଯୋଗ କରନ୍ତୁ"</string>
<string name="added_to_home_screen_accessibility_text" msgid="4451545765448884415">"<xliff:g id="WIDGET_NAME">%1$s</xliff:g>ର ୱିଜେଟ ହୋମ ସ୍କ୍ରିନରେ ଯୋଡ଼ାଗଲା"</string>
<string name="suggested_widgets_header_title" msgid="1844314680798145222">"ପରାମର୍ଶଗୁଡ଼ିକ"</string>
- <string name="widgets_count" msgid="6467746476364652096">"{count,plural, =1{# ୱିଜେଟ}other{# ୱିଜେଟ}}"</string>
+ <string name="widgets_count" msgid="6467746476364652096">"{count,plural, =1{#ଟି ୱିଜେଟ୍}other{#ଟି ୱିଜେଟ୍}}"</string>
<string name="shortcuts_count" msgid="8471715556199592381">"{count,plural, =1{#ଟି ସର୍ଟକଟ୍}other{#ଟି ସର୍ଟକଟ୍}}"</string>
<string name="widgets_and_shortcuts_count" msgid="7209136747878365116">"<xliff:g id="WIDGETS_COUNT">%1$s</xliff:g>, <xliff:g id="SHORTCUTS_COUNT">%2$s</xliff:g>"</string>
<string name="widget_button_text" msgid="2880537293434387943">"ୱିଜେଟ୍"</string>
diff --git a/res/values-v31/colors.xml b/res/values-v31/colors.xml
index 4ffff57..841e07b 100644
--- a/res/values-v31/colors.xml
+++ b/res/values-v31/colors.xml
@@ -102,4 +102,40 @@
@android:color/system_accent1_200</color>
<color name="work_fab_icon_color">
@android:color/system_accent1_900</color>
+
+
+ <color name="material_color_on_secondary_fixed_variant">@android:color/system_accent2_700</color>
+ <color name="material_color_on_tertiary_fixed_variant">@android:color/system_accent3_700</color>
+ <color name="material_color_on_primary_fixed_variant">@android:color/system_accent1_700</color>
+ <color name="material_color_on_secondary_container">@android:color/system_accent2_900</color>
+ <color name="material_color_on_tertiary_container">@android:color/system_accent3_900</color>
+ <color name="material_color_on_primary_container">@android:color/system_accent1_900</color>
+ <color name="material_color_secondary_fixed_dim">@android:color/system_accent2_200</color>
+ <color name="material_color_on_error_container">#410000</color>
+ <color name="material_color_on_secondary_fixed">@android:color/system_accent2_900</color>
+ <color name="material_color_on_surface_inverse">@android:color/system_neutral1_100</color>
+ <color name="material_color_tertiary_fixed_dim">@android:color/system_accent3_200</color>
+ <color name="material_color_on_tertiary_fixed">@android:color/system_accent3_900</color>
+ <color name="material_color_primary_fixed_dim">@android:color/system_accent1_200</color>
+ <color name="material_color_secondary_container">@android:color/system_accent2_100</color>
+ <color name="material_color_error_container">#FFDAD5</color>
+ <color name="material_color_on_primary_fixed">@android:color/system_accent1_900</color>
+ <color name="material_color_primary_inverse">@android:color/system_accent1_200</color>
+ <color name="material_color_secondary_fixed">@android:color/system_accent2_100</color>
+ <color name="material_color_tertiary_container">@android:color/system_accent3_100</color>
+ <color name="material_color_tertiary_fixed">@android:color/system_accent3_100</color>
+ <color name="material_color_primary_container">@android:color/system_accent1_100</color>
+ <color name="material_color_on_background">@android:color/system_neutral1_50</color>
+ <color name="material_color_primary_fixed">@android:color/system_accent1_100</color>
+ <color name="material_color_on_secondary">@android:color/system_accent2_0</color>
+ <color name="material_color_on_tertiary">@android:color/system_accent3_0</color>
+ <color name="material_color_on_error">#FFFFFF</color>
+ <color name="material_color_on_surface_variant">@android:color/system_neutral2_700</color>
+ <color name="material_color_outline">@android:color/system_neutral2_500</color>
+ <color name="material_color_outline_variant">@android:color/system_neutral2_200</color>
+ <color name="material_color_on_primary">@android:color/system_accent1_0</color>
+ <color name="material_color_on_surface">@android:color/system_neutral1_900</color>
+ <color name="material_color_primary">@android:color/system_accent1_600</color>
+ <color name="material_color_secondary">@android:color/system_accent2_600</color>
+ <color name="material_color_tertiary">@android:color/system_accent3_600</color>
</resources>
diff --git a/res/values/attrs.xml b/res/values/attrs.xml
index b023d10..e4650b2 100644
--- a/res/values/attrs.xml
+++ b/res/values/attrs.xml
@@ -506,6 +506,51 @@
<attr name="appIconSize" format="dimension" />
</declare-styleable>
+ <attr name="materialColorOnSecondaryFixedVariant" format="color" />
+ <attr name="materialColorOnTertiaryFixedVariant" format="color" />
+ <attr name="materialColorSurfaceContainerLowest" format="color" />
+ <attr name="materialColorOnPrimaryFixedVariant" format="color" />
+ <attr name="materialColorOnSecondaryContainer" format="color" />
+ <attr name="materialColorOnTertiaryContainer" format="color" />
+ <attr name="materialColorSurfaceContainerLow" format="color" />
+ <attr name="materialColorOnPrimaryContainer" format="color" />
+ <attr name="materialColorSecondaryFixedDim" format="color" />
+ <attr name="materialColorOnErrorContainer" format="color" />
+ <attr name="materialColorOnSecondaryFixed" format="color" />
+ <attr name="materialColorOnSurfaceInverse" format="color" />
+ <attr name="materialColorTertiaryFixedDim" format="color" />
+ <attr name="materialColorOnTertiaryFixed" format="color" />
+ <attr name="materialColorPrimaryFixedDim" format="color" />
+ <attr name="materialColorSecondaryContainer" format="color" />
+ <attr name="materialColorErrorContainer" format="color" />
+ <attr name="materialColorOnPrimaryFixed" format="color" />
+ <attr name="materialColorPrimaryInverse" format="color" />
+ <attr name="materialColorSecondaryFixed" format="color" />
+ <attr name="materialColorTertiaryContainer" format="color" />
+ <attr name="materialColorTertiaryFixed" format="color" />
+ <attr name="materialColorPrimaryContainer" format="color" />
+ <attr name="materialColorOnBackground" format="color" />
+ <attr name="materialColorPrimaryFixed" format="color" />
+ <attr name="materialColorOnSecondary" format="color" />
+ <attr name="materialColorOnTertiary" format="color" />
+ <attr name="materialColorOnError" format="color" />
+ <attr name="materialColorOnSurfaceVariant" format="color" />
+ <attr name="materialColorOutline" format="color" />
+ <attr name="materialColorOutlineVariant" format="color" />
+ <attr name="materialColorOnPrimary" format="color" />
+ <attr name="materialColorOnSurface" format="color" />
+ <attr name="materialColorPrimary" format="color" />
+ <attr name="materialColorSecondary" format="color" />
+ <attr name="materialColorTertiary" format="color" />
+ <attr name="materialColorSurfaceInverse" format="color" />
+ <attr name="materialColorSurfaceVariant" format="color" />
+ <attr name="materialColorSurfaceDim" format="color" />
+ <attr name="materialColorSurfaceBright" format="color" />
+ <attr name="materialColorSurface" format="color" />
+ <attr name="materialColorSurfaceContainerHigh" format="color" />
+ <attr name="materialColorSurfaceContainerHighest" format="color" />
+ <attr name="materialColorSurfaceContainer" format="color" />
+
<declare-styleable name="WidgetSections">
<!-- Component name of an app widget provider. -->
<attr name="provider" format="string" />
diff --git a/res/values/colors.xml b/res/values/colors.xml
index ad7a10b..6c3b54c 100644
--- a/res/values/colors.xml
+++ b/res/values/colors.xml
@@ -128,4 +128,49 @@
<color name="widget_picker_selected_tab_text_color_dark">#2D312F</color>
<color name="widget_picker_unselected_tab_text_color_dark">#C4C7C5</color>
<color name="widget_picker_collapse_handle_color_dark">#444746</color>
+
+ <color name="material_color_on_secondary_fixed_variant">#3F4759</color>
+ <color name="material_color_on_tertiary_fixed_variant">#583E5B</color>
+ <color name="material_color_surface_container_lowest">#FFFFFF</color>
+ <color name="material_color_on_primary_fixed_variant">#2B4678</color>
+ <color name="material_color_on_secondary_container">#141B2C</color>
+ <color name="material_color_on_tertiary_container">#29132D</color>
+ <color name="material_color_surface_container_low">#F5F3F7</color>
+ <color name="material_color_on_primary_container">#001A41</color>
+ <color name="material_color_secondary_fixed_dim">#BFC6DC</color>
+ <color name="material_color_on_error_container">#410000</color>
+ <color name="material_color_on_secondary_fixed">#141B2C</color>
+ <color name="material_color_on_surface_inverse">#E3E2E6</color>
+ <color name="material_color_tertiary_fixed_dim">#DEBCDF</color>
+ <color name="material_color_on_tertiary_fixed">#29132D</color>
+ <color name="material_color_primary_fixed_dim">#ADC6FF</color>
+ <color name="material_color_secondary_container">#DBE2F9</color>
+ <color name="material_color_error_container">#FFDAD5</color>
+ <color name="material_color_on_primary_fixed">#001A41</color>
+ <color name="material_color_primary_inverse">#ADC6FF</color>
+ <color name="material_color_secondary_fixed">#DBE2F9</color>
+ <color name="material_color_surface_inverse">#121316</color>
+ <color name="material_color_surface_variant">#E1E2EC</color>
+ <color name="material_color_tertiary_container">#FBD7FC</color>
+ <color name="material_color_tertiary_fixed">#FBD7FC</color>
+ <color name="material_color_primary_container">#D8E2FF</color>
+ <color name="material_color_on_background">#1B1B1F</color>
+ <color name="material_color_primary_fixed">#D8E2FF</color>
+ <color name="material_color_on_secondary">#FFFFFF</color>
+ <color name="material_color_on_tertiary">#FFFFFF</color>
+ <color name="material_color_surface_dim">#DBD9DD</color>
+ <color name="material_color_surface_bright">#FAF9FD</color>
+ <color name="material_color_on_error">#FFFFFF</color>
+ <color name="material_color_surface">#FAF9FD</color>
+ <color name="material_color_surface_container_high">#E9E7EC</color>
+ <color name="material_color_surface_container_highest">#E3E2E6</color>
+ <color name="material_color_on_surface_variant">#44474F</color>
+ <color name="material_color_outline">#72747D</color>
+ <color name="material_color_outline_variant">#C4C7C5</color>
+ <color name="material_color_on_primary">#FFFFFF</color>
+ <color name="material_color_on_surface">#1B1B1F</color>
+ <color name="material_color_surface_container">#EFEDF1</color>
+ <color name="material_color_primary">#445E91</color>
+ <color name="material_color_secondary">#575E71</color>
+ <color name="material_color_tertiary">#715573</color>
</resources>
diff --git a/res/values/styles.xml b/res/values/styles.xml
index 876c3a8..c41f0e8 100644
--- a/res/values/styles.xml
+++ b/res/values/styles.xml
@@ -31,7 +31,7 @@
<style name="LauncherTheme" parent="@style/BaseLauncherTheme">
<item name="android:textColorSecondary">#DE000000</item>
- <item name="allAppsScrimColor">?android:attr/colorBackgroundFloating</item>
+ <item name="allAppsScrimColor">?attr/materialColorSurfaceDim</item>
<item name="allappsHeaderProtectionColor">@color/popup_color_tertiary_light</item>
<item name="allAppsNavBarScrimColor">#66FFFFFF</item>
<item name="popupColorPrimary">@color/popup_color_primary_light</item>
@@ -75,6 +75,51 @@
<item name="android:statusBarColor">#00000000</item>
<item name="android:navigationBarColor">#00000000</item>
<item name="android:switchStyle">@style/SwitchStyle</item>
+
+ <item name="materialColorOnSecondaryFixedVariant">@color/material_color_on_secondary_fixed_variant</item>
+ <item name="materialColorOnTertiaryFixedVariant">@color/material_color_on_tertiary_fixed_variant</item>
+ <item name="materialColorSurfaceContainerLowest">@color/material_color_surface_container_lowest</item>
+ <item name="materialColorOnPrimaryFixedVariant">@color/material_color_on_primary_fixed_variant</item>
+ <item name="materialColorOnSecondaryContainer">@color/material_color_on_secondary_container</item>
+ <item name="materialColorOnTertiaryContainer">@color/material_color_on_tertiary_container</item>
+ <item name="materialColorSurfaceContainerLow">@color/material_color_surface_container_low</item>
+ <item name="materialColorOnPrimaryContainer">@color/material_color_on_primary_container</item>
+ <item name="materialColorSecondaryFixedDim">@color/material_color_secondary_fixed_dim</item>
+ <item name="materialColorOnErrorContainer">@color/material_color_on_error_container</item>
+ <item name="materialColorOnSecondaryFixed">@color/material_color_on_secondary_fixed</item>
+ <item name="materialColorOnSurfaceInverse">@color/material_color_on_surface_inverse</item>
+ <item name="materialColorTertiaryFixedDim">@color/material_color_tertiary_fixed_dim</item>
+ <item name="materialColorOnTertiaryFixed">@color/material_color_on_tertiary_fixed</item>
+ <item name="materialColorPrimaryFixedDim">@color/material_color_primary_fixed_dim</item>
+ <item name="materialColorSecondaryContainer">@color/material_color_secondary_container</item>
+ <item name="materialColorErrorContainer">@color/material_color_error_container</item>
+ <item name="materialColorOnPrimaryFixed">@color/material_color_on_primary_fixed</item>
+ <item name="materialColorPrimaryInverse">@color/material_color_primary_inverse</item>
+ <item name="materialColorSecondaryFixed">@color/material_color_secondary_fixed</item>
+ <item name="materialColorSurfaceInverse">@color/material_color_surface_inverse</item>
+ <item name="materialColorSurfaceVariant">@color/material_color_surface_variant</item>
+ <item name="materialColorTertiaryContainer">@color/material_color_tertiary_container</item>
+ <item name="materialColorTertiaryFixed">@color/material_color_tertiary_fixed</item>
+ <item name="materialColorPrimaryContainer">@color/material_color_primary_container</item>
+ <item name="materialColorOnBackground">@color/material_color_on_background</item>
+ <item name="materialColorPrimaryFixed">@color/material_color_primary_fixed</item>
+ <item name="materialColorOnSecondary">@color/material_color_on_secondary</item>
+ <item name="materialColorOnTertiary">@color/material_color_on_tertiary</item>
+ <item name="materialColorSurfaceDim">@color/material_color_surface_dim</item>
+ <item name="materialColorSurfaceBright">@color/material_color_surface_bright</item>
+ <item name="materialColorOnError">@color/material_color_on_error</item>
+ <item name="materialColorSurface">@color/material_color_surface</item>
+ <item name="materialColorSurfaceContainerHigh">@color/material_color_surface_container_high</item>
+ <item name="materialColorSurfaceContainerHighest">@color/material_color_surface_container_highest</item>
+ <item name="materialColorOnSurfaceVariant">@color/material_color_on_surface_variant</item>
+ <item name="materialColorOutline">@color/material_color_outline</item>
+ <item name="materialColorOutlineVariant">@color/material_color_outline_variant</item>
+ <item name="materialColorOnPrimary">@color/material_color_on_primary</item>
+ <item name="materialColorOnSurface">@color/material_color_on_surface</item>
+ <item name="materialColorSurfaceContainer">@color/material_color_surface_container</item>
+ <item name="materialColorPrimary">@color/material_color_primary</item>
+ <item name="materialColorSecondary">@color/material_color_secondary</item>
+ <item name="materialColorTertiary">@color/material_color_tertiary</item>
</style>
<style name="SwitchStyle"
@@ -105,7 +150,7 @@
<item name="android:textColorHint">#A0FFFFFF</item>
<item name="android:colorControlHighlight">#19FFFFFF</item>
<item name="android:colorPrimary">#FF212121</item>
- <item name="allAppsScrimColor">?android:attr/colorBackgroundFloating</item>
+ <item name="allAppsScrimColor">?attr/materialColorSurfaceDim</item>
<item name="allAppsNavBarScrimColor">#80000000</item>
<item name="popupColorPrimary">@color/popup_color_primary_dark</item>
<item name="popupColorSecondary">@color/popup_color_secondary_dark</item>
diff --git a/src/com/android/launcher3/util/OnboardingPrefs.java b/src/com/android/launcher3/util/OnboardingPrefs.java
index 6573691..348c8d8 100644
--- a/src/com/android/launcher3/util/OnboardingPrefs.java
+++ b/src/com/android/launcher3/util/OnboardingPrefs.java
@@ -40,17 +40,14 @@
public static final String HOTSEAT_LONGPRESS_TIP_SEEN = "launcher.hotseat_longpress_tip_seen";
public static final String SEARCH_KEYBOARD_EDU_SEEN = "launcher.search_edu_seen";
public static final String SEARCH_SNACKBAR_COUNT = "launcher.keyboard_snackbar_count";
- public static final String SEARCH_ONBOARDING_COUNT = "launcher.search_onboarding_count";
public static final String ALL_APPS_VISITED_COUNT = "launcher.all_apps_visited_count";
- public static final String QSB_SEARCH_ONBOARDING_CARD_DISMISSED = "launcher.qsb_edu_dismiss";
public static final String TASKBAR_EDU_TOOLTIP_STEP = "launcher.taskbar_edu_tooltip_step";
// When adding a new key, add it here as well, to be able to reset it from Developer Options.
public static final Map<String, String[]> ALL_PREF_KEYS = Map.of(
"All Apps Bounce", new String[] { HOME_BOUNCE_SEEN, HOME_BOUNCE_COUNT },
"Hybrid Hotseat Education", new String[] { HOTSEAT_DISCOVERY_TIP_COUNT,
HOTSEAT_LONGPRESS_TIP_SEEN },
- "Search Education", new String[] { SEARCH_KEYBOARD_EDU_SEEN, SEARCH_SNACKBAR_COUNT,
- SEARCH_ONBOARDING_COUNT, QSB_SEARCH_ONBOARDING_CARD_DISMISSED},
+ "Search Education", new String[] { SEARCH_KEYBOARD_EDU_SEEN, SEARCH_SNACKBAR_COUNT},
"Taskbar Education", new String[] { TASKBAR_EDU_TOOLTIP_STEP },
"All Apps Visited Count", new String[] {ALL_APPS_VISITED_COUNT}
);
@@ -62,7 +59,6 @@
HOME_BOUNCE_SEEN,
HOTSEAT_LONGPRESS_TIP_SEEN,
SEARCH_KEYBOARD_EDU_SEEN,
- QSB_SEARCH_ONBOARDING_CARD_DISMISSED
})
@Retention(RetentionPolicy.SOURCE)
public @interface EventBoolKey {}
@@ -74,7 +70,6 @@
HOME_BOUNCE_COUNT,
HOTSEAT_DISCOVERY_TIP_COUNT,
SEARCH_SNACKBAR_COUNT,
- SEARCH_ONBOARDING_COUNT,
ALL_APPS_VISITED_COUNT,
TASKBAR_EDU_TOOLTIP_STEP,
})
@@ -88,8 +83,6 @@
maxCounts.put(HOME_BOUNCE_COUNT, 3);
maxCounts.put(HOTSEAT_DISCOVERY_TIP_COUNT, 5);
maxCounts.put(SEARCH_SNACKBAR_COUNT, 3);
- // This is the sum of all onboarding cards. Currently there is only 1 card shown 3 times.
- maxCounts.put(SEARCH_ONBOARDING_COUNT, 3);
maxCounts.put(ALL_APPS_VISITED_COUNT, 20);
maxCounts.put(TASKBAR_EDU_TOOLTIP_STEP, 2);
MAX_COUNTS = Collections.unmodifiableMap(maxCounts);