http://developer.android.com/reference/android/app/Fragment.html

基本上翻译加上开发使用

1基本:

  1. onAttach(Activity) called once the fragment is associated with its activity.
  2. onCreate(Bundle) called to do initial creation of the fragment.
  3. onCreateView(LayoutInflater, ViewGroup, Bundle) creates and returns the view hierarchy associated with the fragment.
  4. onActivityCreated(Bundle) tells the fragment that its activity has completed its own Activity.onCreate().
  5. onViewStateRestored(Bundle) tells the fragment that all of the saved state of its view hierarchy has been restored.
  6. onStart() makes the fragment visible to the user (based on its containing activity being started).
  7. onResume() makes the fragment interacting with the user (based on its containing activity being resumed).

As a fragment is no longer being used, it goes through a reverse series of callbacks:

  1. onPause() fragment is no longer interacting with the user either because its activity is being paused or a fragment operation is modifying it in the activity.
  2. onStop() fragment is no longer visible to the user either because its activity is being stopped or a fragment operation is modifying it in the activity.
  3. onDestroyView() allows the fragment to clean up resources associated with its View.
  4. onDestroy() called to do final cleanup of the fragment's state.
  5. onDetach() called immediately prior to the fragment no longer being associated with its activity.

http://www.cnblogs.com/mengdd/archive/2013/01/08/2851368.html

更多相关文章

  1. 代码中设置drawableleft
  2. android 3.0 隐藏 系统标题栏
  3. Android开发中activity切换动画的实现
  4. Android(安卓)学习 笔记_05. 文件下载
  5. Android中直播视频技术探究之—摄像头Camera视频源数据采集解析
  6. 技术博客汇总
  7. android 2.3 wifi (一)
  8. AndRoid Notification的清空和修改
  9. Android中的Chronometer

随机推荐

  1. 修改状态栏颜色和状态栏字体颜色
  2. 短视频商城源码,Android(安卓)多图上传压
  3. Android使用JPEG实现图片压缩上传
  4. 老罗Android视频开发教程(百度地图实战开
  5. Android(安卓)PreferenceActivity 使用练
  6. php实现自运行的实例详解
  7. 在PHP中操作文件的扩展属性
  8. php文件下载后无法打开的处理方案及代码
  9. 一篇文章弄懂PHP和HTML的嵌套写法
  10. PHP八大设计模式案例详解