From 401a3cf1d5e33c26aeba672df342c35ccdb04e3d Mon Sep 17 00:00:00 2001 From: Wink Saville Date: Mon, 11 Jun 2012 20:14:57 -0700 Subject: Use telephony-common Change-Id: I5fa0c8f97d0302bfbf1ea73217ad4cfcb0098193 --- Android.mk | 1 + 1 file changed, 1 insertion(+) diff --git a/Android.mk b/Android.mk index 24a5bca..79a84e3 100644 --- a/Android.mk +++ b/Android.mk @@ -5,6 +5,7 @@ include $(CLEAR_VARS) LOCAL_MODULE_TAGS := optional +LOCAL_JAVA_LIBRARIES := telephony-common LOCAL_SRC_FILES := $(call all-subdir-java-files) LOCAL_PACKAGE_NAME := Stk -- cgit v1.1 From 71013cbdc4a9b1b0eaa0d21af1641f90e4e47f42 Mon Sep 17 00:00:00 2001 From: Wink Saville Date: Mon, 11 Jun 2012 20:14:57 -0700 Subject: Use telephony-common - DO NOT MERGE Change-Id: I5fa0c8f97d0302bfbf1ea73217ad4cfcb0098193 --- Android.mk | 1 + 1 file changed, 1 insertion(+) diff --git a/Android.mk b/Android.mk index 24a5bca..79a84e3 100644 --- a/Android.mk +++ b/Android.mk @@ -5,6 +5,7 @@ include $(CLEAR_VARS) LOCAL_MODULE_TAGS := optional +LOCAL_JAVA_LIBRARIES := telephony-common LOCAL_SRC_FILES := $(call all-subdir-java-files) LOCAL_PACKAGE_NAME := Stk -- cgit v1.1 From b548bdcc34592bba628cf99c89bd156b9b9509f6 Mon Sep 17 00:00:00 2001 From: Ying Wang Date: Fri, 20 Jul 2012 11:13:40 -0700 Subject: Import translations. DO NOT MERGE Change-Id: I449238b1b4dab9680658ce0aecfa53915d10e19f Auto-generated-cl: translation import --- res/values-fa/strings.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/res/values-fa/strings.xml b/res/values-fa/strings.xml index 9850cbb..bef8ddd 100644 --- a/res/values-fa/strings.xml +++ b/res/values-fa/strings.xml @@ -29,7 +29,7 @@ "الفبا" "ارقام (0-9، *، #، +)" "تماس در حال انجام..." - "حالت برنامه کاربردی" + "حالت برنامهٔ کاربردی" "فعال شد" "غیرفعال شد" "کیت ابزار سیم کارت" -- cgit v1.1 From d8e2ecdca2d1bc91f48cea59e96aa5b0b452e8a7 Mon Sep 17 00:00:00 2001 From: Alex Yakavenka Date: Fri, 20 Apr 2012 17:10:15 -0700 Subject: Stk: Fix crash due to race condition StkAppService doesn't really need mStkService reference in the constructor. It will need it to respond to proactive command. By that time StkService has to exist (proactive command comes from it) --- src/com/android/stk/StkAppService.java | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/com/android/stk/StkAppService.java b/src/com/android/stk/StkAppService.java index 1007a4a..9dcd25b 100644 --- a/src/com/android/stk/StkAppService.java +++ b/src/com/android/stk/StkAppService.java @@ -144,20 +144,11 @@ public class StkAppService extends Service implements Runnable { @Override public void onCreate() { // Initialize members + // This can return null if StkService is not yet instantiated, but it's ok + // If this is null we will do getInstance before we need to use this mStkService = com.android.internal.telephony.cat.CatService .getInstance(); - // NOTE mStkService is a singleton and continues to exist even if the GSMPhone is disposed - // after the radio technology change from GSM to CDMA so the PHONE_TYPE_CDMA check is - // needed. In case of switching back from CDMA to GSM the GSMPhone constructor updates - // the instance. (TODO: test). - if ((mStkService == null) - && (TelephonyManager.getDefault().getPhoneType() - != TelephonyManager.PHONE_TYPE_CDMA)) { - CatLog.d(this, " Unable to get Service handle"); - return; - } - mCmdsQ = new LinkedList(); Thread serviceThread = new Thread(null, this, "Stk App Service"); serviceThread.start(); @@ -488,6 +479,15 @@ public class StkAppService extends Service implements Runnable { if (mCurrentCmd == null) { return; } + if (mStkService == null) { + mStkService = com.android.internal.telephony.cat.CatService.getInstance(); + if (mStkService == null) { + // This should never happen (we should be responding only to a message + // that arrived from StkService). It has to exist by this time + throw new RuntimeException("mStkService is null when we need to send response"); + } + } + CatResponseMessage resMsg = new CatResponseMessage(mCurrentCmd); // set result code -- cgit v1.1 From 99fccc1c113d9b7a030dc7c945d0750748cc4af9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre=20Fr=C3=B6jd?= Date: Wed, 19 Jan 2011 13:46:57 +0100 Subject: No response sent when backlight is OFF When the LCD backlight is OFF while receiving a PLAY TONE command, the onDestroy() method is called immediately since the app is in the background. In onDestroy() the STOP message is removed from the handler queue which leads to no response is sent back to StkAppService. This causes the RIL layer to send TR 'ME currently unable to process command' back to the SIM. Solution is to check if a response is sent before removing any messages from the handler queue. Change-Id: I7ac2e99b85b38576acfe72370aa55850cdc304a0 --- src/com/android/stk/ToneDialog.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/com/android/stk/ToneDialog.java b/src/com/android/stk/ToneDialog.java index 3251aba..0370939 100644 --- a/src/com/android/stk/ToneDialog.java +++ b/src/com/android/stk/ToneDialog.java @@ -38,6 +38,7 @@ public class ToneDialog extends Activity { TextMessage toneMsg = null; ToneSettings settings = null; TonePlayer player = null; + boolean mIsResponseSent = false; /** * Handler used to stop tones from playing when the duration ends. @@ -98,8 +99,9 @@ public class ToneDialog extends Activity { @Override protected void onDestroy() { super.onDestroy(); - - mToneStopper.removeMessages(MSG_ID_STOP_TONE); + if (mIsResponseSent) { + mToneStopper.removeMessages(MSG_ID_STOP_TONE); + } player.stop(); player.release(); mVibrator.cancel(); @@ -129,5 +131,6 @@ public class ToneDialog extends Activity { args.putInt(StkAppService.OPCODE, StkAppService.OP_RESPONSE); args.putInt(StkAppService.RES_ID, resId); startService(new Intent(this, StkAppService.class).putExtras(args)); + mIsResponseSent = true; } } -- cgit v1.1 From a8e4f50aead658df817e0c0434fc5fb261701208 Mon Sep 17 00:00:00 2001 From: Wink Saville Date: Wed, 26 Sep 2012 16:43:29 -0700 Subject: Fix mVibrator initialization. getSystemService cannot be called during java#init, moving initialization of mVibrator into onCreate. Bug: 6886400 Change-Id: I644aa674fffb11ea755bd6d96169e43896c839f2 --- src/com/android/stk/ToneDialog.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/com/android/stk/ToneDialog.java b/src/com/android/stk/ToneDialog.java index 0370939..0ad6ee8 100644 --- a/src/com/android/stk/ToneDialog.java +++ b/src/com/android/stk/ToneDialog.java @@ -55,7 +55,7 @@ public class ToneDialog extends Activity { } }; - Vibrator mVibrator = (Vibrator)getSystemService(VIBRATOR_SERVICE); + Vibrator mVibrator; // Message id to signal tone duration timeout. private static final int MSG_ID_STOP_TONE = 0xda; @@ -64,7 +64,9 @@ public class ToneDialog extends Activity { protected void onCreate(Bundle icicle) { super.onCreate(icicle); - initFromIntent(getIntent()); + mVibrator = (Vibrator)getSystemService(VIBRATOR_SERVICE); + + initFromIntent(getIntent()); // remove window title View title = findViewById(com.android.internal.R.id.title); -- cgit v1.1 From ac72bff9a1fdb69260e53b277547bf4e32e8e43f Mon Sep 17 00:00:00 2001 From: Dianne Hackborn Date: Fri, 28 Sep 2012 15:42:06 -0700 Subject: More issue #7226656 second user seeing primary user's apps Don't launch this when a user is starting. Change-Id: Ic264a8e1060407d500138d7d182414988aa03938 --- AndroidManifest.xml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/AndroidManifest.xml b/AndroidManifest.xml index a54826e..994abdb 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -16,6 +16,7 @@ @@ -80,7 +81,8 @@ - + -- cgit v1.1