package com.ruiwenliu.wrapper.util.listener;

public class SwitchFragment {
    public static ChangeFragment sChangeFragment;  //改变选中Frangment的接口

    public static void setFragmentSelected(ChangeFragment changeFragment) {
        if (sChangeFragment == null) {
            synchronized (SwitchFragment.class) {
                if (sChangeFragment == null) {
                    sChangeFragment = changeFragment;
                }
            }
        }
    }

    public interface ChangeFragment {
        void changge(int postion);
    }
}