ScrollView嵌套Relative时候会发生问题,RelativeLayout不会充满ScrollView,即使设置match_parent属性也不行 这个时候就需要fillViewPort属性登场了,在ScrollView的源码的onMeasure中,专门针对这个属性做了特殊的处理 prot ...
分类:
其他好文 时间:
2017-01-15 12:51:51
阅读次数:
223
include标签包裹着一个可复用的布局: <include layout="@layout/footer_detail" android:id="@+id/footer" android:layout_width="match_parent" android:layout_height="wrap ...
分类:
移动开发 时间:
2016-12-30 18:48:23
阅读次数:
200
启动Service并传递数据的小实例(通过外界与服务进行通信): 1、activity_main.xml: <EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:text= ...
分类:
移动开发 时间:
2016-12-22 11:53:53
阅读次数:
314
activity_main.xml<LinearLayoutxmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
>
<V..
分类:
移动开发 时间:
2016-12-15 01:22:10
阅读次数:
245
GridView:activity_main.xml<RelativeLayoutxmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="@dimen/acti..
分类:
移动开发 时间:
2016-12-14 22:35:00
阅读次数:
421
activity_main.xml<RelativeLayoutxmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="@dimen/activity_vert..
分类:
移动开发 时间:
2016-12-14 22:27:45
阅读次数:
289
ImageSwitcher:activity_main.xml<RelativeLayoutxmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="@dime..
分类:
移动开发 时间:
2016-12-14 22:14:30
阅读次数:
212
设置视频录制的简易界面<SurfaceView android:id="@+id/surface" android:layout_width="match_parent" android:layout_height="match_parent" /> <LinearLayout android:la ...
分类:
移动开发 时间:
2016-12-14 19:12:31
阅读次数:
308
main6.xml<?xmlversion="1.0"encoding="utf-8"?>
<LinearLayoutxmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<ListView
androi..
分类:
移动开发 时间:
2016-12-14 14:37:50
阅读次数:
238
<?xmlversion="1.0"encoding="utf-8"?>
<LinearLayoutxmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:gravity="center"
>
&l..
分类:
移动开发 时间:
2016-12-13 16:38:52
阅读次数:
224