diff --git a/res/layout/workspace_custom_content.xml b/res/layout/workspace_custom_content.xml deleted file mode 100644 index 649768515b..0000000000 --- a/res/layout/workspace_custom_content.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - - diff --git a/src/com/android/launcher3/Workspace.java b/src/com/android/launcher3/Workspace.java index 88c8e2a5ca..57b0ca0cbc 100644 --- a/src/com/android/launcher3/Workspace.java +++ b/src/com/android/launcher3/Workspace.java @@ -513,7 +513,7 @@ public class Workspace extends SmoothPagedView public void addCustomContentToLeft(View customContent) { CellLayout customScreen = (CellLayout) - mLauncher.getLayoutInflater().inflate(R.layout.workspace_custom_content, null); + mLauncher.getLayoutInflater().inflate(R.layout.workspace_screen, null); int spanX = customScreen.getCountX(); int spanY = customScreen.getCountY(); @@ -523,6 +523,10 @@ public class Workspace extends SmoothPagedView customScreen.addViewToCellLayout(customContent, 0, 0, lp, true); + Rect p = new Rect(); + AppWidgetHostView.getDefaultPaddingForWidget(mLauncher, mLauncher.getComponentName(), p); + customContent.setPadding(p.left, p.top, p.right, p.bottom); + addView(customScreen, 0); mWorkspaceScreens.put(CUSTOM_CONTENT_SCREEN_ID, customScreen);