mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-04 01:46:49 +00:00
Move LauncherApplication's state and code to LauncherAppState.
This removes Launcher's static data and other state out of the Application object. Now LauncherApplication (extends Application) exists only to instantiate LauncherAppState. Change-Id: I4e323bd78b77536b92054105536a55c0c2c19ba8
This commit is contained in:
@@ -251,7 +251,7 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen
|
||||
mPackageManager = context.getPackageManager();
|
||||
mApps = new ArrayList<ApplicationInfo>();
|
||||
mWidgets = new ArrayList<Object>();
|
||||
mIconCache = ((LauncherApplication) context.getApplicationContext()).getIconCache();
|
||||
mIconCache = (LauncherAppState.getInstance()).getIconCache();
|
||||
mCanvas = new Canvas();
|
||||
mRunningTasks = new ArrayList<AppsCustomizeAsyncTask>();
|
||||
|
||||
@@ -362,7 +362,7 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen
|
||||
Configuration.ORIENTATION_LANDSCAPE;
|
||||
int maxCellCountX = Integer.MAX_VALUE;
|
||||
int maxCellCountY = Integer.MAX_VALUE;
|
||||
if (LauncherApplication.isScreenLarge()) {
|
||||
if (LauncherAppState.isScreenLarge()) {
|
||||
maxCellCountX = (isLandscape ? LauncherModel.getCellCountX() :
|
||||
LauncherModel.getCellCountY());
|
||||
maxCellCountY = (isLandscape ? LauncherModel.getCellCountY() :
|
||||
|
||||
Reference in New Issue
Block a user