在 Fragment的解析(一)中讲到了BackStackRecord的run方法, 我们以OP_REPLACE 操作为例看看具体的执行过程: //BackStackRecord.java?run()?..
case?OP_REPLACE:?{
???????????????????...
分类:
其他好文 时间:
2014-10-16 14:58:53
阅读次数:
319
Fragment中有一个ViewPager,ViewPager的每个pager为Fragment
如此内嵌引发的异常:
java.lang.IllegalStateException: Activity has been destroyed
at android.support.v4.app.FragmentManagerImp
的解决方案...
分类:
其他好文 时间:
2014-10-16 13:26:42
阅读次数:
526
在Android3.0之后,Google对UI导航设计上进行了一系列的改革,其中有一个非常好用的新功能就是引入的ActionBar,他用于取代3.0之前的标题栏,并提供更为丰富的导航效果。一、添加ActionBar1、不需要导入ActionBar,因为在android3.0或者以上版本中,Actio...
分类:
其他好文 时间:
2014-10-16 02:23:12
阅读次数:
276
问题描述 如图所示,坐标的小箭头能不能换小一点? 解决方案1 intupid=Resources.getSystem().getIdentifier("up","id","android");...
分类:
其他好文 时间:
2014-10-16 00:47:21
阅读次数:
323
问题描述 我用findViewById为什么取不到控件,我是android初学者,还请各位前辈指点 解决方案1 大侠,你自己不是写在了Fragment里面么。。。。。。。你在onResume里面写应该可...
分类:
移动开发 时间:
2014-10-15 23:28:21
阅读次数:
457
Fragment在实际项目开发中使用的越来越多,现在简单介绍一下
布局文件:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_par...
分类:
移动开发 时间:
2014-10-15 22:54:41
阅读次数:
265
对于要重用资源,节约代码量,fragment起到很好的制约作用
一 先来看看fragment的调用方式。
1.写在布局中
比如我有一个fragme叫 DateFragment.class
第一种方法
android:id = "@+id/datefragment"
android:layout_weight="1"
android:layout_width="0dp"
a...
分类:
其他好文 时间:
2014-10-15 04:17:19
阅读次数:
195
android- pulltorefresh 一个强大的拉动刷新开源项目,支持各种控件下拉刷新,如ListView、ViewPager、WevView、 ExpandableListView、GridView、(Horizontal) ScrollView、Fragment上下左右拉动刷新。并且他 ...
分类:
移动开发 时间:
2014-10-14 20:22:59
阅读次数:
216
开发时遇到一个问题:使用ViewPager+Fragment实现滑动tab切换,在其中某一个Fragment中嵌套一个ViewPager轮播卡片。测试发现轮播卡片不能进行左右滑动了。 看了不少博文,都是通过覆盖onInterceptTouchEvent等方法拦截事件处理,例如: @Ove...
分类:
其他好文 时间:
2014-10-14 17:10:38
阅读次数:
268
三张图让你快速明白activity与fragment生命周期的异同点...
分类:
其他好文 时间:
2014-10-13 21:22:37
阅读次数:
191