summaryrefslogtreecommitdiffstats
path: root/api
diff options
context:
space:
mode:
authorDianne Hackborn <hackbod@google.com>2015-02-25 11:08:11 -0800
committerDianne Hackborn <hackbod@google.com>2015-02-25 17:36:17 -0800
commitffeecb1bfb9b71f4b62c9ef1fbf7b58a7a63f655 (patch)
tree79ce65f76cff29d67abc6b867f0f79795be7a38b /api
parent6e53931f49f49245deef8622eb8e7dc6ccf04536 (diff)
downloadframeworks_base-ffeecb1bfb9b71f4b62c9ef1fbf7b58a7a63f655.zip
frameworks_base-ffeecb1bfb9b71f4b62c9ef1fbf7b58a7a63f655.tar.gz
frameworks_base-ffeecb1bfb9b71f4b62c9ef1fbf7b58a7a63f655.tar.bz2
Rework voice interaction session lifecycle.
We now have a formal concept of the session being shown and hidden, with it being able to continue running while hidden as long as there is enough RAM. This changes the flow that a VoiceInteractionSession will see: onCreate() is when it is first created, onCreateContentView() is when its UI first needs to be built, onShow() is called each time it needs to be shown and has the arguments given when the show request was made (which has been renamed from startSession to showSession), and then onHide() will be called when the UI is no longer shown. The methods show() and hide() now allow a VoiceInteractionSession subclass to control when it is shown and hidden, working with the shown state being maintained by the system. Change-Id: Ic4a430ec7e8bf76a5441fd0425e2932806170fcc
Diffstat (limited to 'api')
-rw-r--r--api/current.txt6
-rw-r--r--api/system-current.txt6
2 files changed, 10 insertions, 2 deletions
diff --git a/api/current.txt b/api/current.txt
index de5b1e6..00ee7a8 100644
--- a/api/current.txt
+++ b/api/current.txt
@@ -27656,7 +27656,7 @@ package android.service.voice {
method public android.os.IBinder onBind(android.content.Intent);
method public void onReady();
method public void onShutdown();
- method public void startSession(android.os.Bundle, int);
+ method public void showSession(android.os.Bundle, int);
field public static final java.lang.String SERVICE_INTERFACE = "android.service.voice.VoiceInteractionService";
field public static final java.lang.String SERVICE_META_DATA = "android.voice_interaction";
field public static final int START_WITH_ASSIST = 1; // 0x1
@@ -27668,6 +27668,7 @@ package android.service.voice {
method public void finish();
method public android.view.LayoutInflater getLayoutInflater();
method public android.app.Dialog getWindow();
+ method public void hide();
method public void hideWindow();
method public void onAbortVoice(android.service.voice.VoiceInteractionSession.Caller, android.service.voice.VoiceInteractionSession.Request, java.lang.CharSequence, android.os.Bundle);
method public void onBackPressed();
@@ -27682,14 +27683,17 @@ package android.service.voice {
method public void onDestroy();
method public boolean[] onGetSupportedCommands(android.service.voice.VoiceInteractionSession.Caller, java.lang.String[]);
method public void onHandleAssist(android.os.Bundle);
+ method public void onHide();
method public boolean onKeyDown(int, android.view.KeyEvent);
method public boolean onKeyLongPress(int, android.view.KeyEvent);
method public boolean onKeyMultiple(int, int, android.view.KeyEvent);
method public boolean onKeyUp(int, android.view.KeyEvent);
+ method public void onShow(android.os.Bundle, int);
method public void onTaskFinished(android.content.Intent, int);
method public void onTaskStarted(android.content.Intent, int);
method public void setContentView(android.view.View);
method public void setTheme(int);
+ method public void show();
method public void showWindow();
method public void startVoiceActivity(android.content.Intent);
}
diff --git a/api/system-current.txt b/api/system-current.txt
index 92f0f4d..626dfd0 100644
--- a/api/system-current.txt
+++ b/api/system-current.txt
@@ -29345,7 +29345,7 @@ package android.service.voice {
method public android.os.IBinder onBind(android.content.Intent);
method public void onReady();
method public void onShutdown();
- method public void startSession(android.os.Bundle, int);
+ method public void showSession(android.os.Bundle, int);
field public static final java.lang.String SERVICE_INTERFACE = "android.service.voice.VoiceInteractionService";
field public static final java.lang.String SERVICE_META_DATA = "android.voice_interaction";
field public static final int START_WITH_ASSIST = 1; // 0x1
@@ -29357,6 +29357,7 @@ package android.service.voice {
method public void finish();
method public android.view.LayoutInflater getLayoutInflater();
method public android.app.Dialog getWindow();
+ method public void hide();
method public void hideWindow();
method public void onAbortVoice(android.service.voice.VoiceInteractionSession.Caller, android.service.voice.VoiceInteractionSession.Request, java.lang.CharSequence, android.os.Bundle);
method public void onBackPressed();
@@ -29371,14 +29372,17 @@ package android.service.voice {
method public void onDestroy();
method public boolean[] onGetSupportedCommands(android.service.voice.VoiceInteractionSession.Caller, java.lang.String[]);
method public void onHandleAssist(android.os.Bundle);
+ method public void onHide();
method public boolean onKeyDown(int, android.view.KeyEvent);
method public boolean onKeyLongPress(int, android.view.KeyEvent);
method public boolean onKeyMultiple(int, int, android.view.KeyEvent);
method public boolean onKeyUp(int, android.view.KeyEvent);
+ method public void onShow(android.os.Bundle, int);
method public void onTaskFinished(android.content.Intent, int);
method public void onTaskStarted(android.content.Intent, int);
method public void setContentView(android.view.View);
method public void setTheme(int);
+ method public void show();
method public void showWindow();
method public void startVoiceActivity(android.content.Intent);
}