use of com.android.launcher3.InvariantDeviceProfile.CHANGE_FLAG_ICON_PARAMS in project android_packages_apps_Trebuchet by LineageOS.
the class InvariantDeviceProfile method onConfigChanged.
private void onConfigChanged(Context context) {
// Config changes, what shall we do?
InvariantDeviceProfile oldProfile = new InvariantDeviceProfile(this);
// Re-init grid
String gridName = getCurrentGridName(context);
initGrid(context, Utilities.getPrefs(context).getString(KEY_IDP_GRID_NAME, gridName));
int changeFlags = 0;
if (numRows != oldProfile.numRows || numColumns != oldProfile.numColumns || numFolderColumns != oldProfile.numFolderColumns || numFolderRows != oldProfile.numFolderRows || numHotseatIcons != oldProfile.numHotseatIcons) {
changeFlags |= CHANGE_FLAG_GRID;
}
if (iconSize != oldProfile.iconSize || iconBitmapSize != oldProfile.iconBitmapSize || !iconShapePath.equals(oldProfile.iconShapePath) || !iconPack.equals(oldProfile.iconPack)) {
changeFlags |= CHANGE_FLAG_ICON_PARAMS;
}
if (!iconShapePath.equals(oldProfile.iconShapePath)) {
IconShape.init(context);
}
apply(context, changeFlags);
}
Aggregations