启动第二个Activityactivity_main.xml文件:
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:la...
分类:
其他好文 时间:
2015-07-23 23:53:43
阅读次数:
138
今天在尝试自定义一个控件后,在布局文件中使用的时候报错
xmlns:tools="http://schemas.android.com/tools"
xmlns:carrey="http://schemas.android.com/apk/res/com.example.customview"
android:layout_width="match_parent"...
分类:
其他好文 时间:
2015-07-23 12:08:27
阅读次数:
143
接着上两篇文章,我们基于Bmob提供的API实现用户登录功能,整体看一下代码。1.注册页面xml:<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width=...
分类:
移动开发 时间:
2015-07-23 08:14:08
阅读次数:
396
效果图:
代码部分main_activity.xml<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent"
android:...
分类:
移动开发 时间:
2015-07-22 16:10:30
阅读次数:
231
??场景:实现安装一个apk应用程序的过程。界面如下:编写如下应用,应用结构如下: RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width=...
分类:
移动开发 时间:
2015-07-21 01:33:15
阅读次数:
215
RatingBar的实现其实是很简单的,只要在xml布局文件中写就行了范例:在主布局文件中,只需要写即可main.xml 1 6 7 15 16 17 18 RatingBar的layout_height和layout_width一般都设置成wrap_con...
分类:
其他好文 时间:
2015-07-20 23:05:24
阅读次数:
276
一、有两种状态: 选中状态(true)、未选中状态(false)二、属性 android:id = "@+id/checkbox" android:layout_width="match_parent" android:layout_height="wrap_content"...
分类:
移动开发 时间:
2015-07-20 21:20:25
阅读次数:
150
Android开发中在布局文件里面都会有如下面的内容:
xmlns:tools="http://schemas.android.com/tools"
android:orientation="vertical"
android:layout_width="match_parent"
andro...
分类:
移动开发 时间:
2015-07-20 01:21:00
阅读次数:
806
上一节学习了利用Intent传值。本节学习利用激活新的Activity获得其返回值。
MainActivity的布局文件如下:
<TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_cont...
分类:
移动开发 时间:
2015-07-19 16:35:12
阅读次数:
148
Android调用系统api使用照相机功能,实现拍照获取图片以及从照相机库中获取指定图片的功能。
以下是示例代码:
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/main"
android:layout_width="match...
分类:
移动开发 时间:
2015-07-19 16:32:08
阅读次数:
205