am bb6fda6a: Provide final callbacks before remove CustomContent (issue 11169651)
* commit 'bb6fda6ac3c4246b91cf66b28cdbc89c3d8a3e52':
Provide final callbacks before remove CustomContent (issue 11169651)
diff --git a/src/com/android/launcher3/Workspace.java b/src/com/android/launcher3/Workspace.java
index 7a16474..bbe0946 100644
--- a/src/com/android/launcher3/Workspace.java
+++ b/src/com/android/launcher3/Workspace.java
@@ -557,6 +557,12 @@
mWorkspaceScreens.remove(CUSTOM_CONTENT_SCREEN_ID);
mScreenOrder.remove(CUSTOM_CONTENT_SCREEN_ID);
removeView(customScreen);
+
+ if (mCustomContentCallbacks != null) {
+ mCustomContentCallbacks.onScrollProgressChanged(0);
+ mCustomContentCallbacks.onHide();
+ }
+
mCustomContentCallbacks = null;
// Ensure that the current page and default page are maintained.