示例#1
0
    public static void doSaveAsset(GameObject go)
    {
        CLPanelBase panel = go.GetComponent <CLPanelBase>();

        if (panel == null)
        {
            return;
        }
        Debug.Log(panel.name);
        if (panel.isNeedResetAtlase)
        {
            CLUIUtl.resetAtlasAndFont(panel.transform, true);
            PrefabUtility.SavePrefabAsset(go);
        }
        string dir = Application.dataPath + "/" + ECLEditorUtl.getPathByObject(go);

        dir = Path.GetDirectoryName(dir);
        ECLCreatAssetBundle4Update.createAssets4Upgrade(dir, panel.gameObject, true);

        // 必须再取一次,好像执行了上面一句方法后,cell就会变成null
        panel = go.GetComponent <CLPanelBase>();
        if (panel != null && panel.isNeedResetAtlase)
        {
            CLUIUtl.resetAtlasAndFont(panel.transform, false);
            PrefabUtility.SavePrefabAsset(go);
        }
    }
示例#2
0
    public static void onGetCalenderPanel(params object[] orgs)
    {
        CLPanelBase p    = orgs [0] as CLPanelBase;
        ArrayList   list = orgs [1] as ArrayList;

        if (p == null)
        {
            return;
        }
        p.setData(list);
        CLPanelManager.showPanel(p);
    }