mirror of
https://github.com/clangen/musikcube.git
synced 2025-01-07 09:54:55 +00:00
Fixed #250
This commit is contained in:
parent
1e655cb97a
commit
07ec3fcce9
@ -572,14 +572,14 @@ class StreamingPlaybackService(context: Context) : IPlaybackService {
|
||||
}
|
||||
|
||||
private fun resolveNextIndex(currentIndex: Int, count: Int, userInitiated: Boolean): Int {
|
||||
if (shuffled) { /* our shuffle matches actually random for now. */
|
||||
if (shuffled) { /* our shuffle is implemented as random for now. */
|
||||
if (count <= 1) {
|
||||
return currentIndex
|
||||
}
|
||||
|
||||
var r = random.nextInt(count - 1)
|
||||
var r = random.nextInt(count)
|
||||
while (r == currentIndex) {
|
||||
r = random.nextInt(count - 1)
|
||||
r = random.nextInt(count)
|
||||
}
|
||||
return r
|
||||
}
|
||||
|
@ -6,7 +6,7 @@ buildscript {
|
||||
jcenter()
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:3.3.1'
|
||||
classpath 'com.android.tools.build:gradle:3.3.2'
|
||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
||||
classpath 'com.google.gms:google-services:4.2.0'
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user