1
我想从我自己的应用程序中的另一个应用程序启动一个活动。我可以控制这两个应用程序。StartActivityForResult在OverviewScreen上生成一个新项目
对此,我使用明确的意图,它运作良好。
Intent intent = new Intent();
ComponentName componentName = new ComponentName("br.com.example.app","br.com.exemple.app.myactivity");
intent.setComponent(componentName);
当我点击概述按钮会出现我的问题,新的应用程序出现在同一项目时概述屏幕(屏幕近期])内。因此,用户可以确定他是否是App1或App2中的一员。实际上,他会认为他还在App1内。
如何强制它出现在概览屏幕上的不同项目上?
我已经尝试过使用
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_DOCUMENT);
和
<activity
android:name=".myactivity"
android:exported="true"
android:screenOrientation="portrait"
android:theme="@style/ApiBaseThemeNoActionBar"
android:documentLaunchMode="always">
</activity>
它似乎运作良好仅使用startActivity(意向)时。