From 0142d33d5c50879744ea3a04039007672cf13a33 Mon Sep 17 00:00:00 2001 From: Gauvain 'GovanifY' Roussel-Tarbouriech Date: Thu, 4 Mar 2021 00:08:11 +0100 Subject: [PATCH] IPC: make dialog close when pressing enter --- pcsx2/gui/Dialogs/IPCDialog.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/pcsx2/gui/Dialogs/IPCDialog.cpp b/pcsx2/gui/Dialogs/IPCDialog.cpp index 66ab0ccc4b..a6377287c6 100644 --- a/pcsx2/gui/Dialogs/IPCDialog.cpp +++ b/pcsx2/gui/Dialogs/IPCDialog.cpp @@ -43,9 +43,6 @@ Dialogs::IPCDialog::IPCDialog(wxWindow* parent) wxTextCtrl* ipc_slot = new wxTextCtrl(this, wxID_ANY, wxString::Format(wxT("%u"), IPCSettings::slot), wxDefaultPosition, wxDefaultSize, wxTE_PROCESS_ENTER); ipc_slot->Bind(wxEVT_TEXT_ENTER, &Dialogs::IPCDialog::OnConfirm, this); - wxButton* confirm = new wxButton(this, wxID_OK); - confirm->SetDefault(); - *this += new wxStaticText(this, wxID_ANY, _("IPC Slot")); *this += ipc_slot; *this += confirm; @@ -57,5 +54,6 @@ void Dialogs::IPCDialog::OnConfirm(wxCommandEvent& evt) if (textbox) { IPCSettings::slot = (unsigned int)atoi(textbox->GetValue().ToUTF8().data()); + Destroy(); } }