解决Android程序退出后不显示在近期任务里
来源:互联网 发布:阿里云华北2速度 编辑:程序博客网 时间:2024/06/05 17:08
solution:
在AndroidManifest.xml中对应的Activity中找到“android:excludeFromRecents”,把值改为false,或直接去掉该项。
e.g.
AndroidManifest.xml
Develop Reference
Whether or not the task initiated by this activity should be excluded from the list of recently used applications ("recent apps"). That is, when this activity is the root activity of a new task, this attribute determines whether the task should not appear in the list of recent apps. "
在AndroidManifest.xml中对应的Activity中找到“android:excludeFromRecents”,把值改为false,或直接去掉该项。
e.g.
AndroidManifest.xml
<activity android:icon="@drawable/ic_launcher_fmradio"
android:name=".FMRadio"
android:label="@string/app_name"
android:taskAffinity=""
android:launchMode="singleTop"
android:screenOrientation="portrait">
<!-- android:excludeFromRecents="true"-->
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<intent-filter>
<action android:name="com.quicinc.fmradio.FMRADIO_ACTIVITY" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
Develop Reference
android:excludeFromRecents
true
" if the task should beexcluded from the list; "false
" if it should be included. The default value is "false
".============================
相反,如果要不出现在近期任务里面,可以增加android:excludeFromRecents="true",但貌似要apk中所有activity都加上才有用。
- 解决Android程序退出后不显示在近期任务里
- 解决Android程序退出后不显示在近期任务里
- 解决Android程序运行且退出后却不会显示在近期任务里的问题
- Android程序运行且退出后却不会显示在近期任务里
- 做WinForm程序,在通知区域加入NotifyIcon,程序退出后不消失的解决
- Android程序退出后音乐不停止
- android应用退出后在任务管理器隐藏
- Android 录像保存后在文件管理或相册里不显示问题
- android返回键后程序不退出moveTaskToBack
- Android:退出程序后保持Serivce开启不关闭
- android程序安装后图标不显示
- android程序安装后图标不显示
- android程序安装后图标不显示
- android程序安装后图标不显示
- android程序安装后图标不显示
- android程序安装后图标不显示
- android程序安装后图标不显示
- Android程序安装后图标不显示
- 多进程和多线程的区别
- MVC4 成员资格、 身份验证
- Java注释Override、Deprecated、SuppressWarnings详解
- JAVA笔记:集合系列02—ArrayList
- 原码、反码、补码和移码其实很简单
- 解决Android程序退出后不显示在近期任务里
- 创建网站与数据库步骤
- 如何用css设置两个背景
- malloc/free和new/delete 区别
- 高并发网站更新数据库数据比较高效的方式
- SharePoint excel service web part 连接到 filter web part
- 打开汇编之门
- linux下c/c++编译器和调试器以及静态库、动态库使用汇总
- js中的referrer使用,返回上一页