From 1dc96f1e50fad6d68ef1d27aa44ef25a9652db38 Mon Sep 17 00:00:00 2001 From: Thomas Martitz Date: Wed, 21 May 2014 08:11:37 +0200 Subject: [PATCH] infobars: Cancel "reload file" dialog when spawning the "resave file" one. When the file was deleted from disk the message that the file is newer on disk has become out of date and irrelevent. --- src/document.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/document.c b/src/document.c index 14c031d2..8c7b13db 100644 --- a/src/document.c +++ b/src/document.c @@ -3206,6 +3206,9 @@ static void monitor_resave_missing_file(GeanyDocument *doc) if (doc->priv->info_bars[MSG_TYPE_RESAVE] == NULL) { GtkWidget *bar; + bar = doc->priv->info_bars[MSG_TYPE_RELOAD]; + if (bar != NULL) /* the "file on disk is newer" warning is now moot */ + gtk_info_bar_response(GTK_INFO_BAR(bar), GTK_RESPONSE_CANCEL); bar = document_show_message(doc, GTK_MESSAGE_WARNING, on_monitor_resave_missing_file_response,