diff options
| author | Rémi Verschelde | 2018-02-14 16:11:53 +0100 |
|---|---|---|
| committer | GitHub | 2018-02-14 16:11:53 +0100 |
| commit | 7d7f8d9e5439ee95f431503906d1545e28ae9d19 (patch) | |
| tree | b0b1d64bd2f454f754d8b95386ac739004c408d0 /platform/windows/os_windows.cpp | |
| parent | 70294716afe8d8bafb0a81baa2d5525475560fdf (diff) | |
| parent | 5980bef67294e861b25071df76c0169e360a2f76 (diff) | |
| download | godot-7d7f8d9e5439ee95f431503906d1545e28ae9d19.tar.gz godot-7d7f8d9e5439ee95f431503906d1545e28ae9d19.tar.zst godot-7d7f8d9e5439ee95f431503906d1545e28ae9d19.zip | |
Diffstat (limited to 'platform/windows/os_windows.cpp')
| -rw-r--r-- | platform/windows/os_windows.cpp | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp index f4b20b698..5d27fae14 100644 --- a/platform/windows/os_windows.cpp +++ b/platform/windows/os_windows.cpp @@ -2448,6 +2448,24 @@ String OS_Windows::get_user_data_dir() const { return ProjectSettings::get_singleton()->get_resource_path(); } +String OS_Windows::get_unique_id() const { + + HW_PROFILE_INFO HwProfInfo; + ERR_FAIL_COND_V(!GetCurrentHwProfile(&HwProfInfo), ""); + return String(HwProfInfo.szHwProfileGuid); +} + +void OS_Windows::set_ime_position(const Point2 &p_pos) { + + HIMC himc = ImmGetContext(hWnd); + COMPOSITIONFORM cps; + cps.dwStyle = CFS_FORCE_POSITION; + cps.ptCurrentPos.x = p_pos.x; + cps.ptCurrentPos.y = p_pos.y; + ImmSetCompositionWindow(himc, &cps); + ImmReleaseContext(hWnd, himc); +} + bool OS_Windows::is_joy_known(int p_device) { return input->is_joy_mapped(p_device); } |
