launcher

Android-Launcher开发之ShortCut(1)

时光怂恿深爱的人放手 提交于 2020-01-09 08:42:40
下面源代码来自Launcher2.3的样例 1.默认每一个应用的主Activity都会自带 <category android:name="android.intent.category.LAUNCHER" />,表示该应用安装到Launcher时点击打开该Activity <activity android:name="org.lean.MainActivity" android:label="@string/app_name" > <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> <category android:name="android.intent.category.DEFAULT" /> </intent-filter> </activity> 2.Launcher2源代码的时序图例如以下:(在图中,我们能够看到 创建shortcut须要准备2方面东西,一个action.,还有一个是我们检索后返回的intent) 2.1.当想在桌面手动创建shortcut,就必须在AndroidManifest.xml文件里加入一个<action />标签. 例如以下

Unable to execute dex: GC overhead limit exceeded

寵の児 提交于 2020-01-09 08:36:10
Android打包时下面的错误: Unable to execute dex: GC overhead limit exceeded GC overhead limit exceeded 解决的方法: 1、关闭Eclipse 打开D:\eclipse\eclipse.ini -startup plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar --launcher.library plugins/org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.200.v20120913-144807 -product org.eclipse.epp.package.jee.product --launcher.defaultAction openFile --launcher.XXMaxPermSize 512M -showsplash org.eclipse.platform --launcher.XXMaxPermSize 512m --launcher.defaultAction openFile -vmargs -Dosgi.requiredJavaVersion=1.5 -Dhelp.lucene.tokenizer=standard -Xms40m

android开发launcher

你离开我真会死。 提交于 2020-01-09 04:13:48
1. launcher是桌面应用程序 一. android.intent.category.LAUNCHER与android.intent.category.HOME的差别? android.intent.category.LAUNCHER:android.intent.category.LAUNCHER决定应用程序是否显示在程序列表里。就是android开机后的主程序列表。 android.intent.category.HOME:按住“HOME”键,该程序显示在HOME列表里。 二.android.intent.action.MAIN android.intent.action.MAIN:一个应用程序能够有多个Activity,每一个Activity是同级别的,那么在启动程序时,最先启动哪个Activity呢?由它决定。 一般我们创建project的时候,默认启动的ACTIVITY,都有 <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> http://blog.csdn.net/sljjyy/article/details

android App启动过程

两盒软妹~` 提交于 2020-01-04 05:25:50
本文以图文并茂的形式简单介绍一个APP从启动到主页面显示经历了哪些流程,以及实现的原理。不介绍具体源码,仅仅构建一个大体框架。 启动流程: ①点击桌面App图标,Launcher进程采用Binder IPC向system_server进程发起startActivity请求; ②system_server进程接收到请求后,向zygote进程发送创建进程的请求; ③Zygote进程fork出新的子进程,即App进程; ④App进程,通过Binder IPC向sytem_server进程发起attachApplication请求; ⑤system_server进程在收到请求后,进行一系列准备工作后,再通过binder IPC向App进程发送scheduleLaunchActivity请求; ⑥App进程的binder线程(ApplicationThread)在收到请求后,通过handler向主线程发送LAUNCH_ACTIVITY消息; ⑦主线程在收到Message后,通过发射机制创建目标Activity,并回调Activity.onCreate()等方法。 ⑧到此,App便正式启动,开始进入Activity生命周期,执行完onCreate/onStart/onResume方法,UI渲染结束后便可以看到App的主界面。 上面的一些列步骤简单介绍了一个APP启动到主页面显示的过程

Android系统启动流程(四)Launcher启动过程与系统启动流程

心已入冬 提交于 2020-01-04 05:21:18
此前的文章我们学习了init进程、Zygote进程和SyetemServer进程的启动过程,这一篇文章我们就来学习Android系统启动流程的最后一步:Launcher的启动流程,并结合本系列的前三篇文章的内容来讲解Android系统启动流程。建议读这篇文章前要通读本系列的前三篇文章,否则你可能不会理解我在讲什么。 1.Launcher概述 Android系统启动的最后一步是启动一个Home应用程序,这个应用程序用来显示系统中已经安装的应用程序,这个Home应用程序就叫做Launcher。应用程序Launcher在启动过程中会请求PackageManagerService返回系统中已经安装的应用程序的信息,并将这些信息封装成一个快捷图标列表显示在系统屏幕上,这样用户可以通过点击这些快捷图标来启动相应的应用程序。 2.Launcher启动流程 SyetemServer进程在启动的过程中会启动PackageManagerService,PackageManagerService启动后会将系统中的应用程序安装完成。在此前已经启动的ActivityManagerService会将Launcher启动起来。 3.Launcher中应用图标显示流程 包含应用信息的列表apps已经传给了AllAppsContainerView

SmokeTest测试流程

拈花ヽ惹草 提交于 2020-01-04 03:45:20
没办法了,本来是表格,但是粘贴不过来 测试目的: 用于检测该版本在基本的应用场景下,基本的功能是否满足。 测试前提: 发货版本 示例:ATV9冒烟测试测试项解读 表格获取:Google ATV help官网。 Test Plan Version 1.1.2_External_and_3PL Device/Build details Build fingerprint(s) being tested: Use: adb shell getprop ro.build.fingerprint <fingerprint(s)> Reference fingerprint of previously Approved build: Populate this if only running the 'Lite test' cases, and relying on fuller tests from previously Approved builds. See details here: <fingerprint(s)> https://support.google.com/androidpartners_androidtv/answer/9020145 Area Lite test? Test What to look for Exclusions / Applicability

How to redirect User to default launcher in an android app?

依然范特西╮ 提交于 2020-01-01 16:49:39
问题 It's been now a long time since I try to figure out how to develop a android unlock screen app working with an NFC authentication. I am working with a Nexus S. After several researches on the Internet, I came to the conclusion that replacing the lock screen as a third party app is just not supported right now and that we need to modify the platform to do a decent implementation. This is the reason why I developed an home screen app that give the illusion of an unlockscreen app. But my problem

How do I programmatically set the default launcher app? [duplicate]

|▌冷眼眸甩不掉的悲伤 提交于 2020-01-01 10:17:12
问题 This question already has answers here : Closed 7 years ago . Possible Duplicate: Android: change default Home Application I want to create a program like "Home Switcher" that can programmatically set the default launcher. I have no code written yet but can kind of figure out how to find the available launcher apps, but I have no idea how to programmatically set the default. Can anyone point me in the right direction? 回答1: This is not possible, except perhaps via some security flaw. I will

Drop event when select OK to restart Launcher when ANR occurs

↘锁芯ラ 提交于 2020-01-01 07:11:10
问题 When ANR occurs for Launcher,dialog pops up and the Launcher resume then. Select OK to restart Launcher after the launcher resume to respond, the rest keys will be dropped. The problem occurs in my developing environment and it's hard to reproduce.So I do a test for this: Create a simple APK as Launcher, and sleep some time in onCreat or onResume to let the ANR occurs Start the Launcher and press key to let ANR occurs after sleep the view is normally shown behind the ANR dialog select OK to

Detecting android Activity launches

倾然丶 夕夏残阳落幕 提交于 2020-01-01 04:39:25
问题 I have searched the stackoverflow for this question and found : Android, Detect when other apps are launched and Reliable way to detect application launch from home / desktop? , which kind of answers my question but it's still not enough. What I want to do I want to create a widget/app that shows the user of the device a list of recent apps and a list of most used apps. Problem How can I have accurate data about the apps in order to build a list of most used apps. Base information I am