Giving proper workspace description when the launcher is not loaded.
am: 5be3e4c
* commit '5be3e4cc529f75b894d4603c9fd1342b370766e0':
Giving proper workspace description when the launcher is not loaded.
Change-Id: I13684173a45e23e6a1add5495280457bf5b274ba
diff --git a/src/com/android/launcher3/Workspace.java b/src/com/android/launcher3/Workspace.java
index f04244f..4aea85e 100644
--- a/src/com/android/launcher3/Workspace.java
+++ b/src/com/android/launcher3/Workspace.java
@@ -4255,6 +4255,10 @@
}
nScreens--;
}
+ if (nScreens == 0) {
+ // When the workspace is not loaded, we do not know how many screen will be bound.
+ return getContext().getString(R.string.all_apps_home_button_label);
+ }
return getContext().getString(R.string.workspace_scroll_format,
page + 1 - delta, nScreens);
}