开发者

ANDROID :How to start an existing activity as new activity from stack

开发者 https://www.devze.com 2023-02-20 06:23 出处:网络
I am using ActivityGroup in my application. I am starting each activity by : Window objWindow= getLocalActivityManager().startActivity(argActivityId,argIntent);

I am using ActivityGroup in my application. I am starting each activity by :

     Window objWindow   = getLocalActivityManager().startActivity(argActivityId,argIntent); 
     View objView   = objWindow.getDecorView();
     setContentView(objView);   

But when I am trying to start an activity, that is already started by another activity, it will not start as a new activity, in开发者_Python百科stead the old activity object is retained.

How can I start this as a new activity?

Thanking you...


Set the FLAG_ACTIVITY_CLEAR_TOP intent flag of argIntent before calling startActivity.

0

精彩评论

暂无评论...
验证码 换一张
取 消