Skip to content

Commit ea50748

Browse files
Wei HuangAndroid (Google) Code Review
authored andcommitted
Merge "Change slide-to-camera intent to INTENT_ACTION_STILL_IMAGE_CAMERA." into ics-mr1
2 parents 48542eb + b757835 commit ea50748

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

policy/src/com/android/internal/policy/impl/LockScreen.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
import android.widget.*;
3535
import android.util.Log;
3636
import android.media.AudioManager;
37+
import android.provider.MediaStore;
3738
import android.provider.Settings;
3839

3940
import java.io.File;
@@ -225,9 +226,10 @@ public void onTrigger(View v, int target) {
225226
mCallback.goToUnlockScreen();
226227
} else if (target == 2 || target == 3) { // 2 = alt/portrait, 3 = alt/landscape
227228
if (!mCameraDisabled) {
228-
// Broadcast an intent to start the Camera
229-
Intent intent = new Intent(Intent.ACTION_CAMERA_BUTTON, null);
230-
mContext.sendOrderedBroadcast(intent, null);
229+
// Start the Camera
230+
Intent intent = new Intent(MediaStore.INTENT_ACTION_STILL_IMAGE_CAMERA);
231+
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
232+
mContext.startActivity(intent);
231233
mCallback.goToUnlockScreen();
232234
} else {
233235
toggleRingMode();

0 commit comments

Comments
 (0)