外部程序启动App
第一种:直接通过包名:
Intent LaunchIntent = getPackageManager().getLaunchIntentForPackage("com.joyodream.jiji");
startActivity(LaunchIntent);
第二种:通过自定义的Action
Intent intent = new Intent();
intent.setAction("com.joyodream.jiji.main");
MainActivity.this.startActivity(intent); <intent-filter>
<action android:name="com.joyodream.jiji.main" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
第三种:通过Scheme
Intent intent = new Intent();
intent.setData(Uri.parse("joyodream://......"));
startActivity(intent); <intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<data android:scheme="joyodream" android:ssp="jiji" />
</intent-filter>
外部程序启动App的更多相关文章
- [Android]从Launcher开始启动App流程源码分析
以下内容为原创,欢迎转载,转载请注明 来自天天博客:http://www.cnblogs.com/tiantianbyconan/p/5017056.html 从Launcher开始启动App流程源码 ...
- ActivityManagerService是如何启动app
ActivityManagerService是如何启动app 一. 上一篇文章app的启动过程,说明了launcher启动app是通过binber,让ActivityManagerServi ...
- Appium学习路—脚本篇(启动app)
启动之前的准备 1.脚本执行前,需要先启动appium的server端, 启动server方法: 打开appium客户端,点击右上角的Launch 2.iOS的测试只能在mac本上做 ...
- Android Launcher分析和修改9——Launcher启动APP流程
本来想分析AppsCustomizePagedView类,不过今天突然接到一个临时任务.客户反馈说机器界面的图标很难点击启动程序,经常点击了没有反应,Boss说要优先解决这问题.没办法,只能看看是怎么 ...
- Android 启动APP黑屏解决方案
#Android 启动APP黑屏解决方案# 1.自定义Theme //1.设置背景图Theme <style name="Theme.AppStartLoad" parent ...
- Android在浏览器启动APP
要想在浏览器启动APP的方法例如以下: 在须要跳转的ACTIVITY中加入intent-filter的相关信息: <intent-filter> <data android: ...
- ele.me在IOS浏览器端启动APP的技巧分析
ele.me在IOS浏览器端启动APP的技巧分析 巧妙利用后台重定向,在schemes启动时提示用户打开,启动不了APP时能够及时跳转至下载页面. 避免报错页面的出现以及用户还没来的及选择就跳转到下载 ...
- appium+Python 启动app(二)
我们上步操作基本完成,下面介绍编写Python脚本启动app 打开我们pycharm新建.py文件 第一步:输入Python脚本代码: #coding=utf-8 from appium import ...
- appium+Python 启动app(一)
当我们appium和Python环境都配置好了,如何启动我们第一个app呢?下面介绍appium+Python启动app的操作步骤,为了能够详细查看,我们这里使用夜游神模拟器进行示范. 测试项目:QQ ...
随机推荐
- 转 PHP5+APACHE2.2配置
初学php,配置起来老出问题,找了篇不错的帖子,一试就通过了,所以就顺带着转了过来. 不过在我安装phpMyAdmin的时候还是发现这篇文章的一个问题,就是php.ini如果放在system32下,启 ...
- [转载]Error starting Sun's native2ascii:
原文地址:Error starting Sun's native2ascii:作者:大一吧浪 Error starting Sun's native2ascii: at org.apache.tool ...
- 导致线程死锁容易忽略的一点 SendMessage
假如主线程 某一个按钮 点击的 响应要操作与另一个线程共享的 变量. 在这个点击响应里先lock 之后,假如另一个线程的变量正在 “使用”状态,并且内部又调用了SendMessage试图更新界面的某些 ...
- JavaScript indexOf() 方法详解
定义和用法 indexOf() 方法可返回某个指定的字符串值在字符串中首次出现的位置. 语法 stringObject.indexOf(searchvalue,fromindex) 参数 描述 sea ...
- 【LeetCode】213. House Robber II
House Robber II Note: This is an extension of House Robber. After robbing those houses on that stree ...
- 【DeepLearning】Exercise:Sparse Autoencoder
Exercise:Sparse Autoencoder 习题的链接:Exercise:Sparse Autoencoder 注意点: 1.训练样本像素值需要归一化. 因为输出层的激活函数是logist ...
- 安装 Linuxbrew
在 OS X 平台上非常流行的包管理器 Homebrew 最近正被移植到 Linux 上而成为 Linuxbrew.虽然各种 Linux 发行都带有自己的包管理工具,诸如 apt-get.yum.pa ...
- TCP详解 (1)
网络层: IP 被称为洲际协议,ICMP称为互联网控制报文协议 IGMP 为互联网组管理协议 传输层: 传输层的作用是把应用程序给他的任务划分为数据包,然后传递给下面的层: 应用层: 应用层的协 ...
- struts2 标签变形和 样式class无效 问题解决方法
在jsp使用Struts2标签的时候会发现,出现严重变形问题. <s:textfield type="text" name="username" labe ...
- 《JAVA与模式》之单例模式(转载)
原文地址:http://blog.csdn.net/jason0539/article/details/23297037 概念: java中单例模式是一种常见的设计模式,单例模式分三种:懒汉式单例.饿 ...