Fixed Samsung multiwindow mode, apps can be started at any order now

This commit is contained in:
pelya
2015-01-01 22:53:14 +02:00
parent f482591bea
commit 8834abfcd3
6 changed files with 166 additions and 7 deletions

View File

@@ -498,9 +498,9 @@ class Settings
} catch( FileNotFoundException e ) {
} catch ( IOException e ) { }
new File( p.getFilesDir() + "/" + SettingsFileName ).delete();
PendingIntent intent = PendingIntent.getActivity(p, 0, new Intent(p.getIntent()), p.getIntent().getFlags());
AlarmManager mgr = (AlarmManager) p.getSystemService(Context.ALARM_SERVICE);
mgr.set(AlarmManager.RTC, System.currentTimeMillis() + 1000, intent);
Intent intent = new Intent(context, RestartMainActivity.class);
context.startActivity(intent);
System.exit(0);
}