Skip to content

Commit 9cc9293

Browse files
committed
feat: update NIM to 10.9.72-beta.0
Signed-off-by: Dylan <2894220@gmail.com>
1 parent 7a9069d commit 9cc9293

File tree

10 files changed

+45
-537
lines changed

10 files changed

+45
-537
lines changed

.cmake/export_recipes.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ function(export_recipes_dynamically)
128128
"libyuv/1892@yunxin/stable"
129129
"sqlite3/3.51.0@yunxin/stable"
130130
"tinyxml/2.6.2@yunxin/stable"
131-
"nim/10.9.33@yunxin/stable"
131+
"nim/10.9.72-beta.0@yunxin/stable"
132132
"nertc/4.1.1@yunxin/stable"
133133
"libcef/3.2623.1401@yunxin/stable"
134134
"ne_live_player/1.6.9@yunxin/stable"

app_sdk/base/http/sdk_http_manager.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,6 @@ namespace app_sdk
116116

117117
#ifdef _DEBUG
118118
QLOG_APP(L"#####response api:{0} rescode:{1}\r\n{2}") << request->GetAPIURL() << response_code << reply;
119-
std::wstring test = nbase::UTF8ToUTF16(reply);
120119
#else
121120
QLOG_APP(L"#####response api:{0} rescode:{1}") << request->GetAPIURL() << response_code ;
122121
#endif

app_sdk/protocol/sdk_pro.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -280,9 +280,9 @@ void SDK_PRO::SendSmsCodeResponse::OnParse(const std::string &response)
280280
}
281281
else
282282
{
283-
if (json_reply.isMember("message"))
283+
if (json_reply.isMember("msg"))
284284
{
285-
err_msg_ = json_reply["message"].asString();
285+
err_msg_ = json_reply["msg"].asString();
286286
}
287287
QLOG_ERR(L"Invoke send sms code error. Json rescode: {0}.") << res;
288288
}

bin/resources/lang/en_US/gdstrings.ini

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,13 @@ STRID_LOGIN_FORM_SMS_CODE = SMS Code
5353
STRID_LOGIN_FORM_GET_CODE = Get Code
5454
STRID_LOGIN_FORM_INPUT_MOBILE = Enter mobile number
5555
STRID_LOGIN_FORM_INPUT_SMS_CODE = Enter SMS code
56+
STRID_LOGIN_FORM_MOBILE_EMPTY = Please enter mobile number
57+
STRID_LOGIN_FORM_MOBILE_INVALID = Please enter a valid mobile number
58+
STRID_LOGIN_FORM_SMS_CODE_EMPTY = Please enter SMS code
59+
STRID_LOGIN_FORM_SENDING_CODE = Sending...
60+
STRID_LOGIN_FORM_CODE_SENT_SUCCESS = SMS code sent successfully
61+
STRID_LOGIN_FORM_CODE_SEND_FAILED = Failed to send SMS code
62+
STRID_LOGIN_FORM_ERROR_WITH_CODE = Error code: %d
5663
STRID_LOGIN_FORM_LOGINING = Logining...
5764
STRID_LOGIN_FORM_CHATROOMDEMO = Anonymous-Chatroom Demo
5865
STRID_LOGIN_FORM_LOGIN = Login

bin/resources/lang/zh_CN/gdstrings.ini

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,13 @@ STRID_LOGIN_FORM_SMS_CODE = 验证码
5353
STRID_LOGIN_FORM_GET_CODE = 获取验证码
5454
STRID_LOGIN_FORM_INPUT_MOBILE = 请输入手机号
5555
STRID_LOGIN_FORM_INPUT_SMS_CODE = 请输入验证码
56+
STRID_LOGIN_FORM_MOBILE_EMPTY = 请输入手机号
57+
STRID_LOGIN_FORM_MOBILE_INVALID = 请输入正确的手机号
58+
STRID_LOGIN_FORM_SMS_CODE_EMPTY = 请输入验证码
59+
STRID_LOGIN_FORM_SENDING_CODE = 发送中...
60+
STRID_LOGIN_FORM_CODE_SENT_SUCCESS = 验证码发送成功
61+
STRID_LOGIN_FORM_CODE_SEND_FAILED = 发送验证码失败
62+
STRID_LOGIN_FORM_ERROR_WITH_CODE = 错误码: %d
5663
STRID_LOGIN_FORM_LOGINING = 正在登录...
5764
STRID_LOGIN_FORM_CHATROOMDEMO = 匿名聊天室Demo
5865
STRID_LOGIN_FORM_LOGIN = 登录

