程序锁学习(指纹识别的基础)------阿冬专栏
Posted 阿冬专栏
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了程序锁学习(指纹识别的基础)------阿冬专栏相关的知识,希望对你有一定的参考价值。
高级工具--程序锁界面设计(一)
转载自:http://blog.csdn.net/asmcvc/article/details/18356007
界面效果图:
在加载安装的应用程序列表时,显示进度条:
布局文件:
[html] view plain copy![](https://code.csdn.net/assets/CODE_ico.png)
- <?xml version="1.0" encoding="utf-8"?>
- <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:orientation="vertical" android:layout_width="match_parent"
- android:layout_height="match_parent">
- <TextView style="@style/title_center_text"
- android:text="程序锁"/>
- <View style="@style/splitter_view"/>
- <RelativeLayout
- android:layout_height="fill_parent"
- android:layout_width="fill_parent">
- <LinearLayout
- android:id="@+id/ll_applock_loading"
- android:gravity="center"
- android:orientation="vertical"
- android:visibility="invisible"
- android:layout_height="fill_parent"
- android:layout_width="fill_parent">
- <ProgressBar
- android:layout_height="wrap_content"
- android:layout_width="wrap_content" />
- <TextView style="@style/content_text"
- android:text="正在加载程序信息……"/>
- </LinearLayout>
- <ListView
- android:fastScrollEnabled="true"
- android:id="@+id/lv_applock"
- android:layout_height="match_parent"
- android:layout_width="match_parent"/>
- </RelativeLayout>
- </LinearLayout>
ListView的每一个item的布局:
[html] view plain copy![](https://code.csdn.net/assets/CODE_ico.png)
- <?xml version="1.0" encoding="utf-8"?>
- <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:orientation="horizontal" android:layout_width="match_parent"
- android:layout_height="wrap_content">
- <ImageView
- android:id="@+id/iv_applock_icon"
- android:layout_height="wrap_content"
- android:layout_width="wrap_content"
- android:layout_alignParentLeft="true"/>
- <TextView style="@style/content_text"
- android:id="@+id/iv_applock_name"
- android:layout_toRightOf="@+id/iv_applock_icon"/>
- <ImageView
- android:id="@+id/iv_applock_status"
- android:layout_height="wrap_content"
- android:layout_width="wrap_content"
- android:layout_alignParentRight="true"/>
- </RelativeLayout>
界面在加载时先获取已安装的程序列表,保存应用程序的信息用一个AppInfo类来表示:
[java] view plain copy![](https://code.csdn.net/assets/CODE_ico.png)
- package com.example.mobilesafe.engine;
- import android.graphics.drawable.Drawable;
- /**
- * Created by sing on 14-1-15.
- * desc:
- */
- public class AppInfo
- private static final String TAG = "AppInfo";
- //包名
- private String packname;
- //应用程序版本号
- private String version;
- IOS 指纹识别的简单使用
git@oschina使用学习--------阿冬专栏!!!
git@oschina使用学习--------阿冬专栏!!!
Java Web中的ActionDaoServiceModel学习笔记-----阿冬专栏