第一次进入有欢迎页,以后在不出现
2015-12-04 17:00
531 查看
在mainfest中guide页
<action android:name="android.intent.action.`这里写代码片`MAIN" />
private SharedPreferences sharepreferences; private SharedPreferences.Editor editor; .... oncreat() sharepreferences=this.getSharedPreferences("check", MODE_PRIVATE); editor=sharepreferences.edit(); boolean fristload=sharepreferences.getBoolean("fristload", true); if (!fristload) { Intent intent = new Intent(); intent.setClass(this,toActivity.class); startActivityForResult(intent,0); } button.setOnClickListener(new OnClickListener() { public void onClick(View v) { editor.putBoolean("fristload", false); Intent intent = new Intent(); intent.setClass(this,toActivity.class); startActivityForResult(intent, 0); } } });
相关文章推荐
- 统一处理jquery ajax请求过程中的异常错误信息的机制
- C++类变量声明
- iOS-常用的辅助工具软件
- iOS9 视频播放
- doT.js介绍
- Android获取清单文件中metaData的值
- 年轻一定要奋斗吗?
- android资源文件查找顺序
- js中几种实用的跨域方法原理详解
- Discuz!图片查看插件(支持鼠标缩放、实际大小、旋转、下载)
- 单例初始化宏定义
- 杭电5504 GT and sequence
- git中的四种对象 tree blob commit tag
- ANT生成war包
- 最小二乘法
- MySQL内存使用 – 全局共享
- LeetCode解题报告--Search Insert Position
- android帐号管理token问题
- powerpoint已停止工作的解决办法(也适用word、excel等其他office组件)
- 软件测试理论