diff --git a/src/app/commands/cmd_new_layer.cpp b/src/app/commands/cmd_new_layer.cpp index 06ec3122c..100969b04 100644 --- a/src/app/commands/cmd_new_layer.cpp +++ b/src/app/commands/cmd_new_layer.cpp @@ -143,6 +143,10 @@ void NewLayerCommand::onExecute(Context* context) static_cast(context) ->setActiveDocument(oldActiveDocument); } + // If the user didn't selected a new document, it means that the + // file selector dialog was canceled. + else + return; } // If params specify to ask the user about the name...