Adding a DB update path to handle the QSB position change
> Renamed the id of 1st screen to 0 and making space for the QSB by running the grid migration task. > Added a feature flag to easily disable the QSB-in-workspace behavior Change-Id: Ie3369f0d4433d916e9d6215d414770d4333f3e26
This commit is contained in:
@@ -510,6 +510,9 @@ public class Workspace extends PagedView
|
||||
* @param qsb an exisitng qsb to recycle or null.
|
||||
*/
|
||||
public void bindAndInitFirstWorkspaceScreen(View qsb) {
|
||||
if (!FeatureFlags.QSB_ON_FIRST_SCREEN) {
|
||||
return;
|
||||
}
|
||||
// Add the first page
|
||||
CellLayout firstPage = insertNewWorkspaceScreen(Workspace.FIRST_SCREEN_ID, 0);
|
||||
|
||||
@@ -909,7 +912,8 @@ public class Workspace extends PagedView
|
||||
long id = mWorkspaceScreens.keyAt(i);
|
||||
CellLayout cl = mWorkspaceScreens.valueAt(i);
|
||||
// FIRST_SCREEN_ID can never be removed.
|
||||
if (id > FIRST_SCREEN_ID && cl.getShortcutsAndWidgets().getChildCount() == 0) {
|
||||
if ((!FeatureFlags.QSB_ON_FIRST_SCREEN || id > FIRST_SCREEN_ID)
|
||||
&& cl.getShortcutsAndWidgets().getChildCount() == 0) {
|
||||
removeScreens.add(id);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user