最新消息:20210816 当前crifan.com域名已被污染,为防止失联,请关注(页面右下角的)公众号

【整理】android.support.v4.app.FragmentActivity vs android.app.Fragment

Android crifan 2596浏览 0评论

【背景】

折腾android期间,对于:

android.support.v4.app.FragmentActivity

android.app.Fragment

之前,不了解其区别。

所以要去了解了解。

【折腾过程】

搜:

android.support.v4.app.FragmentActivity vs android.app.Fragment

参考:

android fragment(android.support.v4.app.Fragment和android.app.Fragment区别) – woshilisao的专栏 – 博客频道 – CSDN.NET

Android.app Fragments vs. android.support.v4.app using ViewPager? – Stack Overflow

android – Fragment or Support Fragment? – Stack Overflow

Ken Yang 筆記: Android Fragment Activity

简单说就是:

android.app.Fragment是之前(Android 3.0-)的;

android.support.v4.app.FragmentActivity是新的,android 4.0+之后的

 

两者不要混用,否则容易出错。。

 

有空继续总结。。。。

转载请注明:在路上 » 【整理】android.support.v4.app.FragmentActivity vs android.app.Fragment

发表我的评论
取消评论

表情

Hi,您需要填写昵称和邮箱!

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址
85 queries in 0.182 seconds, using 22.05MB memory