Browse Source

Merge branch 'tsumugi/devel' into tsumugi/master

yattoz 4 years ago
parent
commit
1fddd50b56

+ 2 - 2
app/build.gradle View File

@@ -29,8 +29,8 @@ android {
29 29
         applicationId "fr.forum_thalie.tsumugi"
30 30
         minSdkVersion 16
31 31
         targetSdkVersion 29
32
-        versionCode 111
33
-        versionName "1.1.1"
32
+        versionCode 112
33
+        versionName "1.1.2"
34 34
         testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
35 35
         vectorDrawables.useSupportLibrary = true
36 36
     }

+ 3 - 3
app/src/main/java/fr/forum_thalie/tsumugi/playerstore/PlayerStore.kt View File

@@ -46,8 +46,8 @@ class PlayerStore {
46 46
         isQueueUpdated.value = false
47 47
         isLpUpdated.value = false
48 48
         isMuted.value = false
49
-        currentSong.title.value = noConnectionValue
50
-        currentSongBackup.title.value = noConnectionValue
49
+        currentSong.setTitleArtist(noConnectionValue)
50
+        currentSongBackup.setTitleArtist(noConnectionValue)
51 51
         listenersCount.value = 0
52 52
     }
53 53
 
@@ -181,7 +181,7 @@ class PlayerStore {
181 181
         //if (lp.isNotEmpty()){
182 182
             val n = Song()
183 183
             n.copy(currentSongBackup)
184
-            if (n.title.value != noConnectionValue && n.title.value != streamDownValue)
184
+            if (n != Song(noConnectionValue) && n != Song(streamDownValue))
185 185
                 lp.add(0, n)
186 186
             currentSongBackup.copy(currentSong)
187 187
             isLpUpdated.value = true

+ 2 - 1
app/src/main/java/fr/forum_thalie/tsumugi/playerstore/Song.kt View File

@@ -52,7 +52,8 @@ class Song(artistTitle: String = "", _id : Int = 0) {
52 52
     }
53 53
 
54 54
     fun copy(song: Song) {
55
-        this.setTitleArtist(song.artist.value + " - " + song.title.value)
55
+        this.artist.value = song.artist.value
56
+        this.title. value = song.title.value
56 57
         this.startTime.value = song.startTime.value
57 58
         this.stopTime.value = song.stopTime.value
58 59
         this.type.value = song.type.value

+ 5 - 5
app/src/main/res/layout/fragment_nowplaying.xml View File

@@ -36,7 +36,7 @@
36 36
             android:contentDescription="dj-image"
37 37
             android:scaleType="fitStart"
38 38
             app:layout_constraintEnd_toEndOf="parent"
39
-            app:layout_constraintBottom_toBottomOf="parent"
39
+            app:layout_constraintBottom_toBottomOf="@id/scrollViewMetadataNext"
40 40
             app:layout_constraintStart_toStartOf="@id/imageGuideline"
41 41
             app:layout_constraintTop_toTopOf="parent"
42 42
             app:srcCompat="@drawable/logo_roundsquare"
@@ -160,7 +160,7 @@
160 160
             app:layout_constraintEnd_toStartOf="@id/streamerPicture"
161 161
             app:layout_constraintStart_toStartOf="parent"
162 162
             app:layout_constraintTop_toBottomOf="@id/seek_bar_volume"
163
-            app:layout_constraintVertical_weight="3">
163
+            >
164 164
 
165 165
 
166 166
             <androidx.constraintlayout.widget.ConstraintLayout
@@ -180,7 +180,7 @@
180 180
                     android:text="@string/up_next"
181 181
                     android:textAlignment="center"
182 182
                     android:textColor="@color/whited5"
183
-                    android:layout_marginTop="8dp"
183
+                    android:layout_marginTop="0dp"
184 184
                     app:layout_constraintStart_toStartOf="parent"
185 185
                     app:layout_constraintEnd_toEndOf="parent"
186 186
                     app:layout_constraintTop_toTopOf="parent" />
@@ -218,14 +218,14 @@
218 218
         <ScrollView
219 219
             android:id="@+id/scrollProgramme"
220 220
             android:layout_width="0dp"
221
-            android:layout_height="0dp"
221
+            android:layout_height="wrap_content"
222 222
             android:fillViewport="true"
223 223
             android:layout_marginBottom="0dp"
224 224
             app:layout_constraintEnd_toEndOf="parent"
225 225
             app:layout_constraintStart_toStartOf="parent"
226 226
             app:layout_constraintTop_toBottomOf="@id/scrollViewMetadataNext"
227 227
             app:layout_constraintBottom_toBottomOf="@id/topInfoGuideline"
228
-            app:layout_constraintVertical_weight="1">
228
+            >
229 229
 
230 230
 
231 231
         <androidx.constraintlayout.widget.ConstraintLayout