Преглед изворни кода

fix black screen after change screen orientation

but need to fix preview stretching after change screen orientation
flutter-beta
Leon пре 7 година
committed by GitHub
родитељ
комит
66e811b04e
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 измењених фајлова са 4 додато и 3 уклоњено
  1. +4
    -3
      android/src/main/kotlin/net/touchcapture/qr/flutterqr/QRView.kt

+ 4
- 3
android/src/main/kotlin/net/touchcapture/qr/flutterqr/QRView.kt Прегледај датотеку

@@ -43,8 +43,6 @@ class QRView(context: Context, private val registrar: PluginRegistry.Registrar,
}
)

init()

activity.application.registerActivityLifecycleCallbacks(
object : Application.ActivityLifecycleCallbacks{
override fun onActivityPaused(p0: Activity?) {
@@ -84,7 +82,10 @@ class QRView(context: Context, private val registrar: PluginRegistry.Registrar,
}

override fun getView(): View {
return barcodeView
barcodeView.pause()
return barcodeView.apply {
init()
}
}

override fun dispose() {


Loading…
Откажи
Сачувај