Sync prediction client and folders

- Notifies prediction client when a folder is converted into workspace
item as a result of losing all items but one.
- Notifies predction client when a folder is created from an item in the
workspace with no duplicates.

Bug: 148749638
Test: Manual
Change-Id: Ifd51a6fe2a40c8baf4d88e2dba1e5bdc925e1608
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index d250658..89c3b93 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -100,6 +100,7 @@
 import com.android.launcher3.dragndrop.DragController;
 import com.android.launcher3.dragndrop.DragLayer;
 import com.android.launcher3.dragndrop.DragView;
+import com.android.launcher3.folder.Folder;
 import com.android.launcher3.folder.FolderGridOrganizer;
 import com.android.launcher3.folder.FolderIcon;
 import com.android.launcher3.graphics.RotationMode;
@@ -1718,8 +1719,8 @@
     /**
      * Creates and adds new folder to CellLayout
      */
-    public FolderIcon addFolder(CellLayout layout, WorkspaceItemInfo info, int container,
-            final int screenId, int cellX, int cellY) {
+    public FolderIcon addFolder(CellLayout layout, int container, final int screenId, int cellX,
+            int cellY) {
         final FolderInfo folderInfo = new FolderInfo();
         folderInfo.title = "";
 
@@ -1737,6 +1738,16 @@
     }
 
     /**
+     * Called when a workspace item is converted into a folder
+     */
+    public void folderCreatedFromItem(Folder folder, WorkspaceItemInfo itemInfo){}
+
+    /**
+     * Called when a folder is converted into a workspace item
+     */
+    public void folderConvertedToItem(Folder folder, WorkspaceItemInfo itemInfo) {}
+
+    /**
      * Unbinds the view for the specified item, and removes the item and all its children.
      *
      * @param v the view being removed.