Skip to content
Open
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
4 changes: 2 additions & 2 deletions app/src/main/res/drawable/menu_selector.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,6 @@
-->

<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:color="@color/selected" android:state_checked="true" />
<item android:color="@color/regular" android:state_checked="false" />
<item android:color="?attr/colorPrimary" android:state_checked="true" />
<item android:color="?attr/colorOnSurfaceVariant" android:state_checked="false" />
</selector>
33 changes: 33 additions & 0 deletions app/src/main/res/drawable/navigation_drawer_item_background.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
~ WiFiAnalyzer
~ Copyright (C) 2015 - 2026 VREM Software Development <VREMSoftwareDevelopment@gmail.com>
~
~ This program is free software: you can redistribute it and/or modify
~ it under the terms of the GNU General Public License as published by
~ the Free Software Foundation, either version 3 of the License, or
~ (at your option) any later version.
~
~ This program is distributed in the hope that it will be useful,
~ but WITHOUT ANY WARRANTY; without even the implied warranty of
~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
~ GNU General Public License for more details.
~
~ You should have received a copy of the GNU General Public License
~ along with this program. If not, see <http://www.gnu.org/licenses/>
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_checked="true">
<inset
android:insetLeft="12dp"
android:insetTop="4dp"
android:insetRight="12dp"
Comment on lines +22 to +24
Copy link

Copilot AI Apr 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This drawable uses insetLeft/insetRight, which won’t mirror in RTL layouts even though the app enables RTL (supportsRtl=true). Use insetStart/insetEnd so selection insets are correct for RTL users.

Suggested change
android:insetLeft="12dp"
android:insetTop="4dp"
android:insetRight="12dp"
android:insetStart="12dp"
android:insetTop="4dp"
android:insetEnd="12dp"

Copilot uses AI. Check for mistakes.
android:insetBottom="4dp">
<shape android:shape="rectangle">
<corners android:radius="16dp" />
<solid android:color="@color/brand_primary_container" />
</shape>
</inset>
</item>
<item android:drawable="@android:color/transparent" />
</selector>
4 changes: 2 additions & 2 deletions app/src/main/res/layout/main_activity.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
android:id="@+id/drawer_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/background"
Copy link

