Time circuits, after Back to the Future: three LED rows (the car as the destination, the present time, the last departure from P), the speed in red digits and a flux capacitor that flows with the power; at 88 km/h it all flashes. Letters on fourteen segments (Segments14, tested). Quest, after World of Warcraft's interface: player frame, minimap, gold speed, cast bar, quest tracker, chat, action bar and the odometer as experience. Both in their own colours, the app with them. In THEMES.md with screenshots. Emulator only; not tried on the car. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LhzAVaUyqcw5PkGjz4mWW6
34 lines
1.5 KiB
Java
34 lines
1.5 KiB
Java
package com.evsuite.abrp;
|
|
|
|
/**
|
|
* The app's colours while an Overview style shows its own palette: the theme overlay
|
|
* (res/values/style_palettes.xml) that MainActivity lays over the accent colour, so the
|
|
* navigation and the rest of the app match the style — Retro's turquoise, Terminal's green
|
|
* phosphor, and so on. Styles drawn in the accent colour have none.
|
|
*/
|
|
final class StylePalette {
|
|
|
|
private StylePalette() {}
|
|
|
|
/** The overlay for a style's own palette, or 0 for a style that has none. */
|
|
static int overlay(OverviewStyle style) {
|
|
switch (style) {
|
|
case RETRO: return R.style.ThemeOverlay_EV_Style_Retro;
|
|
case TERMINAL: return R.style.ThemeOverlay_EV_Style_Terminal;
|
|
case SCIFI: return R.style.ThemeOverlay_EV_Style_SciFi;
|
|
case CARTOON: return R.style.ThemeOverlay_EV_Style_Cartoon;
|
|
case NIXIE: return R.style.ThemeOverlay_EV_Style_Nixie;
|
|
case GRID: return R.style.ThemeOverlay_EV_Style_Grid;
|
|
case TIME_CIRCUITS: return R.style.ThemeOverlay_EV_Style_TimeCircuits;
|
|
case QUEST: return R.style.ThemeOverlay_EV_Style_Quest;
|
|
default: return 0;
|
|
}
|
|
}
|
|
|
|
/** The overlay the app wears: the style's own when it shows its palette, else the accent's. */
|
|
static int appOverlay(OverviewStyle style, boolean originalChosen, AccentColor accent) {
|
|
int own = overlay(style);
|
|
return own != 0 && style.showsOwnPalette(originalChosen) ? own : accent.overlay;
|
|
}
|
|
}
|