summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAmit Mahajan <amitmahajan@google.com>2019-12-03 00:57:16 -0800
committerAmit Mahajan <amitmahajan@google.com>2019-12-05 23:33:59 -0800
commitf17bb5778ab1678601cfb171eec7213de63bbefc (patch)
tree8b4939612ad7f63f7cf0dc33608b526b8d884e87 /src
parent64a7605c0d8baf2e2ee83c85c6935080fc2bc6cd (diff)
downloadStk-f17bb5778ab1678601cfb171eec7213de63bbefc.tar.gz
Split Stk into a client apk and a lib.
The client apk has the manifest and the lib has the code and resources. This is being done so that the apk can run under the phone shareduid, while the lib can be part of telephony mainline module and be updatable. Test: basic stk sanity Bug: 144806641 Merged-in: I0275115747f51bb6d97f1cbe1501aefc3caf0ca7 Change-Id: I0275115747f51bb6d97f1cbe1501aefc3caf0ca7 (cherry picked from commit 7e1566067f791a8145d36e397cdd6b842cc89240)
Diffstat (limited to 'src')
-rw-r--r--src/com/android/stk/StkInputActivity.java18
1 files changed, 6 insertions, 12 deletions
diff --git a/src/com/android/stk/StkInputActivity.java b/src/com/android/stk/StkInputActivity.java
index 0af6767..fe16101 100644
--- a/src/com/android/stk/StkInputActivity.java
+++ b/src/com/android/stk/StkInputActivity.java
@@ -105,22 +105,18 @@ public class StkInputActivity extends AppCompatActivity implements View.OnClickL
return;
}
- switch (v.getId()) {
- case R.id.button_ok:
+ if (v.getId() == R.id.button_ok) {
input = mTextIn.getText().toString();
- break;
- case R.id.button_cancel:
+ } else if (v.getId() == R.id.button_cancel) {
sendResponse(StkAppService.RES_ID_END_SESSION);
finish();
return;
- // Yes/No layout buttons.
- case R.id.button_yes:
+ // Yes/No layout buttons.
+ } else if (v.getId() == R.id.button_yes) {
input = YES_STR_RESPONSE;
- break;
- case R.id.button_no:
+ } else if (v.getId() == R.id.button_no) {
input = NO_STR_RESPONSE;
- break;
- case R.id.more:
+ } else if (v.getId() == R.id.more) {
if (mPopupMenu == null) {
mPopupMenu = new PopupMenu(this, v);
Menu menu = mPopupMenu.getMenu();
@@ -140,8 +136,6 @@ public class StkInputActivity extends AppCompatActivity implements View.OnClickL
mPopupMenu.show();
}
return;
- default:
- break;
}
CatLog.d(LOG_TAG, "handleClick, ready to response");
sendResponse(StkAppService.RES_ID_INPUT, input, false);