Skip to content

Commit

Permalink
Fix background color on playlisthome
Browse files Browse the repository at this point in the history
Add new icon enquee_new
  • Loading branch information
fast4x committed Oct 26, 2023
1 parent 9385b2e commit 1bb9e49
Show file tree
Hide file tree
Showing 9 changed files with 46 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ fun SecondaryButton(
colorFilter = ColorFilter.tint(colorPalette.text),
modifier = Modifier
.align(Alignment.Center)
.size(18.dp)
.size(24.dp)
)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ fun PlaylistItem(
Box(
modifier = centeredModifier
.clip(thumbnailShape)
.background(color = colorPalette.background1)
.background(color = colorPalette.background4)
.requiredSize(thumbnailSizeDp)
) {
thumbnailContent(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ fun AlbumSongs(
Column(horizontalAlignment = Alignment.CenterHorizontally) {
headerContent {
SecondaryButton(
iconId = R.drawable.addqueue,
iconId = R.drawable.enqueue_new,
enabled = songs.isNotEmpty(),
onClick = { binder?.player?.enqueue(songs.map(Song::asMediaItem)) }
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ fun ArtistLocalSongs(
Column(horizontalAlignment = Alignment.CenterHorizontally) {
headerContent {
SecondaryButton(
iconId = R.drawable.addqueue,
iconId = R.drawable.enqueue_new,
enabled = !songs.isNullOrEmpty(),
onClick = { binder?.player?.enqueue(songs!!.map(Song::asMediaItem)) }
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ fun BuiltInPlaylistSongs(builtInPlaylist: BuiltInPlaylist) {
spacer = 0
)
SecondaryButton(
iconId = R.drawable.addqueue,
iconId = R.drawable.enqueue_new,
enabled = songs.isNotEmpty(),
onClick = {
binder?.player?.enqueue(songs.map(Song::asMediaItem))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ fun HomeScreen(onPlaylistUrl: (String) -> Unit) {
Item(2, stringResource(R.string.playlists), R.drawable.playlist)
Item(3, stringResource(R.string.artists), R.drawable.person)
Item(4, stringResource(R.string.albums), R.drawable.disc)
//Item(5, "Statistics", R.drawable.query_stats)
Item(5, "Statistics", R.drawable.query_stats)
//Item(6, "Settings", R.drawable.equalizer)
}
) { currentTabIndex ->
Expand Down Expand Up @@ -161,14 +161,14 @@ fun HomeScreen(onPlaylistUrl: (String) -> Unit) {
onAlbumClick = { albumRoute(it.id) },
onSearchClick = { searchRoute("") }
)
/*

5 -> HomeStatistics(
onStatisticsType = { statisticsTypeRoute(it)},
onBuiltInPlaylist = { builtInPlaylistRoute(it) },
onPlaylistClick = { localPlaylistRoute(it.id) },
onSearchClick = { searchRoute("") }
)
*/

//6 -> settingsRoute()
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ fun LocalPlaylistSongs(
.padding(bottom = 8.dp)
) {
SecondaryButton(
iconId = R.drawable.addqueue,
iconId = R.drawable.enqueue_new,
enabled = playlistWithSongs?.songs?.isNotEmpty() == true,
onClick = {
playlistWithSongs?.songs
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ data class ColorPalette(
val background1: Color,
val background2: Color,
val background3: Color,
val background4: Color,
val accent: Color,
val onAccent: Color,
val red: Color = Color(0xffbf4040),
Expand Down Expand Up @@ -60,6 +61,7 @@ val DefaultDarkColorPalette = ColorPalette(
background1 = Color(0xff1f2029),
background2 = Color(0xff2b2d3b),
background3 = Color(0xff495057),
background4 = Color(0xff333333),
text = Color(0xffe1e1e2),
textSecondary = Color(0xffa3a4a6),
textDisabled = Color(0xff6f6f73),
Expand All @@ -74,6 +76,7 @@ val DefaultLightColorPalette = ColorPalette(
background1 = Color(0xfff8f8fc),
background2 = Color(0xffeaeaf5),
background3 = Color(0xffeaeafd),
background4 = Color(0xffeaeafd),
text = Color(0xff212121),
textSecondary = Color(0xff656566),
textDisabled = Color(0xff9d9d9d),
Expand All @@ -87,13 +90,15 @@ val PureBlackColorPalette = DefaultDarkColorPalette.copy(
background0 = Color.Black,
background1 = Color.Black,
background2 = Color.Black,

)

val ModernBlackColorPalette = DefaultDarkColorPalette.copy(
background0 = Color.Black,
background1 = Color.Black,
background2 = Color.Black,
background3 = DefaultDarkColorPalette.accent
background3 = DefaultDarkColorPalette.accent,

)


Expand Down
31 changes: 31 additions & 0 deletions app/src/main/res/drawable-nodpi/enqueue_new.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="512dp"
android:height="512dp"
android:viewportWidth="512"
android:viewportHeight="512">
<path
android:pathData="M62.56,256L449.44,256"
android:strokeLineJoin="round"
android:strokeWidth="48"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:strokeLineCap="round"/>
<path
android:pathData="M63.76,368L448.24,368"
android:strokeLineJoin="round"
android:strokeWidth="48"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:strokeLineCap="round"/>
<path
android:pathData="M154.74,144L442.74,144"
android:strokeLineJoin="round"
android:strokeWidth="48"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:strokeLineCap="round"/>
<path
android:fillColor="#FF000000"
android:pathData="m53.46,187.53a8.18,8.18 0,0 1,-4.05 -1.08c-2.78,-1.57 -4.5,-4.63 -4.5,-7.94v-67.07c0,-3.32 1.73,-6.37 4.5,-7.94a8.12,8.12 0,0 1,8.27 0.1l57.32,34.31a8.33,8.33 0,0 1,0 14.11l-57.33,34.32a8.21,8.21 0,0 1,-4.22 1.18z"
android:strokeWidth="0.23128222"/>
</vector>

0 comments on commit 1bb9e49

Please sign in to comment.