本文整理了Java中android.content.Context.startActivities()
方法的一些代码示例,展示了Context.startActivities()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Context.startActivities()
方法的具体详情如下:
包路径:android.content.Context
类名称:Context
方法名:startActivities
暂无
代码示例来源:origin: oasisfeng/condom
@RequiresApi(HONEYCOMB) @Override public void startActivities(Intent[] intents) {
mBase.startActivities(intents);
}
代码示例来源:origin: oasisfeng/condom
@RequiresApi(JELLY_BEAN) @Override public void startActivities(Intent[] intents, Bundle options) {
mBase.startActivities(intents, options);
}
代码示例来源:origin: Trumeet/MiPushFramework
@RequiresApi(JELLY_BEAN) @Override public void startActivities(Intent[] intents, Bundle options) {
mBase.startActivities(intents, options);
}
代码示例来源:origin: Trumeet/MiPushFramework
@RequiresApi(HONEYCOMB) @Override public void startActivities(Intent[] intents) {
mBase.startActivities(intents);
}
代码示例来源:origin: kingargyle/adt-leanback-support
static void startActivities(Context context, Intent[] intents) {
context.startActivities(intents);
}
代码示例来源:origin: kingargyle/adt-leanback-support
public static void startActivities(Context context, Intent[] intents, Bundle options) {
context.startActivities(intents, options);
}
代码示例来源:origin: yangchong211/YCAudioPlayer
private void reStartActivity(Intent intent, Context context) {
Intent[] intents = new Intent[2];
Intent mainIntent = new Intent(context, MainActivity.class);
mainIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
intents[0] = mainIntent;
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
intents[1] = intent;
context.startActivities(intents);
}
代码示例来源:origin: yangchong211/YCAudioPlayer
private void reStartActivity(Intent intent, Context context) {
Intent[] intents = new Intent[2];
Intent mainIntent = new Intent(context, MainActivity.class);
mainIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
intents[0] = mainIntent;
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
intents[1] = intent;
context.startActivities(intents);
}
代码示例来源:origin: ManbangGroup/Phantom
@RequiresApi(api = Build.VERSION_CODES.JELLY_BEAN)
void startActivities(Intent[] intents, @Nullable Bundle options) {
mContext.startActivities(setIntentExtra(intents), options);
}
代码示例来源:origin: ManbangGroup/Phantom
void startActivities(Intent...intents) {
mContext.startActivities(setIntentExtra(intents));
}
代码示例来源:origin: fanatic-mobile-developer-for-android/A-week-to-develop-android-app-plan
@Override
public void onReceive(Context context, Intent intent) {
// 判断app进程是否存活
if (SystemUtils.isAppAlive(context, "net.coollet.infzmreader")) {
Log.i("NotificationReceiver", "the app process is alive");
Intent mainIntent = new Intent(context, MainActivity.class);
mainIntent.putExtra("ID", intent.getIntExtra("ID", 0));
mainIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
Intent detailIntent = new Intent(context,
MainActivity.class);
detailIntent.putExtra("ID", intent.getIntExtra("ID", 0));
Intent[] intents = { mainIntent, detailIntent };
context.startActivities(intents);
} else {
Log.i("NotificationReceiver", "the app process is dead");
Intent launchIntent = context.getPackageManager()
.getLaunchIntentForPackage("net.coollet.infzmreader");
launchIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK
| Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED);
launchIntent.putExtra("ID", intent.getIntExtra("ID", 0));
context.startActivity(launchIntent);
}
}
}
内容来源于网络,如有侵权,请联系作者删除!