Пример #1
0
    public void InitLoginUI()
    {
        if (_ui == null)
        {
            return;
        }
        string account_name = "";

        if (LoginIDManager.GetFirstLoginState()) //第一次登录
        {
        }
        else //第二次登录
        {
            account_name = LoginIDManager.GetAccount();
#if IOS_SDK || ANDROID_SDK
            string userName = LoginIDManager.GetUserName();
//            if (userName == "")
//            {
            //userName = CommonFunction.GetConstString("STR_TOURIST");
//                userName = _ui.lblText.text;
//            }
            //            _ui.lblText.text = userName;
            SetAccountName(userName);
#else
            SetAccountName(account_name);
#endif
        }
        _ui.lblServerLabel.text = LoginIDManager.GetPlatServerName();
        //_ui.goServerList.SetActive(false);
        SetDisplayServerLabel(LoginIDManager.GetPlatDisplayServerID(), LoginIDManager.GetPlatServerName());

        //UIEventListener.Get(_ui.goBg).onClick = onBgClick;
        UIEventListener.Get(_ui.lblText.gameObject).onClick = onInputClick;
        UIEventListener.Get(_ui.goServer).onClick           = onChangeServer;
    }
Пример #2
0
    static int GetPlatDisplayServerID(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 0);
        uint o = LoginIDManager.GetPlatDisplayServerID();

        LuaScriptMgr.Push(L, o);
        return(1);
    }