Removing layout handling in DeviceProfile and moving it to
individual views
Bug: 71709920
Change-Id: I8300fa7a84b31898bdb135d774cca576d2928525
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index adfb44c..4d58593 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -337,8 +337,6 @@
mLauncherView = LayoutInflater.from(this).inflate(R.layout.launcher, null);
setupViews();
- mDeviceProfile.layout(this, false /* notifyListeners */);
-
mPopupDataProvider = new PopupDataProvider(this);
mRotationEnabled = getResources().getBoolean(R.bool.allow_rotation);
@@ -392,6 +390,7 @@
? SCREEN_ORIENTATION_UNSPECIFIED : SCREEN_ORIENTATION_NOSENSOR);
setContentView(mLauncherView);
+ ((LauncherRootView) mLauncherView).dispatchInsets();
// Listen for broadcasts
IntentFilter filter = new IntentFilter();
@@ -441,11 +440,6 @@
private LauncherCallbacks mLauncherCallbacks;
- public void onInsetsChanged(Rect insets) {
- mDeviceProfile.updateInsets(insets);
- mDeviceProfile.layout(this, true /* notifyListeners */);
- }
-
/**
* Call this after onCreate to set or clear overlay.
*/