Copilot AI Apr 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Setting the root background to @color/background makes the activity surface use the day/night palette even when ThemeBlack is selected. Since ThemeBlack overrides colorSurface/windowBackground to true black, consider using a theme attribute here (e.g. ?attr/colorSurface / ?android:attr/colorBackground) instead of a fixed @color/* resource so the black theme remains actually black.

Suggested change
android:background="@color/background"
android:background="?attr/colorSurface"

Copilot uses AI. Check for mistakes.
android:fitsSystemWindows="true"
tools:openDrawer="start">

Expand All @@ -33,11 +34,10 @@
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_gravity="start"
android:background="?attr/colorSurface"
android:fitsSystemWindows="true"
android:saveEnabled="false"
app:headerLayout="@layout/main_navigation"
app:itemIconTint="@drawable/menu_selector"
app:itemTextColor="@drawable/menu_selector"
app:menu="@menu/nav_drawer_menu" />

</androidx.drawerlayout.widget.DrawerLayout>
11 changes: 7 additions & 4 deletions app/src/main/res/layout/main_connection.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,12 @@
android:id="@+id/connection"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/background"
android:background="@color/surface_container_high"
android:orientation="vertical"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingStart="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_half_margin"
android:paddingEnd="@dimen/activity_horizontal_margin"
android:paddingBottom="@dimen/activity_vertical_half_margin"
android:visibility="gone"
tools:visibility="visible">

Expand Down Expand Up @@ -77,7 +79,8 @@
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="@color/selected" />
android:layout_marginTop="@dimen/activity_vertical_half_margin"
android:background="@color/outline" />
</LinearLayout>

<include layout="@layout/main_wifi_support" />
Expand Down
14 changes: 7 additions & 7 deletions app/src/main/res/layout/main_content.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_height="match_parent"
android:background="@color/background"
android:orientation="vertical">
Comment on lines 22 to 25
Copy link

Copilot AI Apr 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The layout background is hardcoded to @color/background. This will override the theme’s android:windowBackground and can prevent ThemeBlack from rendering true black surfaces (since @color/background resolves to the day/night surface). Prefer using a theme attribute (?attr/colorSurface/?android:attr/colorBackground) so theme overrides control the actual background.

Copilot uses AI. Check for mistakes.

<include layout="@layout/main_toolbar" />
Expand All @@ -31,16 +32,17 @@
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:background="@color/background"
android:orientation="vertical"
Comment on lines 33 to 36
Copy link

Copilot AI Apr 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This container also hardcodes @color/background, which can fight the theme’s surface colors (notably the black theme) and makes future theme tweaks harder. Prefer a theme attribute background so ThemeBase/ThemeBlack can control the surface consistently.

Copilot uses AI. Check for mistakes.
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingStart="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingEnd="@dimen/activity_horizontal_margin"
android:paddingBottom="@dimen/activity_vertical_margin">

<FrameLayout
android:id="@+id/main_fragment"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
android:layout_height="match_parent" />

</LinearLayout>

Expand All @@ -49,9 +51,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:background="@color/primary_material_dark"
app:itemIconTint="@drawable/menu_selector"
app:itemTextColor="@drawable/menu_selector"
android:background="?attr/colorSurface"
app:labelVisibilityMode="labeled"
app:menu="@menu/nav_bottom_menu" />

Expand Down
11 changes: 6 additions & 5 deletions app/src/main/res/layout/main_navigation.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="@dimen/nav_header_height"
android:background="@color/background"
android:background="@color/drawer_header_background"
android:gravity="bottom"
android:orientation="horizontal"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingStart="@dimen/activity_horizontal_margin"
android:paddingEnd="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin">

<ImageView
Expand All @@ -38,9 +38,10 @@
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingStart="@dimen/activity_horizontal_margin"
android:paddingEnd="@dimen/activity_horizontal_margin"
android:text="@string/app_full_name"
android:textColor="@color/on_surface"
Copy link

Copilot AI Apr 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This header title hardcodes @color/on_surface. Since ThemeBlack overrides the theme’s colorOnSurface, using a fixed resource here can make the black theme inconsistent. Prefer android:textColor="?attr/colorOnSurface" (or a theme attribute) so the text adapts to the active theme overrides.

Suggested change
android:textColor="@color/on_surface"
android:textColor="?attr/colorOnSurface"

Copilot uses AI. Check for mistakes.
android:textStyle="bold" />

</LinearLayout>
7 changes: 6 additions & 1 deletion app/src/main/res/layout/main_toolbar.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,22 @@
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/colorSurface"
android:fitsSystemWindows="true">

<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/colorSurface"
android:elevation="0dp"
android:theme="@style/ThemeOverlay">

<androidx.appcompat.widget.Toolbar
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize" />
android:layout_height="?attr/actionBarSize"
android:paddingStart="@dimen/activity_horizontal_margin"
android:paddingEnd="@dimen/activity_horizontal_margin" />
Comment on lines 26 to +38
Copy link

Copilot AI Apr 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

android:theme is set to @style/ThemeOverlay (an AppCompat dark action bar overlay) while the toolbar/AppBar now uses a light colorSurface background. This combination can force light/white toolbar icons and menu text on a light surface. Consider using a Material3 toolbar overlay (or removing the overlay) and/or switching to MaterialToolbar so icon/text colors are derived from colorOnSurface.

Copilot uses AI. Check for mistakes.

</com.google.android.material.appbar.AppBarLayout>

Expand Down
46 changes: 46 additions & 0 deletions app/src/main/res/values-night/colors.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
~ WiFiAnalyzer
~ Copyright (C) 2015 - 2026 VREM Software Development <VREMSoftwareDevelopment@gmail.com>
~
~ This program is free software: you can redistribute it and/or modify
~ it under the terms of the GNU General Public License as published by
~ the Free Software Foundation, either version 3 of the License, or
~ (at your option) any later version.
~
~ This program is distributed in the hope that it will be useful,
~ but WITHOUT ANY WARRANTY; without even the implied warranty of
~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
~ GNU General Public License for more details.
~
~ You should have received a copy of the GNU General Public License
~ along with this program. If not, see <http://www.gnu.org/licenses/>
-->
<resources>
<color name="brand_primary">#A8C7FA</color>
<color name="brand_on_primary">#0A1B33</color>
<color name="brand_primary_container">#20406C</color>
<color name="brand_on_primary_container">#D7E3FF</color>

<color name="surface">#101418</color>
<color name="surface_variant">#1F2630</color>
<color name="surface_container">#171C22</color>
<color name="surface_container_high">#20262E</color>
<color name="on_surface">#E3E9F1</color>
<color name="on_surface_variant">#AAB5C3</color>
<color name="outline">#3C4654</color>
<color name="drawer_header_background">#16202B</color>

<color name="regular">@color/on_surface_variant</color>
<color name="selected">@color/brand_primary</color>
<color name="channel">@color/on_surface_variant</color>
<color name="channel_number">#5ED3CD</color>
<color name="frequency">#83B8FF</color>
<color name="security">#D7CCC8</color>
<color name="distance">#86D993</color>
<color name="error">#FFB4AB</color>
<color name="warning">#F3C969</color>
<color name="success">#86D993</color>
<color name="background">@color/surface</color>
<color name="black">#000000</color>
</resources>
49 changes: 25 additions & 24 deletions app/src/main/res/values/colors.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,30 +16,31 @@
~ You should have received a copy of the GNU General Public License
~ along with this program. If not, see <http://www.gnu.org/licenses/>
-->

<resources>
<!-- grey_500 -->
<color name="regular">#9E9E9E</color>
<!-- blue_500 -->
<color name="selected">#2196F3</color>
<!-- grey_500 -->
<color name="channel">@color/regular</color>
<!-- cyan_500 -->
<color name="channel_number">#00BCD4</color>
<!-- cyan_700 -->
<color name="frequency">#0097A7</color>
<!-- blue_grey_500 -->
<color name="security">#607D8B</color>
<!-- teal_500 -->
<color name="distance">#009688</color>
<!-- red_500 -->
<color name="error">#F44336</color>
<!-- amber_500 -->
<color name="warning">#FFC107</color>
<!-- green_500 -->
<color name="success">#4CAF50</color>
<!-- background -->
<color name="background">#757575</color>
<!-- black -->
<color name="brand_primary">#1A73E8</color>
<color name="brand_on_primary">#FFFFFF</color>
<color name="brand_primary_container">#D7E3FF</color>
<color name="brand_on_primary_container">#001B3D</color>

<color name="surface">#F4F7FB</color>
<color name="surface_variant">#E3EAF4</color>
<color name="surface_container">#FFFFFF</color>
<color name="surface_container_high">#EDF2F8</color>
<color name="on_surface">#15202B</color>
<color name="on_surface_variant">#5F6B7A</color>
<color name="outline">#C7D0DD</color>
<color name="drawer_header_background">#E8F0FE</color>

<color name="regular">@color/on_surface_variant</color>
<color name="selected">@color/brand_primary</color>
<color name="channel">@color/on_surface_variant</color>
<color name="channel_number">#0B8A83</color>
<color name="frequency">#1565C0</color>
<color name="security">#6D4C41</color>
<color name="distance">#2E7D32</color>
<color name="error">#BA1A1A</color>
<color name="warning">#9A6700</color>
<color name="success">#2E7D32</color>
<color name="background">@color/surface</color>
<color name="black">#000000</color>
</resources>
Loading
Loading