OSDN Git Service
Replace ad-hoc intent script execution with more formal interface
The current intent script execution mechanism has at least two
serious problems:
* If a Term activity is already running, it will just bring the activity
to the top, without opening a new window or running the provided
script.
* It allows any other application to use our permissions, even if they
don't have those permissions themselves.
Replace the current ad-hoc mechanism with a more formally defined remote
intent interface, which provides two actions:
* jackpal.androidterm.OPEN_NEW_WINDOW opens a new terminal window. No
script execution is allowed, and no permissions are required to use
this action.
* jackpal.androidterm.RUN_SCRIPT opens a new window and runs the script
specified in the jackpal.androidterm.iInitialCommand extra.
Applications using this intent must have the
jackpal.androidterm.permission.RUN_SCRIPT permission, which must be
approved by the user at install time.
Signed-off-by: Jack Palevich <jackpal@google.com>