Fix #660. Update subsampling

This commit is contained in:
len 2017-02-19 23:39:53 +01:00
parent 2230ad59f1
commit 6de260d73f
4 changed files with 222 additions and 207 deletions

View File

@ -98,7 +98,7 @@ android {
dependencies {
// Modified dependencies
compile 'com.github.inorichi:subsampling-scale-image-view:8a22092'
compile 'com.github.inorichi:subsampling-scale-image-view:4255750'
compile 'com.github.inorichi:junrar-android:634c1f5'
// Android support library

View File

@ -96,6 +96,7 @@ class ReaderCustomFilterDialog : DialogFragment() {
// Set brightness value
txt_brightness_seekbar_value.text = brightness.toString()
brightness_seekbar.progress = brightness
// Initialize seekBar progress
seekbar_color_filter_alpha.progress = argb[0]
@ -145,7 +146,7 @@ class ReaderCustomFilterDialog : DialogFragment() {
}
}
})
brightness_seekbar.progress = preferences.customBrightnessValue().getOrDefault()
brightness_seekbar.setOnSeekBarChangeListener(object : SimpleSeekBarListener() {
override fun onProgressChanged(seekBar: SeekBar, value: Int, fromUser: Boolean) {
if (fromUser) {

View File

@ -1,6 +1,7 @@
package eu.kanade.tachiyomi.widget
import android.content.Context
import android.os.Parcelable
import android.util.AttributeSet
import android.widget.SeekBar
import eu.kanade.tachiyomi.R
@ -58,4 +59,11 @@ class NegativeSeekBar @JvmOverloads constructor(context: Context, attrs: Attribu
this.listener = listener
}
override fun onRestoreInstanceState(state: Parcelable?) {
// We can't restore the progress from the saved state because it gets shifted.
val origProgress = progress
super.onRestoreInstanceState(state)
super.setProgress(origProgress)
}
}

View File

@ -28,6 +28,10 @@
android:visibility="gone" />
</RelativeLayout>
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
@ -254,4 +258,6 @@
</RelativeLayout>
</LinearLayout>
</ScrollView>
</LinearLayout>