Added version check for app shortcuts

As mentioned by @arkon 2e1a453e8d (commitcomment-21247880)
This commit is contained in:
Adrian Campos 2017-03-09 21:54:06 -08:00 committed by Karim Abou Zeid
commit b14ba65a5b
2 changed files with 6 additions and 3 deletions

View file

@ -114,8 +114,10 @@ public class MainActivity extends AbsSlidingMusicPanelActivity {
checkShowChangelog();
}
//Set up dynamic shortcuts if needed
new DynamicShortcutManager(getApplicationContext()).initDynamicShortcuts();
//Set up dynamic shortcuts
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N_MR1) {
new DynamicShortcutManager(getApplicationContext()).initDynamicShortcuts();
}
}
private void setMusicChooser(int key) {