bin/resources/themes/default/login/login.xml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,17 @@
2626
<VBox name="enter_panel" width="240" height="auto" margin="20,10,20,0" bkimage="user_password.png">
2727
<HBox height="41" padding="14,1,10,0">
2828
<Control name="usericon" width="16" height="16" valign="center" normalimage="user_1.png" disabledimage="user_2.png"/>
29-
<RichEdit class="simple prompt" name="username" width="stretch" height="auto" margin="10,0,10,0" valign="center" font="2" prompttext="请输入手机号"/>
29+
<RichEdit class="simple prompt" name="username" width="stretch" height="auto" margin="10,0,10,0" valign="center" font="1" prompttextid="STRID_LOGIN_FORM_INPUT_MOBILE"/>
3030
</HBox>
3131
<HBox name="nick_name_panel" height="40" padding="14,1,0,0" visible="false" margin="0,0,0,0">
3232
<Control name="nick_name_icon" width="16" height="16" valign="center" normalimage="nickname.png" disabledimage="nickname.png"/>
3333
<RichEdit class="simple prompt" name="nickname" width="stretch" height="auto" margin="10,0,10,0" valign="center" font="2" prompttextid="STRID_LOGIN_FORM_NICKNAME"/>
3434
</HBox>
3535
<HBox height="41" padding="14,1,5,0">
3636
<Control name="passwordicon" width="16" height="16" valign="center" normalimage="password_1.png" disabledimage="password_2.png"/>
37-
<RichEdit class="simple prompt" name="password" width="110" height="auto" margin="10,0,5,0" valign="center" font="2" prompttext="请输入验证码"/>
38-
<Button name="btn_get_code" width="70" height="30" margin="5,5,5,0" font="0" normaltextcolor="white" text="获取验证码"
39-
normalimage="login0.png" hotimage="login1.png" pushedimage="login2.png"/>
37+
<RichEdit class="simple prompt" name="password" width="110" height="auto" margin="10,0,5,0" valign="center" font="1" prompttextid="STRID_LOGIN_FORM_INPUT_SMS_CODE"/>
38+
<Button name="btn_get_code" width="70" height="30" margin="5,5,5,0" font="0" normaltextcolor="white" textid="STRID_LOGIN_FORM_GET_CODE"
39+
normalimage="login0.png" hotimage="login1.png" pushedimage="login2.png" disabledimage="file='cancel0.png'"/>
4040
</HBox>
4141
</VBox>
4242
</VBox>
@@ -51,7 +51,6 @@
5151
<Event type="select" receiver="chkbox_remember_username" applyattribute="selected=&quot;true&quot;"/>
5252
<Event type="unselect" receiver="chkbox_remember_username" applyattribute="selected=&quot;false&quot;"/>
5353
</CheckBox>
54-
<Control />
5554
<!--Button name="forget_password" cursortype="hand" font="1" normaltextcolor="link_gray" textid="STRID_LOGIN_FORGET_PASSWORD" /-->
5655
</HBox>
5756

