设置向导页面,通过SharedPreferences来判断是否已经设置过了,跳转到不同的页面

自定义样式

在res/values/styles.xml中

添加节点<style name=””>,设置名称属性

在<style>节点里面,添加节点<item name=””>设置名称属性,就是布局的各种参数

在<item>的文本里面,设置布局的各种参数值

在布局文件中引用样式,style=”@style/xxxxxxxxxxxx”

在TextView的左侧放置小图标

使用左侧图标属性android:drawableLeft=”@android:drawable/xxxxxxxxxxx”,引用android系统的图标,例如:@android:drawable/star_big_on

图标垂直居中对齐,使用对齐属性 android:gravity=”center_vertical”

引导页下面的小圆点

线性布局,横向,ImageView,包裹内容,整体居中

使用系统图标 @android:drawable/presence_online

@android:drawable/presence_invisible

自定义按钮状态背景

在res/drawable/button.xml文件中定义,添加节点<selector>

定义按钮按下状态 添加<item>节点,设置状态属性android:state_pressed=”true”

设置图片属性android:drawable=”xxxx”

设置按钮焦点状态 添加<item>节点,设置状态属性android:state_focus=”true”

定义按钮默认图片 添加<item>节点,设置图片属性android:drawable=”xxxx”

设置图片属性android:drawable=”xxxx”

布局文件中,给按钮设置背景,android:background=”@drawable/xxxxx”

activity_lost_find.xml

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" > <TextView
android:layout_width="match_parent"
android:layout_height="40dp"
android:background="#2D89EF"
android:gravity="center"
android:text="1.手机防盗设置向导"
android:textColor="#fff"
android:textSize="18sp" /> <TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="10dp"
android:layout_marginTop="8dp"
android:text="手机防盗包含以下功能:"
android:textSize="16sp" /> <TextView
style="@style/guide_text_list"
android:drawableLeft="@android:drawable/btn_star_big_on"
android:text="SIM卡变更报警" /> <TextView
style="@style/guide_text_list"
android:drawableLeft="@android:drawable/btn_star_big_on"
android:text="GPS追踪" /> <TextView
style="@style/guide_text_list"
android:drawableLeft="@android:drawable/btn_star_big_on"
android:text="远程数据销毁" /> <TextView
style="@style/guide_text_list"
android:drawableLeft="@android:drawable/btn_star_big_on"
android:text="远程锁屏" /> <LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_horizontal"
android:orientation="horizontal" > <ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@android:drawable/presence_online" /> <ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@android:drawable/presence_invisible" /> <ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@android:drawable/presence_invisible" /> <ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@android:drawable/presence_invisible" />
</LinearLayout> <RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent" > <Button
android:textColor="#444"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:layout_marginBottom="10dp"
android:layout_marginRight="10dp"
android:background="@drawable/button_selector"
android:text="下一步" />
</RelativeLayout> </LinearLayout>

button_selector.xml

<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android"> <item android:drawable="@drawable/barcode_btn_guide_pressed" android:state_focused="true"></item>
<item android:drawable="@drawable/barcode_btn_guide_pressed" android:state_pressed="true"></item>
<item android:drawable="@drawable/barcode_btn_guide_normal"></item> </selector>

