Skip to the end of the folder open animation in battery saver mode.
Bug: 25666809
Change-Id: I867d56a34fc5e0ad6aaabd8b6df47be05ec31966
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index 9824e3e..658272f 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -3125,6 +3125,10 @@
}
oa.setDuration(getResources().getInteger(R.integer.config_folderExpandDuration));
oa.start();
+ if (Utilities.isPowerSaverOn(this)) {
+ // Animations are disabled in battery saver mode, so just skip to the end state.
+ oa.end();
+ }
}
private void shrinkAndFadeInFolderIcon(final FolderIcon fi, boolean animate) {