mirror of
https://github.com/whoahq/whoa.git
synced 2026-02-02 00:32:45 +03:00
feat(ui): implement Script_CancelRealmListQuery (#109)
Co-authored-by: fallenoak <git@fallenoak.me>
This commit is contained in:
parent
046575fb98
commit
26f2255f53
@ -89,6 +89,16 @@ float CalculateAspectRatio() {
|
|||||||
return static_cast<float>(width) / static_cast<float>(height);
|
return static_cast<float>(width) / static_cast<float>(height);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void CGlueMgr::CancelRealmListQuery() {
|
||||||
|
if (CGlueMgr::m_idleState != IDLE_REALM_LIST) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
ClientServices::Connection()->Cancel(2);
|
||||||
|
|
||||||
|
CGlueMgr::SetIdleState(IDLE_NONE);
|
||||||
|
}
|
||||||
|
|
||||||
void CGlueMgr::ChangeRealm(const REALM_INFO* realmInfo) {
|
void CGlueMgr::ChangeRealm(const REALM_INFO* realmInfo) {
|
||||||
if (!realmInfo) {
|
if (!realmInfo) {
|
||||||
return;
|
return;
|
||||||
|
|||||||
@ -58,6 +58,7 @@ class CGlueMgr {
|
|||||||
static int32_t m_suspended;
|
static int32_t m_suspended;
|
||||||
|
|
||||||
// Static functions
|
// Static functions
|
||||||
|
static void CancelRealmListQuery();
|
||||||
static void ChangeRealm(const REALM_INFO* realmInfo);
|
static void ChangeRealm(const REALM_INFO* realmInfo);
|
||||||
static void DisplayLoginStatus();
|
static void DisplayLoginStatus();
|
||||||
static void EnterWorld();
|
static void EnterWorld();
|
||||||
|
|||||||
@ -19,7 +19,9 @@ int32_t Script_RealmListUpdateRate(lua_State* L) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
int32_t Script_CancelRealmListQuery(lua_State* L) {
|
int32_t Script_CancelRealmListQuery(lua_State* L) {
|
||||||
WHOA_UNIMPLEMENTED(0);
|
CGlueMgr::CancelRealmListQuery();
|
||||||
|
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int32_t Script_GetNumRealms(lua_State* L) {
|
int32_t Script_GetNumRealms(lua_State* L) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user