Esempio n. 1
0
    /// <summary>
    /// 注册模块并且
    /// 启动模块
    /// </summary>
    private void RegModuleAndStart()
    {
        //测试
        appdomain.DelegateManager.RegisterMethodDelegate <System.Exception>();
        appdomain.DelegateManager.RegisterDelegateConvertor <TestDelegateMethod>((action) =>
        {
            return(new TestDelegateMethod((a) =>
            {
                ((System.Action <Exception>)action)(a);
            }));
        });
        //TODO:要修改成通过配置加载
        List <string> list = new List <string>()
        {
            "BDFramework.ScreenView_Test1",
            "BDFramework.ScreenView_Test2"
        };

        //注册各个模块
        m_layerCenter = new ScreenViewCenter();
        m_layerCenter.AddLayer();
        g_mainLayer = m_layerCenter.GetLayer(0);

        for (int i = 0; i < list.Count; i++)
        {
            g_mainLayer.RegScreen(new ScreenView_HotFix_Wrapper(appdomain, list[i]));
        }
        //
        g_mainLayer.BeginNavTo("test_1");
    }
Esempio n. 2
0
 public void BeginInit(Action <Exception> onInit, ScreenViewCenter screenCenter)
 {
     Debug.LogFormat("{0}:on Init", this.name);
 }