When reloading a file with ctrl+R don't display the warning dialog
that the unsaved changes might be lost when the file has not been
modified.
Signed-off-by: Jiří Techet <[email protected]>
---
src/callbacks.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/src/callbacks.c b/src/callbacks.c
index cd6e53e..f973570 100644
--- a/src/callbacks.c
+++ b/src/callbacks.c
@@ -485,7 +485,8 @@ on_reload_as_activate (GtkMenuItem *menuitem,
charset = doc->encoding;
base_name = g_path_get_basename(doc->file_name);
- if (dialogs_show_question_full(NULL, _("_Reload"), GTK_STOCK_CANCEL,
+ if (!doc->changed ||
+ dialogs_show_question_full(NULL, _("_Reload"), GTK_STOCK_CANCEL,
_("Any unsaved changes will be lost."),
_("Are you sure you want to reload '%s'?"), base_name))
{
_______________________________________________
Geany-devel mailing list
[email protected]
http://lists.uvena.de/cgi-bin/mailman/listinfo/geany-devel