mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-25 23:10:47 -08:00
Implement `restart-emacs' on Android
* java/org/gnu/emacs/EmacsService.java (restartEmacs): New function. * src/android.c (struct android_emacs_service) (android_init_emacs_service): Add new method. (android_restart_emacs): New function. * src/android.h: Update prototypes. * src/emacs.c (Fkill_emacs): Call android_restart_emacs whenever appropriate.
This commit is contained in:
parent
22749d69e5
commit
f9e32ce157
4 changed files with 47 additions and 1 deletions
|
|
@ -611,4 +611,16 @@ public class EmacsService extends Service
|
|||
|
||||
return manager.thing;
|
||||
}
|
||||
|
||||
public void
|
||||
restartEmacs ()
|
||||
{
|
||||
Intent intent;
|
||||
|
||||
intent = new Intent (this, EmacsActivity.class);
|
||||
intent.addFlags (Intent.FLAG_ACTIVITY_NEW_TASK
|
||||
| Intent.FLAG_ACTIVITY_CLEAR_TASK);
|
||||
startActivity (intent);
|
||||
System.exit (0);
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue