// Path: src/com/xiaomi/mitv/soundbarapp/TypefaceManager.java
// public class TypefaceManager {
//     private static Typeface mType;
// 
//     public static void updateTextFace(Context context, ViewGroup root){
//         if(mType==null) init(context);
//         setFontStyle(root, mType);
//     }
// 
//     private static void init(Context context){
// //        mType = Typeface.createFromAsset(context.getAssets(),"fonts/lanting.TTF");
//     }
// 
//     private static void setFontStyle(ViewGroup root, Typeface type){
// //        if(root == null) return;
// //        for(int i=0; i<root.getChildCount(); i++){
// //            View v = root.getChildAt(i);
// //            if(v instanceof TextView){
// //                ((TextView)v).setTypeface(type);
// //            }else if(v instanceof ViewGroup){
// //                setFontStyle((ViewGroup)v, type);
// //            }
// //        }
//     }
// }


import android.app.Activity;
import android.graphics.Typeface;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.text.TextUtils;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;
import com.umeng.analytics.MobclickAgent;
import com.xiaomi.mitv.soundbarapp.TypefaceManager;
import com.xiaomi.mitv.utils.AsyncTaskRunner;
import org.w3c.dom.Text;
package com.xiaomi.mitv.soundbarapp.fragment;


/**
 * Created by chenxuetong on 8/26/14.
 */
public abstract class BaseFragment extends Fragment {
    protected View mRootView;
    protected boolean mIsDestroyed = false;

    @Override
    public void onViewCreated(View view, Bundle savedInstanceState) {
        super.onViewCreated(view, savedInstanceState);
        mRootView = view;
    }

    @Override
    public void onActivityCreated(Bundle savedInstanceState) {
        super.onActivityCreated(savedInstanceState);
        View root = getView();
        if( root instanceof ViewGroup){
// Path: src/com/xiaomi/mitv/soundbarapp/TypefaceManager.java
// public class TypefaceManager {
//     private static Typeface mType;
// 
//     public static void updateTextFace(Context context, ViewGroup root){
//         if(mType==null) init(context);
//         setFontStyle(root, mType);
//     }
// 
//     private static void init(Context context){
// //        mType = Typeface.createFromAsset(context.getAssets(),"fonts/lanting.TTF");
//     }
// 
//     private static void setFontStyle(ViewGroup root, Typeface type){
// //        if(root == null) return;
// //        for(int i=0; i<root.getChildCount(); i++){
// //            View v = root.getChildAt(i);
// //            if(v instanceof TextView){
// //                ((TextView)v).setTypeface(type);
// //            }else if(v instanceof ViewGroup){
// //                setFontStyle((ViewGroup)v, type);
// //            }
// //        }
//     }
// }


// Path: src/com/xiaomi/mitv/soundbarapp/fragment/BaseFragment.java
import android.app.Activity;
import android.graphics.Typeface;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.text.TextUtils;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;
import com.umeng.analytics.MobclickAgent;
import com.xiaomi.mitv.soundbarapp.TypefaceManager;
import com.xiaomi.mitv.utils.AsyncTaskRunner;
import org.w3c.dom.Text;

package com.xiaomi.mitv.soundbarapp.fragment;


/**
 * Created by chenxuetong on 8/26/14.
 */
public abstract class BaseFragment extends Fragment {
    protected View mRootView;
    protected boolean mIsDestroyed = false;

    @Override
    public void onViewCreated(View view, Bundle savedInstanceState) {
        super.onViewCreated(view, savedInstanceState);
        mRootView = view;
    }

    @Override
    public void onActivityCreated(Bundle savedInstanceState) {
        super.onActivityCreated(savedInstanceState);
        View root = getView();
        if( root instanceof ViewGroup){
            TypefaceManager.updateTextFace(getActivity(), (ViewGroup) root);