Skip to content

Instantly share code, notes, and snippets.

@meet30997
Created August 23, 2022 12:36
Show Gist options
  • Save meet30997/7b41604dbcb23aba84c7ad52cdaf7897 to your computer and use it in GitHub Desktop.
Save meet30997/7b41604dbcb23aba84c7ad52cdaf7897 to your computer and use it in GitHub Desktop.
Initialize And Use FlightModeManager
// Init flightMode Manager to handle warning dialog
private val flightModeManager by lazy { FlightModeManager(this) }
override fun onResume() {
super.onResume()
// Check flight Mode on OnResume
flightModeManager.checkFlightMode()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment