Example #1
0
    public TestPop4()
    {
        m_popId    = POP_ID.TEST_POP_4;
        m_layerIdx = POP_LAYER_IDX.LAYER_POP_1;

        ShowGameObject();

        //
        m_btnOk    = GetChildByName <KButton>("Button_Ok", true);
        m_btnClose = GetChildByName <KButton>("Button_Close", true);

        m_panel = GameObjUtil.GetParent(m_btnOk.gameObject);

        //
        m_inputName      = GetChildByName <KInputField>("Input_name", true);
        m_labelTestInput = GetChildByName <KText>("Label_testInput", true);
        //
        m_tgl_1      = GetChildByName <KToggle>("Toggle_position1", true);
        m_labelTgl_1 = GetChildByName <KText>(m_tgl_1.gameObject, "Label_Text", true);
        m_tglGroup_1 = GetChildByName <KToggleGroup>("ToggleGroup_a1", true);
        //
        m_sliderSchedule = GetChildByName <KSlider>("Slider_Schedule1", true);
        m_labelSchedule  = GetChildByName <KText>("Label_testSilder", true);
        //
        m_barLoading = GetChildByName <KProgressBar>("ProgressBar_loading", true);
        //
        m_icon = GetChildByName <KImage>("Image_sharedAnchor", true);
        //
        m_scrollView = GetChildByName <KScrollView>("ScrollView_GuildList", true);
        m_listView   = ComponentUtil.EnsureComponent <KListViewScroll>(m_scrollView.gameObject);
    }
Example #2
0
    void OnTglGroupValue(KToggleGroup tglGroup_, int idx_, bool b_)
    {
        KToggle child = tglGroup_.GetToggle(idx_);
        KText   label = GetChildByName <KText>(child.gameObject, "Label_Text");

        label.text = b_ ? "选中" : "没选中";
    }
Example #3
0
    public TestKUIPop3()
    {
        m_popId    = POP_ID.TEST_KUI_3;
        m_layerIdx = POP_LAYER_IDX.LAYER_POP_1;

        ShowGameObject();

        m_toggle1 = GetChildByName <KToggle>("Toggle_position1", true);
        m_toggle1.needReqChange = true;

        m_toggleGroup1 = GetChildByName <KToggleGroup>("ToggleGroup_1", true);
        //m_toggleGroup1.allowMultiple = true;
        //m_toggleGroup1.needReqChange = true;
        //m_toggleGroup1.allowSwitchOff = true;

        m_inputName = GetChildByName <KInputField>("Input_name", true);


        m_buttonAnnounce = GetChildByName <KButton>("Button_SystemAnnounce", true);
        m_buttonClose    = GetChildByName <KButton>("Button_Close", true);


        m_barExp          = GetChildByName <KProgressBar>("ProgressBar_EXP", true);
        m_sliderSchedule1 = GetChildByName <KSlider>("Slider_Schedule1", true);

        m_icon1 = GetChildByName <KImage>("Image_Icon1", true);


        m_scrollViewItemList = GetChildByName <KScrollView>("ScrollView_ItemList", true);
    }
Example #4
0
    void OnToggleGroupReq(KToggleGroup toggle_, int index_, bool isOn_)
    {
        Log.Debug("OnToggleGroupReq:" + index_ + " " + isOn_, this);

        toggle_.Select(index_, isOn_, true);
    }
Example #5
0
 void OnToggleGroup(KToggleGroup toggle_, int index_, bool isOn_)
 {
     Log.Debug("OnToggleGroup:" + index_ + " " + isOn_, this);
 }