mirror of
https://github.com/Lime3DS/Lime3DS.git
synced 2024-11-23 01:59:22 +01:00
Updated default opacity to 50%
This change accounts for the change in overlay image opacity to roughly equal how the overlay looks in 2108
This commit is contained in:
parent
460c580bdb
commit
d22afdb97f
@ -810,7 +810,7 @@ class EmulationFragment : Fragment(), SurfaceHolder.Callback, Choreographer.Fram
|
||||
|
||||
sliderBinding.apply {
|
||||
slider.valueTo = 100f
|
||||
slider.value = preferences.getInt("controlOpacity", 100).toFloat()
|
||||
slider.value = preferences.getInt("controlOpacity", 50).toFloat()
|
||||
slider.addOnChangeListener(
|
||||
Slider.OnChangeListener { slider: Slider, progress: Float, _: Boolean ->
|
||||
textValue.text = (progress.toInt()).toString()
|
||||
@ -831,7 +831,7 @@ class EmulationFragment : Fragment(), SurfaceHolder.Callback, Choreographer.Fram
|
||||
setControlOpacity(sliderBinding.slider.value.toInt())
|
||||
}
|
||||
.setNeutralButton(R.string.slider_default) { _: DialogInterface?, _: Int ->
|
||||
setControlOpacity(100)
|
||||
setControlOpacity(50)
|
||||
}
|
||||
.show()
|
||||
}
|
||||
@ -863,7 +863,7 @@ class EmulationFragment : Fragment(), SurfaceHolder.Callback, Choreographer.Fram
|
||||
private fun resetInputOverlay() {
|
||||
preferences.edit()
|
||||
.putInt("controlScale", 50)
|
||||
.putInt("controlOpacity", 100)
|
||||
.putInt("controlOpacity", 50)
|
||||
.apply()
|
||||
|
||||
val editor = preferences.edit()
|
||||
|
@ -939,7 +939,7 @@ class InputOverlay(context: Context?, attrs: AttributeSet?) : SurfaceView(contex
|
||||
scale *= (preferences.getInt("controlScale", 50) + 50).toFloat()
|
||||
scale /= 100f
|
||||
|
||||
val opacity: Int = preferences.getInt("controlOpacity", 100) * 255 / 100
|
||||
val opacity: Int = preferences.getInt("controlOpacity", 50) * 255 / 100
|
||||
|
||||
// Initialize the InputOverlayDrawableButton.
|
||||
val defaultStateBitmap = getBitmap(context, defaultResId, scale)
|
||||
@ -997,7 +997,7 @@ class InputOverlay(context: Context?, attrs: AttributeSet?) : SurfaceView(contex
|
||||
scale *= (preferences.getInt("controlScale", 50) + 50).toFloat()
|
||||
scale /= 100f
|
||||
|
||||
val opacity: Int = preferences.getInt("controlOpacity", 100) * 255 / 100
|
||||
val opacity: Int = preferences.getInt("controlOpacity", 50) * 255 / 100
|
||||
|
||||
// Initialize the InputOverlayDrawableDpad.
|
||||
val defaultStateBitmap = getBitmap(context, defaultResId, scale)
|
||||
@ -1057,7 +1057,7 @@ class InputOverlay(context: Context?, attrs: AttributeSet?) : SurfaceView(contex
|
||||
scale *= (preferences.getInt("controlScale", 50) + 50).toFloat()
|
||||
scale /= 100f
|
||||
|
||||
val opacity: Int = preferences.getInt("controlOpacity", 100) * 255 / 100
|
||||
val opacity: Int = preferences.getInt("controlOpacity", 50) * 255 / 100
|
||||
|
||||
// Initialize the InputOverlayDrawableJoystick.
|
||||
val bitmapOuter = getBitmap(context, resOuter, scale)
|
||||
|
Loading…
Reference in New Issue
Block a user