ENH: GUI: add arm64 check logic for windows

jira: no-jira
Change-Id: Ic788d4ae9218b909eae5ce571d4436c39e77230a
(cherry picked from commit 323184e42c5f85c8738b03b890e5aaf3818e8858)
This commit is contained in:
lane.wei
2025-04-07 20:09:51 +08:00
committed by Noisyfox
parent 7af9802688
commit 320cd87f0b
5 changed files with 49 additions and 1 deletions

View File

@@ -1087,6 +1087,20 @@ GUI_App::GUI_App()
#endif
reset_to_active();
#if defined(__WINDOWS__)
SYSTEM_INFO sysInfo;
GetNativeSystemInfo(&sysInfo);
switch (sysInfo.wProcessorArchitecture) {
case PROCESSOR_ARCHITECTURE_ARM64:
m_is_arm64 = true;
break;
case PROCESSOR_ARCHITECTURE_AMD64:
default:
m_is_arm64 = false;
break;
}
#endif
}
void GUI_App::shutdown()

View File

@@ -238,6 +238,9 @@ private:
#ifdef __linux__
bool m_opengl_initialized{ false };
#endif
#if defined(__WINDOWS__)
bool m_is_arm64{false};
#endif
//#ifdef _WIN32
@@ -583,6 +586,10 @@ public:
std::string get_download_model_url() {return m_mall_model_download_url;}
std::string get_download_model_name() {return m_mall_model_download_name;}
#if defined(__WINDOWS__)
bool is_running_on_arm64() { return m_is_arm64; }
#endif
void load_url(wxString url);
void open_mall_page_dialog();
void open_publish_page_dialog();