让Android程序单例运行

来源:互联网 发布:写论文查数据的网站 编辑:程序博客网 时间:2024/05/22 06:54

1, Set application launch mode (More details about launchMode, please refer to http://code.google.com/intl/en-CN/android/reference/android/R.styleable.html#AndroidManifestActivity_launchMode) to single instance in AndroidManifest.xml: 2, If you find single instance doesn't take effect when you install and run your application from Eclipse, please press Run> Run Configurations ...,and select the configuration item of your application on your Eclipse, then select Do Nonthing in group box Launch Action in Android tab. (A launch configuration specifies the project to launch, the Activity to start, the emulator options to use, and so on, please refer to online document http://code.google.com/intl/en-CN/android/intro/develop-and-debug.html in section Create a Launch Configuration to get more details)

原创粉丝点击