zoukankan      html  css  js  c++  java
  • fragment 切换

    1.Fragment的添加方式

    FragmentTransaction ft = getFragmentManager().beginTransaction();
    ft.hide
    ft.show
    ft.add
    ft.replace
    ft.hide---ft.show
    a.let the old fragment to hide, but not delete in memory, so it will quick showing after calling show
    b.when calling ft.replace it will delete all old memory, and it will onCreateView for a new time when show this.
    c.ft.add it using with ft-hide/ft.show, not delete fragment in memory.
    d.ft.remove sync using with ft.add. just remove what you want .
  • 相关阅读:
    Ajax
    Linux安装SmartSVN及破解
    JQuery异步提交
    动画效果
    事件
    表单选择器
    DOM操作
    JQuery基础
    PHP环境配置
    DP--钢条切割
  • 原文地址:https://www.cnblogs.com/deman/p/4511891.html
Copyright © 2011-2022 走看看