clean-arc
This commit is contained in:
parent
1d423fc7bd
commit
5ee566c09a
62 changed files with 477 additions and 937 deletions
|
@ -18,10 +18,8 @@ import android.content.Context
|
|||
import android.provider.MediaStore.Audio.AudioColumns
|
||||
import code.name.monkey.retromusic.model.Album
|
||||
import code.name.monkey.retromusic.model.Artist
|
||||
import code.name.monkey.retromusic.model.Song
|
||||
import code.name.monkey.retromusic.util.PreferenceUtil
|
||||
import io.reactivex.Observable
|
||||
import java.util.*
|
||||
import kotlin.collections.ArrayList
|
||||
|
||||
object ArtistLoader {
|
||||
|
|
|
@ -17,15 +17,13 @@ package code.name.monkey.retromusic.loaders
|
|||
import android.content.Context
|
||||
import android.database.Cursor
|
||||
import android.provider.MediaStore
|
||||
|
||||
import java.util.ArrayList
|
||||
|
||||
import code.name.monkey.retromusic.model.Album
|
||||
import code.name.monkey.retromusic.model.Artist
|
||||
import code.name.monkey.retromusic.model.Song
|
||||
import code.name.monkey.retromusic.util.PreferenceUtil
|
||||
import io.reactivex.Observable
|
||||
import io.reactivex.annotations.NonNull
|
||||
import java.util.*
|
||||
|
||||
/**
|
||||
* Created by hemanths on 16/08/17.
|
||||
|
|
|
@ -64,7 +64,7 @@ object PlaylistSongsLoader {
|
|||
val year = cursor.getInt(3)
|
||||
val duration = cursor.getLong(4)
|
||||
val data = cursor.getString(5)
|
||||
val dateModified = cursor.getInt(6)
|
||||
val dateModified = cursor.getLong(6)
|
||||
val albumId = cursor.getInt(7)
|
||||
val albumName = cursor.getString(8)
|
||||
val artistId = cursor.getInt(9)
|
||||
|
|
|
@ -134,7 +134,7 @@ object SongLoader {
|
|||
val song: Song = if (cursor != null && cursor.moveToFirst()) {
|
||||
getSongFromCursorImpl(cursor)
|
||||
} else {
|
||||
Song.EMPTY_SONG
|
||||
Song.emptySong
|
||||
}
|
||||
cursor?.close()
|
||||
e.onNext(song)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue