示例#1
0
    public void DelOpComponent(OptionInfo config)
    {
        AVGDataComponent component = null;

        if (opComponentDic.TryGetValue(config.Id, out component))
        {
            opComponentDic.Remove(config.Id);
            component.Close();
            return;
        }
    }
示例#2
0
    public void DelDiaComponent(DialogueInfo config)
    {
        AVGDataComponent component = null;

        if (diaComponentDic.TryGetValue(config.Id, out component))
        {
            diaComponentDic.Remove(config.Id);
            component.Close();
            return;
        }
    }
示例#3
0
    public void AddOrRefreshOpComponent(OptionInfo config)
    {
        AVGDataComponent component = null;

        if (opComponentDic.TryGetValue(config.Id, out component))
        {
            component.Init(AVGDataComponent.AVGComponentType.Option, config);
            return;
        }

        var item = UIManager.instance.CreateComponent <AVGDataComponent>(UINames.AVGDataComponet, optionScroll);

        item.Init(AVGDataComponent.AVGComponentType.Option, config);
        item.callback             = OnBtnClickOptionDetail;
        opComponentDic[config.Id] = item;
    }
示例#4
0
    public void AddOrRefreshDiaComponent(DialogueInfo config)
    {
        AVGDataComponent component = null;

        if (diaComponentDic.TryGetValue(config.Id, out component))
        {
            component.Init(AVGDataComponent.AVGComponentType.Dialogue, config);
            return;
        }

        var item = UIManager.instance.CreateComponent <AVGDataComponent>(UINames.AVGDataComponet, dialogScroll);

        item.Init(AVGDataComponent.AVGComponentType.Dialogue, config);
        item.callback = OnBtnClickDialogueDetail;
        diaComponentDic[config.Id] = item;
    }