Last active
March 21, 2022 11:10
-
-
Save laurentyhuel/60b1ba29b49ff29fd0d55abd138e8419 to your computer and use it in GitHub Desktop.
2x screen : show presentation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private var presentation: DefaultPresentation? = null | |
override fun onCreate(savedInstanceState: Bundle?) { | |
super.onCreate(savedInstanceState) | |
[...] | |
getCustomerDisplay(this)?.let { display -> | |
presentation = DefaultPresentation(display, applicationContext) | |
presentation?.setImage(uri) | |
} | |
} | |
override fun onResume() { | |
presentation?.show() | |
super.onResume() | |
} | |
override fun onPause() { | |
presentation?.hide() | |
super.onPause() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment