Add two extra empty pages on two panel launcher home

Add a new screen ID for the second extra empty page
and add that new screen as well when the existing
extra empty page is added so that users can put items
on both sides of Workspace.

Test: manual
Bug: 196376162
Change-Id: I0b4f2e818407a10d8a7c032788a7bd7a61267779
This commit is contained in:
Andras Kloczl
2021-08-28 00:59:08 +01:00
parent 667bda8448
commit 408a54f2e7
7 changed files with 210 additions and 74 deletions

View File

@@ -232,9 +232,9 @@ public class ItemInfo {
* Write the fields of this item to the DB
*/
public void onAddToDatabase(ContentWriter writer) {
if (screenId == Workspace.EXTRA_EMPTY_SCREEN_ID) {
if (Workspace.EXTRA_EMPTY_SCREEN_IDS.contains(screenId)) {
// We should never persist an item on the extra empty screen.
throw new RuntimeException("Screen id should not be EXTRA_EMPTY_SCREEN_ID");
throw new RuntimeException("Screen id should not be extra empty screen: " + screenId);
}
writeToValues(writer);