getSupportFragmentManager() versus getFragmentManager() in android 3.0+

后端 未结 3 470
半阙折子戏
半阙折子戏 2020-12-18 00:18

In the documentation for android.support.v4.app.FragmentManager:

\"Static library support version of the framework\'s FragmentManager. Used to write apps that run on

3条回答
  •  生来不讨喜
    2020-12-18 00:58

    If you are using API >= 14, then use getFragmentManager(). If you want compatibility with devices below API 14 then you can use getSupportFragmentManager(). Therefore, getSupportFragmentManager() is used to deliver newer features to older platforms.

提交回复
热议问题