Scale preview padding in UITheme metrics

Apply scaling to previewPadding metric while keeping previewHeightPercent intentionally unscaled. Adds clarifying comment about the different scaling behavior between these two preview-related metrics.
This commit is contained in:
Justin Mitchell
2026-06-21 01:23:56 -04:00
parent 3e0ba4488b
commit 4e156e1617
2 changed files with 4 additions and 1 deletions
+3
View File
@@ -40,6 +40,9 @@ ThemeMetrics scaleThemeMetrics(const ThemeMetrics& b, float s) {
m.batteryBarHeight = sp(b.batteryBarHeight, s);
m.headerHeight = sp(b.headerHeight, s);
m.verticalSpacing = sp(b.verticalSpacing, s);
// previewPadding is a pixel inset (font preview pane); scaled. previewHeightPercent is a
// percent of the usable height and is intentionally NOT scaled.
m.previewPadding = sp(b.previewPadding, s);
m.contentSidePadding = sp(b.contentSidePadding, s);
m.listRowHeight = sp(b.listRowHeight, s);
m.listWithSubtitleRowHeight = sp(b.listWithSubtitleRowHeight, s);