Warning fixed and upgraded app version

This commit is contained in:
Ivan Agosto 2019-10-24 14:34:14 -05:00
parent 904319674d
commit 390b1a7add
4 changed files with 6 additions and 7 deletions

View File

@ -11,8 +11,8 @@ android {
minSdkVersion 21
//noinspection OldTargetApi
targetSdkVersion 27
versionCode 5
versionName "0.4"
versionCode 6
versionName "0.5"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {

View File

@ -12,7 +12,6 @@ object ManagerSingleton {
var videos_count: Int = 0
fun Toast(text: String?, context: Context) {
if(context == null) { return }
android.widget.Toast.makeText(context, text, android.widget.Toast.LENGTH_SHORT).show()
}

View File

@ -285,12 +285,12 @@ class ReproductorActivity : AppCompatActivity() {
// Pass null as the parent view because its going in the dialog layout
builder.setView(dialog)
// Add action buttons
.setPositiveButton(R.string.reportBtn) { dialog, id ->
.setPositiveButton(R.string.reportBtn) { _, _ ->
val reason = inputReason.text.toString()
reportVideo(reason)
}
.setNegativeButton("Cancel") { dialog, id ->
dialog.cancel()
.setNegativeButton("Cancel") { dialog, _ ->
dialog.run { cancel() }
}
val alertDialog = builder.create()
alertDialog.show()

View File

@ -178,7 +178,7 @@ class Videos: Client() {
fun channelVideos(account: String, start: Int): ArrayList<VideoModel> {
val count = ManagerSingleton.videos_count
val params = "start=$start&count=$count"
val con = this._newCon("video-channels/$account/videos","GET")
val con = this._newCon("video-channels/$account/videos?$params","GET")
var videos = arrayListOf<VideoModel>()
try {
if (con.responseCode == 200) {