[android] 手机卫士设置向导页面的更多相关文章

  1. Android 手机卫士2--home页面

    1,自定义获取焦点的TextView FocusTextView.java package com.itheima.mobilesafe74.view; import android.content. ...

  2. Android 手机卫士--设置界面&功能列表界面跳转逻辑处理

    在<Android 手机卫士--md5加密过程>中已经实现了加密类,这里接着实现手机防盗功能 本文地址:http://www.cnblogs.com/wuyudong/p/5941959. ...

  3. Android 手机卫士--参照文档编写选择器

    本文来实现<Android 手机卫士--导航界面1的布局编写>中的图片选择器部分的代码. 本文地址:http://www.cnblogs.com/wuyudong/p/5944356.ht ...

  4. Android 手机卫士--确认密码对话框编写

    本文接着实现“确认密码”功能,也即是用户以前设置过密码,现在只需要输入确认密码 本文地址:http://www.cnblogs.com/wuyudong/p/5940718.html,转载请注明出处. ...

  5. Android 手机卫士--签名文件说明&包名说明

    在<Android 手机卫士--打包生成apk维护到服务器>一文中,实现了新版本的apk到服务器,当打开客户端apk的时候,发现有新版本,提示更新.还实现了利用xutils工具实现了从服务 ...

  6. Android 手机卫士--弹出对话框

    在<Android 手机卫士--解析json与消息机制发送不同类型消息>一文中,消息机制发送不同类型的信息还没有完全实现,在出现异常的时候,应该弹出吐司提示异常,代码如下: private ...

  7. android手机卫士、3D指南针、动画精选、仿bilibli客户端、身份证银行卡识别等源码

    Android精选源码 android身份证.银行卡号扫描源码 android仿bilibili客户端 android一款3D 指南针 源码 android手机卫士app源码 android提醒应用, ...

  8. Android 手机卫士--阶段小结1

    本文地址:http://www.cnblogs.com/wuyudong/p/5904528.html,转载请注明源地址. 本文对之前手机卫士开发进行一个小结. 1.SplashActivity 版本 ...

  9. Android 手机卫士--安装过程中点击回退按钮

    本文地址:http://www.cnblogs.com/wuyudong/p/5903707.html,转载请注明源地址. 在手机卫士之前的版本升级的对话框中: 有的用户暂时不想更新,没有点击“稍后再 ...

随机推荐

  1. linux主机间复制文件

    命令基本格式: 1.从 本地 复制到 远程    * 复制文件:          * 命令格式:                  scp local_file remote_username@re ...

  2. shell的重定向

    >file  将file文件重定向为输出源,新建模式,可以将正确的结果输出到file文件 >>file 将file文件重定向为输出源,追加模式 <file  将file文件重定 ...

  3. iOS-UITableView-处理cell上按钮事件(弹出警示框,页面跳转等)

    一. 目的: 实现UITableViewCell上按钮点击事件可以进行页面跳转. 二. 实现方法: 1. 用协议的方式的实现. 2. 需要自定义UITableViewCell. 三. 代码部分. ce ...

  4. C#ASP.NET 通用扩展函数之 IsWhat 简单好用

    好东西都需要人去整理.分类 注意:需要引用命名空间 SyntacticSugar 用法: /***扩展函数名细***/ //[IsInRange] int num = 100; //以前写法 if ( ...

  5. 如何单独启动wamp 中自带的MySQL

    前言:Wamp集成了Apache.MySQL和PHP环境.使用Wamp进行网站开发,是很多网站开发爱好者的选择.同时,其集成的MySQL服务,也常被用于MySQL的开发.这个时候我们只是想启动MySQ ...

  6. 订餐APP第一次sprint+燃尽图

    MY-HR 成员: 角色分配 学号 博客园 团队贡献分 丘惠敏 PM项目经理 201406114203 http://www.cnblogs.com/qiuhuimin/ 19 郭明茵 用户 2014 ...

  7. Res_Orders_01之需求分析

    Res_Orders_01之需求分析 一.背景及好处 为了提高餐厅的运营效率,增强餐厅各部门间的配合,减少顾客到店后的点餐.等餐及结算过程消耗的时间,降低服务员点餐失误率,进一步提高餐厅管理人员对菜品 ...

  8. C# WinFrom 跨线程访问控件

    1.跨线程访问控件委托和类的定义 using System; using System.Windows.Forms; namespace ahwildlife.Utils { /// <summ ...

  9. 因用了NeatUpload大文件上传控件而导致Nonfile portion > 4194304 bytes错误的解决方法

    今天遇到一个问题,就是“NeatUpload大文件上传控件而导致Nonfile portion > 4194304 bytes错误”,百度后发现了一个解决方法,跟大家分享下: NeatUploa ...

  10. android 6.0 httpclient

    Apache HTTP Client RemovalAndroid 6.0 release removes support for the Apache HTTP client. If your ap ...