Expose icon scale to properly shape themed icons
Bug: 394902299 Test: tested with themed/forced-themed icons on and off Flag: com.android.launcher3.enable_launcher_icon_shapes Change-Id: I5b189b8dcfefe195e42b8cfad1bda9e18fd80a29
This commit is contained in:
@@ -66,11 +66,16 @@ internal constructor(
|
||||
return userCache.getUserInfo(user)
|
||||
}
|
||||
|
||||
public override fun getShapePath(drawable: AdaptiveIconDrawable, iconBounds: Rect): Path {
|
||||
if (!Flags.enableLauncherIconShapes()) return drawable.iconMask
|
||||
override fun getShapePath(drawable: AdaptiveIconDrawable, iconBounds: Rect): Path {
|
||||
if (!Flags.enableLauncherIconShapes()) return super.getShapePath(drawable, iconBounds)
|
||||
return themeManager.iconShape.getPath(iconBounds)
|
||||
}
|
||||
|
||||
override fun getIconScale(): Float {
|
||||
if (!Flags.enableLauncherIconShapes()) return super.getIconScale()
|
||||
return themeManager.iconState.iconScale
|
||||
}
|
||||
|
||||
override fun drawAdaptiveIcon(
|
||||
canvas: Canvas,
|
||||
drawable: AdaptiveIconDrawable,
|
||||
|
||||
Reference in New Issue
Block a user