From df195188bc68b48d20f584b9fd29a65ac5b567e9 Mon Sep 17 00:00:00 2001 From: Karol Kosek Date: Sat, 25 Sep 2021 22:02:48 +0200 Subject: [PATCH] PixelPaint: Close New Image dialog after pressing return key 13e526de43847ac86d74e3cb0be2d6b930f1d46f added the feature to new Layer dialog. This patch adds it to Image dialog to stay consistent across the app. :^) --- Userland/Applications/PixelPaint/CreateNewImageDialog.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Userland/Applications/PixelPaint/CreateNewImageDialog.cpp b/Userland/Applications/PixelPaint/CreateNewImageDialog.cpp index 51aa608c3c..3d8d925293 100644 --- a/Userland/Applications/PixelPaint/CreateNewImageDialog.cpp +++ b/Userland/Applications/PixelPaint/CreateNewImageDialog.cpp @@ -65,6 +65,10 @@ CreateNewImageDialog::CreateNewImageDialog(GUI::Window* parent_window) m_image_size.set_height(value); }; + m_name_textbox->on_return_pressed = [this] { + done(ExecOK); + }; + width_spinbox.set_range(1, 16384); height_spinbox.set_range(1, 16384);