bin/resources/themes/default/login/login_en.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
<Control name="passwordicon" width="16" height="16" valign="center" normalimage="password_1.png" disabledimage="password_2.png"/>
3737
<RichEdit class="simple prompt" name="password" width="110" height="auto" margin="10,0,5,0" valign="center" font="1" prompttextid="STRID_LOGIN_FORM_INPUT_SMS_CODE"/>
3838
<Button name="btn_get_code" width="70" height="30" margin="5,5,5,0" font="0" normaltextcolor="white" textid="STRID_LOGIN_FORM_GET_CODE"
39-
normalimage="login0.png" hotimage="login1.png" pushedimage="login2.png"/>
39+
normalimage="login0.png" hotimage="login1.png" pushedimage="login2.png" disabledimage="file='cancel0.png'"/>
4040
</HBox>
4141
</VBox>
4242
</VBox>

conanfile.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def requirements(self):
3131
self.requires("libyuv/1892@yunxin/stable")
3232
self.requires("sqlite3/3.51.0@yunxin/stable")
3333
self.requires("tinyxml/2.6.2@yunxin/stable")
34-
self.requires("nim/10.9.33@yunxin/stable")
34+
self.requires("nim/10.9.72-beta.0@yunxin/stable")
3535
self.requires("nertc/4.1.1@yunxin/stable")
3636
self.requires("libcef/3.2623.1401@yunxin/stable")
3737
self.requires("ne_live_player/1.6.9@yunxin/stable")

nim_win_demo/gui/login/login_form.cpp

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -129,19 +129,19 @@ void LoginForm::OnGetSmsCode()
129129

130130
if (mobile.empty())
131131
{
132-
ShowLoginTip(L"请输入手机号");
132+
ShowLoginTip(MutiLanSupport::GetInstance()->GetStringViaID(L"STRID_LOGIN_FORM_MOBILE_EMPTY"));
133133
return;
134134
}
135135

136136
// 简单的手机号验证
137137
if (mobile.length() != 11)
138138
{
139-
ShowLoginTip(L"请输入正确的手机号");
139+
ShowLoginTip(MutiLanSupport::GetInstance()->GetStringViaID(L"STRID_LOGIN_FORM_MOBILE_INVALID"));
140140
return;
141141
}
142142

143143
btn_get_code_->SetEnabled(false);
144-
btn_get_code_->SetText(L"发送中...");
144+
btn_get_code_->SetText(MutiLanSupport::GetInstance()->GetStringViaID(L"STRID_LOGIN_FORM_SENDING_CODE"));
145145

146146
current_mobile_ = mobile;
147147

@@ -161,23 +161,25 @@ void LoginForm::OnGetSmsCodeCallback(int code, bool is_first_register, const std
161161
{
162162
if (code == 200)
163163
{
164-
ShowLoginTip(L"验证码发送成功");
164+
ShowLoginTip(MutiLanSupport::GetInstance()->GetStringViaID(L"STRID_LOGIN_FORM_CODE_SENT_SUCCESS"));
165165
countdown_seconds_ = 60;
166166
StartCodeCountdown();
167167
}
168168
else
169169
{
170170
btn_get_code_->SetEnabled(true);
171-
btn_get_code_->SetText(L"获取验证码");
171+
btn_get_code_->SetText(MutiLanSupport::GetInstance()->GetStringViaID(L"STRID_LOGIN_FORM_GET_CODE"));
172172

173-
std::wstring error_msg = L"发送验证码失败";
173+
std::wstring error_msg = MutiLanSupport::GetInstance()->GetStringViaID(L"STRID_LOGIN_FORM_CODE_SEND_FAILED");
174174
if (!err_msg.empty())
175175
{
176176
error_msg = nbase::UTF8ToUTF16(err_msg);
177177
}
178178
else
179179
{
180-
error_msg += L" (错误码: " + std::to_wstring(code) + L")";
180+
std::wstring error_code_format =
181+
MutiLanSupport::GetInstance()->GetStringViaID(L"STRID_LOGIN_FORM_ERROR_WITH_CODE");
182+
error_msg += L" (" + nbase::StringPrintf(error_code_format.c_str(), code) + L")";
181183
}
182184
ShowLoginTip(error_msg);
183185
}

0 commit comments

Comments
 (0)