FIX: imgui textinput cannot paste on macos

jira: STUDIO-5070、STUDIO-5365

Change-Id: Iea8f41e12744ecda0fbb95c1a8f2e014a7cdc384
This commit is contained in:
liz.li 2023-11-27 10:54:20 +08:00 committed by Lane.Wei
parent 5a581fcf16
commit 5011621ad8

View File

@ -2501,12 +2501,12 @@ void ImGuiWrapper::destroy_fonts_texture() {
const char* ImGuiWrapper::clipboard_get(void* user_data)
{
ImGuiWrapper *self = reinterpret_cast<ImGuiWrapper*>(user_data);
ImGuiWrapper* self = reinterpret_cast<ImGuiWrapper*>(user_data);
const char* res = "";
if (wxTheClipboard->Open()) {
if (wxTheClipboard->IsSupported(wxDF_TEXT)) {
if (wxTheClipboard->IsSupported(wxDF_TEXT) || wxTheClipboard->IsSupported(wxDF_UNICODETEXT)) {
wxTextDataObject data;
wxTheClipboard->GetData(data);