intent通过ComponentName指定要执行的组件名字,创建一个Activity时就可以用这个方式进行指定 通过Main启动Detail 两个活动的布局 Detail <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:and ...
分类:
移动开发 时间:
2020-01-27 22:06:08
阅读次数:
80
布局文件 <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android ...
分类:
移动开发 时间:
2020-01-27 22:01:22
阅读次数:
99
Bundle是个保存元组<key,value>的数据结构,两个活动传递数据时就通过Bundle进行传递 在Main中输入数据,然后将数据传递给Address 两个活动布局 Main <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns: ...
分类:
移动开发 时间:
2020-01-26 22:36:40
阅读次数:
115
这两天通过网上的一些视频教学,了解学习了AS的布局问题,下面对布局进行简单介绍: 主要包括: 1、LinearLayout(线性布局) 2、View视图 一、LinearLayout (1)Layout_width:设置的是当前视图的宽度,设置的属性包括match_parent,wrap_conte ...
分类:
移动开发 时间:
2020-01-26 22:16:05
阅读次数:
136
注意 onRestart的箭头是弄错了,应该指向onStart MainActivity的布局文件和java代码 <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.co ...
分类:
移动开发 时间:
2020-01-26 16:06:58
阅读次数:
121
布局文件 <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android ...
分类:
移动开发 时间:
2020-01-25 22:00:31
阅读次数:
116
额外新建一个layout,用来布局ImageView组件 <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:o ...
分类:
移动开发 时间:
2020-01-25 16:42:18
阅读次数:
133
layout代码 <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.and ...
分类:
移动开发 时间:
2020-01-24 23:44:51
阅读次数:
175
两种文本框:EditText,TextView, 两种按钮:Button,ImageButton, 单选按钮/单选按钮组:RadioButton,RadioGroup 复选框:CheckBox <?xml version="1.0" encoding="utf-8"?> <LinearLayout ...
分类:
移动开发 时间:
2020-01-23 21:19:51
阅读次数:
131
layout absolute_layout <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orienta ...
分类:
其他好文 时间:
2020-01-23 21:16:47
阅读次数:
108