서비스에서 알림창을 먼전 띄우고 매로리 해제된 activity를 띄움
Context context = getApplicationContext();
Intent intent = new Intent(context, MnActy.class);
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
context.startActivity(intent);
Bundle bundle = new Bundle();
bundle.putString("BeReady", "You are almost next one!");
Intent popupIntent = new Intent(getApplicationContext(), AlertDialogActivity.class);
popupIntent.putExtras(bundle);
PendingIntent pendingIntent= PendingIntent.getActivity(getApplicationContext(), 0, popupIntent, PendingIntent.FLAG_ONE_SHOT);
try {
pendingIntent.send();
} catch (CanceledException e) {
e.printStackTrace();
}
'Android 안드로이드' 카테고리의 다른 글
카메라 플레시 (0) | 2015.02.20 |
---|---|
SurfaceView 원이 이동, 화면 전환시 위치 저장 (0) | 2015.02.18 |
MySurfaceVwActy (0) | 2014.12.28 |
코드 역난독화 deobfuscation disassemble (0) | 2014.12.28 |
Failed to create the Java Virtual Machine. (0) | 2014.12.17 |