[simple-scan] Don't ask for saving Pages, if there is nothing to save



commit cd091da824914c63c6698d251c7d3aa39b50ad65
Author: Bartosz Kosiorek <gang65 poczta onet pl>
Date:   Wed Dec 4 01:35:29 2019 +0100

    Don't ask for saving Pages, if there is nothing to save

 src/app-window.vala | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/src/app-window.vala b/src/app-window.vala
index aaa663c..18d6b2d 100644
--- a/src/app-window.vala
+++ b/src/app-window.vala
@@ -688,7 +688,7 @@ public class AppWindow : Gtk.ApplicationWindow
 
     private async bool prompt_to_save_async (string title, string discard_label)
     {
-        if (!book_needs_saving)
+        if (!book_needs_saving || (book.n_pages == 0))
             return true;
 
         var dialog = new Gtk.MessageDialog (this,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]