Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,9 @@ public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup c
back.setText("‹ " + getString(R.string.k2go_mod_back));
back.setOnClickListener(v -> requireActivity().getOnBackPressedDispatcher().onBackPressed());

((ImageView) root.findViewById(R.id.k2go_moddet_image)).setImageResource(R.drawable.k2go_module_placeholder);
// K2GO-426: use the same glyph the list row bullet uses (ic_card_dashnode), on the shared hero
// panel, so the Dashboard is consistent between the list and the detail.
((ImageView) root.findViewById(R.id.k2go_moddet_image)).setImageResource(R.drawable.ic_card_dashnode);
((TextView) root.findViewById(R.id.k2go_moddet_title)).setText(R.string.k2go_dash_detail_title);
((TextView) root.findViewById(R.id.k2go_moddet_sub)).setText(R.string.k2go_dash_detail_sub);
((TextView) root.findViewById(R.id.k2go_moddet_desc)).setText(R.string.k2go_dash_detail_desc);
Expand Down
3 changes: 3 additions & 0 deletions controller/app/src/main/res/drawable/ic_card_dashnode.xml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
<!-- K2GO-426: Dashboard glyph (Material dashboard, four rectangles forming a square). One drawable for
both the Module management list row bullet and the detail hero, so the Dashboard stays consistent.
Tinted from the theme at runtime; the fill here is a placeholder color. -->
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="40dp" android:height="40dp" android:viewportWidth="24" android:viewportHeight="24">
<path android:fillColor="#000000" android:pathData="M3 13h8V3H3v10zm0 8h8v-6H3v6zm10 0h8V11h-8v10zm0-18v6h8V3h-8z" />
</vector>
7 changes: 7 additions & 0 deletions controller/app/src/main/res/drawable/k2go_hero_panel.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- K2GO-426: neutral rounded panel behind the module detail hero glyph. Theme-aware fill so the
centered glyph reads on both themes (was: raw full-width glyph, black on dark). -->
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle">
<solid android:color="@color/k2go_hairline" />
<corners android:radius="18dp" />
</shape>
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,18 @@
android:textAppearance="?attr/textAppearanceBodyMedium"
android:textColor="@color/k2go_teal" />

<!-- K2GO-426: hero = neutral panel background + centered glyph. The glyph (src) is set in
code per module and tinted from the theme; padding shrinks it and gives an even margin,
so every module reads the same on both themes (was: raw full-width glyph, black on dark). -->
<ImageView
android:id="@+id/k2go_moddet_image"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_height="180dp"
android:layout_marginTop="8dp"
android:adjustViewBounds="true"
android:background="@drawable/k2go_hero_panel"
android:padding="32dp"
android:scaleType="fitCenter"
android:src="@drawable/k2go_module_placeholder"
android:tint="@color/k2go_teal"
android:importantForAccessibility="no" />

<TextView
Expand Down
Loading