Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
e
os
Notes
Commits
6b836e86
Commit
6b836e86
authored
Dec 14, 2020
by
Amit Kumar
💻
Browse files
Merge branch 'e-theme-improvement' into 'master'
e theme improvement See merge request e/apps/notes!17
parents
e6b3d464
896a3922
Pipeline
#90300
passed with stage
in 3 minutes and 22 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
app/src/main/java/foundation/e/notes/model/NavigationAdapter.java
View file @
6b836e86
...
...
@@ -5,6 +5,7 @@ import android.graphics.Color;
import
androidx.annotation.DrawableRes
;
import
androidx.annotation.NonNull
;
import
androidx.annotation.Nullable
;
import
androidx.core.graphics.ColorUtils
;
import
androidx.recyclerview.widget.RecyclerView
;
import
android.util.TypedValue
;
...
...
@@ -100,7 +101,8 @@ public class NavigationAdapter extends RecyclerView.Adapter<NavigationAdapter.Vi
}
else
{
icon
.
setVisibility
(
View
.
GONE
);
}
view
.
setBackgroundColor
(
isSelected
?
view
.
getResources
().
getColor
(
R
.
color
.
bg_selected_item
)
:
Color
.
TRANSPARENT
);
// view.setBackgroundColor(isSelected ? view.getResources().getColor(R.color.bg_selected_item) : Color.TRANSPARENT);
view
.
setBackgroundColor
(
isSelected
?
ColorUtils
.
setAlphaComponent
(
view
.
getResources
().
getColor
(
R
.
color
.
accent_color
),
20
)
:
Color
.
TRANSPARENT
);
int
textColor
=
view
.
getResources
().
getColor
(
isSelected
?
R
.
color
.
accent_color
:
R
.
color
.
fg_default
);
name
.
setTextColor
(
textColor
);
...
...
app/src/main/res/layout/drawer_layout.xml
View file @
6b836e86
...
...
@@ -34,6 +34,7 @@
android:id=
"@+id/header_view"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:visibility=
"gone"
android:background=
"?attr/colorAccent"
android:theme=
"@style/AppTheme"
>
...
...
app/src/main/res/values/colors.xml
View file @
6b836e86
...
...
@@ -2,10 +2,10 @@
<resources>
<!-- Colors -->
<color
name=
"primary"
>
#ffffff
</color>
<color
name=
"primary_dark"
>
#ffffff
</color>
<color
name=
"primary"
>
@lineageos.platform:color/color_default_primary
</color>
<color
name=
"primary_dark"
>
@lineageos.platform:color/color_default_primary_dark
</color>
<color
name=
"accent_color"
>
@lineageos.platform:color/color_default_
primary
</color>
<color
name=
"accent_color"
>
@lineageos.platform:color/color_default_
accent
</color>
<color
name=
"separator"
>
#fbfbfb
</color>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment