Last active
August 2, 2019 14:33
-
-
Save SanojPunchihewa/73642e402280e3f5a444a73ae9b41739 to your computer and use it in GitHub Desktop.
Initialize the UpdateManager in Activity
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
// Declare the UpdateManager | |
UpdateManager mUpdateManager; | |
@Override | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
setContentView(R.layout.activity_main); | |
// Initialize the Update Manager with the Activity and the Update Mode | |
mUpdateManager = UpdateManager.Builder(this).mode(UpdateManagerConstant.FLEXIBLE); | |
// Call start() to check for updates and install them | |
mUpdateManager.start(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment