From cecb8aca3b2e52f28b57b1cbda0d9987d3d5a012 Mon Sep 17 00:00:00 2001 From: sspanak Date: Thu, 30 May 2024 16:09:22 +0300 Subject: [PATCH] fixed the button separators changing width or missing when the main layout is set to 'Functional Keys' --- .../io/github/sspanak/tt9/ui/main/MainLayoutTray.java | 8 ++++---- app/src/main/res/layout/main_small.xml | 8 ++++++++ 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/app/src/main/java/io/github/sspanak/tt9/ui/main/MainLayoutTray.java b/app/src/main/java/io/github/sspanak/tt9/ui/main/MainLayoutTray.java index cf9468bc..a8776cab 100644 --- a/app/src/main/java/io/github/sspanak/tt9/ui/main/MainLayoutTray.java +++ b/app/src/main/java/io/github/sspanak/tt9/ui/main/MainLayoutTray.java @@ -70,10 +70,9 @@ class MainLayoutTray extends BaseMainLayout { } // separators - Drawable separatorColor = getSeparatorColor(view, dark); for (View separator : getSeparators()) { if (separator != null) { - separator.setBackground(separatorColor); + separator.setBackground(getSeparatorColor(separator, dark)); } } } @@ -100,10 +99,11 @@ class MainLayoutTray extends BaseMainLayout { @Override protected ArrayList getSeparators() { return new ArrayList<>(Arrays.asList( + view.findViewById(R.id.separator_top), + view.findViewById(R.id.separator_candidates_bottom), view.findViewById(R.id.separator_2_1), view.findViewById(R.id.separator_2_2), - view.findViewById(R.id.separator_3_1), - view.findViewById(R.id.separator_3_2) + view.findViewById(R.id.separator_3_1) )); } } diff --git a/app/src/main/res/layout/main_small.xml b/app/src/main/res/layout/main_small.xml index 52b2b6a4..2efaa893 100644 --- a/app/src/main/res/layout/main_small.xml +++ b/app/src/main/res/layout/main_small.xml @@ -5,6 +5,10 @@ android:layout_height="wrap_content" android:orientation="vertical"> + + @@ -27,6 +31,10 @@ + +