From 1c52ca9693eee5d48bc26da6290c14c18811f228 Mon Sep 17 00:00:00 2001 From: Roberto Bampi Date: Sun, 21 Aug 2022 22:41:06 +0200 Subject: [PATCH] PixelPaint: Push layer creation onto the undo stack Before this change, creating a layer, painting something on it and undoing would delete the layer as well as the paint on it. --- Userland/Applications/PixelPaint/MainWidget.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/Userland/Applications/PixelPaint/MainWidget.cpp b/Userland/Applications/PixelPaint/MainWidget.cpp index 0f3b4f4f01..b3f070f7a3 100644 --- a/Userland/Applications/PixelPaint/MainWidget.cpp +++ b/Userland/Applications/PixelPaint/MainWidget.cpp @@ -567,6 +567,7 @@ void MainWidget::initialize_menubar(GUI::Window& window) } editor->image().add_layer(layer_or_error.release_value()); editor->layers_did_change(); + editor->did_complete_action("New Layer"sv); m_layer_list_widget->select_top_layer(); } }));