示例#1
0
文件: Form1.cs 项目: lineCode/QUILib
        public int notify(ref TNofityUI msg)
        {
            if (msg.mType == "click")
            {
                if (msg.mSender == mButtonClose)
                {
                    this.Dispose();
                }
                else if (msg.mSender == mButtonLogin)
                {
                    Action action = () =>
                    {
                        MessageBox.Show("OK");
                    };
                    this.BeginInvoke(action);
                }
            }
            else if (msg.mType == "itemselect")
            {
                Action <string, string> action = (controlName, strText) =>
                {
                    if (controlName == "accountcombo")
                    {
                        EditUI pAccountEdit = (EditUI)mManager.findControl("accountedit");
                        if (pAccountEdit != null)
                        {
                            pAccountEdit.setText(strText);
                        }
                    }
                };
                this.BeginInvoke(action, msg.mSender.getName(), msg.mSender.getText());
            }

            return(0);
        }
示例#2
0
文件: Form1.cs 项目: lineCode/QUILib
        public void init()
        {
            mButtonClose = mManager.findControl("closebtn");
            mButtonLogin = mManager.findControl("loginBtn");


            {
                ComboUI pAccountCombo = (ComboUI)mManager.findControl("accountcombo");
                EditUI  pAccountEdit  = (EditUI)mManager.findControl("accountedit");
                if (pAccountCombo != null && pAccountEdit != null)
                {
                    pAccountEdit.setText(pAccountCombo.getText());
                }
            }
        }
示例#3
0
        public void init()
        {
            mButtonClose = mManager.findControl("closebtn");
            mButtonLogin = mManager.findControl("loginBtn");


            {
                ComboUI pAccountCombo = (ComboUI)mManager.findControl("accountcombo");
                EditUI  pAccountEdit  = (EditUI)mManager.findControl("accountedit");
                if (pAccountCombo != null && pAccountEdit != null)
                {
                    pAccountEdit.setText(pAccountCombo.getText());
                }
            }
            {
                // 获取列表控件
                mUserList = (ListUI)mManager.findControl("userlist");
                mUserList.setTextCallback(this);
            }
        }