@LiquidCake commented on this pull request.


In plugins/saveactions.c:

> +
+	new_file_path_utf8 = DOC_FILENAME(doc);
+	old_file_path_utf8 = plugin_get_document_data(geany_plugin, doc, "file-name-before-save-as");
+
+	if (old_file_path_utf8 != NULL)
+	{
+		if (is_persistent_untitled_doc_file(old_file_path_utf8)
+			&& ! g_str_equal(old_file_path_utf8, new_file_path_utf8))
+		{
+			/* remove untitled doc file if it was saved as some other file */
+			gchar *locale_old_file_path = utils_get_locale_from_utf8(old_file_path_utf8);
+			g_remove(locale_old_file_path);
+
+			g_free(locale_old_file_path);
+
+			ui_set_statusbar(TRUE, _("Untitled document file %s was deleted"), old_file_path_utf8);

done


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <geany/geany/pull/3911/review/2452516225@github.com>