diff --git a/quickstep/recents_ui_overrides/src/com/android/quickstep/views/DigitalWellBeingToast.java b/quickstep/recents_ui_overrides/src/com/android/quickstep/views/DigitalWellBeingToast.java
index 19e9cb4..446fb39 100644
--- a/quickstep/recents_ui_overrides/src/com/android/quickstep/views/DigitalWellBeingToast.java
+++ b/quickstep/recents_ui_overrides/src/com/android/quickstep/views/DigitalWellBeingToast.java
@@ -24,7 +24,6 @@
 import android.content.Intent;
 import android.content.pm.LauncherApps;
 import android.content.pm.LauncherApps.AppUsageLimit;
-import android.content.res.Resources;
 import android.icu.text.MeasureFormat;
 import android.icu.text.MeasureFormat.FormatWidth;
 import android.icu.util.Measure;
@@ -54,7 +53,7 @@
     private final LauncherApps mLauncherApps;
 
     public interface InitializeCallback {
-        void call(float saturation, String contentDescription);
+        void call(String contentDescription);
     }
 
     private static final String TAG = DigitalWellBeingToast.class.getSimpleName();
@@ -84,7 +83,7 @@
 
         if (task.key.userId != UserHandle.myUserId()) {
             setVisibility(GONE);
-            callback.call(1, task.titleDescription);
+            callback.call(task.titleDescription);
             return;
         }
 
@@ -99,7 +98,7 @@
                     usageLimit != null ? usageLimit.getUsageRemaining() : -1;
 
             post(() -> {
-                if (appUsageLimitTimeMs < 0) {
+                if (appUsageLimitTimeMs < 0 || appRemainingTimeMs < 0) {
                     setVisibility(GONE);
                 } else {
                     setVisibility(VISIBLE);
@@ -108,10 +107,8 @@
                             R.drawable.hourglass_top : R.drawable.hourglass_bottom);
                 }
 
-                callback.call(
-                        appUsageLimitTimeMs >= 0 && appRemainingTimeMs <= 0 ? 0 : 1,
-                        getContentDescriptionForTask(
-                                task, appUsageLimitTimeMs, appRemainingTimeMs));
+                callback.call(getContentDescriptionForTask(
+                        task, appUsageLimitTimeMs, appRemainingTimeMs));
             });
         });
     }
@@ -180,12 +177,9 @@
     }
 
     private String getText(long remainingTime) {
-        final Resources resources = getResources();
-        return (remainingTime <= 0) ?
-                resources.getString(R.string.app_in_grayscale) :
-                resources.getString(
-                        R.string.time_left_for_app,
-                        getRoundedUpToMinuteReadableDuration(remainingTime));
+        return getResources().getString(
+                R.string.time_left_for_app,
+                getRoundedUpToMinuteReadableDuration(remainingTime));
     }
 
     public void openAppUsageSettings() {
@@ -209,7 +203,7 @@
 
     private String getContentDescriptionForTask(
             Task task, long appUsageLimitTimeMs, long appRemainingTimeMs) {
-        return appUsageLimitTimeMs >= 0 ?
+        return appUsageLimitTimeMs >= 0 && appRemainingTimeMs >= 0 ?
                 getResources().getString(
                         R.string.task_contents_description_with_remaining_time,
                         task.titleDescription,
diff --git a/quickstep/recents_ui_overrides/src/com/android/quickstep/views/TaskView.java b/quickstep/recents_ui_overrides/src/com/android/quickstep/views/TaskView.java
index 98495db..6eade49 100644
--- a/quickstep/recents_ui_overrides/src/com/android/quickstep/views/TaskView.java
+++ b/quickstep/recents_ui_overrides/src/com/android/quickstep/views/TaskView.java
@@ -323,9 +323,8 @@
                         }
                         mDigitalWellBeingToast.initialize(
                                 mTask,
-                                (saturation, contentDescription) -> {
+                                contentDescription -> {
                                     setContentDescription(contentDescription);
-                                    mSnapshotView.setSaturation(saturation);
                                     if (mDigitalWellBeingToast.getVisibility() == VISIBLE) {
                                         getRecentsView().onDigitalWellbeingToastShown();
                                     }
diff --git a/quickstep/res/values/strings.xml b/quickstep/res/values/strings.xml
index f5e8fa8..81565a5 100644
--- a/quickstep/res/values/strings.xml
+++ b/quickstep/res/values/strings.xml
@@ -55,10 +55,6 @@
      escaped form of '<'). [CHAR LIMIT=15] -->
     <string name="shorter_duration_less_than_one_minute">&lt; 1 minute</string>
 
-    <!-- Annotation shown on an app card in Recents, telling that the app was switched to a
-    grayscale because it ran over its time limit [CHAR LIMIT=25] -->
-    <string name="app_in_grayscale">App in grayscale</string>
-
     <!-- Annotation shown on an app card in Recents, telling that the app has a usage limit set by
     the user, and a given time is left for it today [CHAR LIMIT=22] -->
     <string name="time_left_for_app"><xliff:g id="time" example="7 minutes">%1$s</xliff:g> left today</string>
