[Xfce4-commits] <thunar-vcs-plugin:master> Add a progress message of sorts to svn diff dialog.

Stefan Sperling noreply at xfce.org
Fri Sep 7 13:52:01 CEST 2012


Updating branch refs/heads/master
         to 938e836d61d02c46ea72b861c046b52f555da921 (commit)
       from c3208b715eb062cabccd21d58701ff9dc5a84e67 (commit)

commit 938e836d61d02c46ea72b861c046b52f555da921
Author: Stefan Sperling <stsp at stsp.name>
Date:   Fri Sep 7 13:44:44 2012 +0200

    Add a progress message of sorts to svn diff dialog.
    
    Display "Loading..." while the diff is being generated which can take
    a while on large working copies, especially if the disk cache is cold.

 tvp-svn-helper/tsh-diff-dialog.c |    9 +++++++++
 tvp-svn-helper/tsh-diff-dialog.h |    2 ++
 tvp-svn-helper/tsh-diff.c        |    2 ++
 3 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/tvp-svn-helper/tsh-diff-dialog.c b/tvp-svn-helper/tsh-diff-dialog.c
index 6b01978..92a5672 100644
--- a/tvp-svn-helper/tsh-diff-dialog.c
+++ b/tvp-svn-helper/tsh-diff-dialog.c
@@ -363,3 +363,12 @@ tsh_diff_dialog_get_notice_ancestry (TshDiffDialog *dialog)
 
   return gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (dialog->notice_ancestry));
 }
+
+void
+tsh_diff_dialog_start (TshDiffDialog *dialog)
+{
+  GtkTextBuffer *text_buffer;
+
+  text_buffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(dialog->text_view));
+  gtk_text_buffer_set_text(text_buffer, _("Loading..."), -1);
+}
diff --git a/tvp-svn-helper/tsh-diff-dialog.h b/tvp-svn-helper/tsh-diff-dialog.h
index 7d273a9..20c8c46 100644
--- a/tvp-svn-helper/tsh-diff-dialog.h
+++ b/tvp-svn-helper/tsh-diff-dialog.h
@@ -40,6 +40,8 @@ GtkWidget* tsh_diff_dialog_new       (const gchar *title,
                                        GtkWindow *parent,
                                        GtkDialogFlags flags) G_GNUC_MALLOC G_GNUC_INTERNAL;
 
+void       tsh_diff_dialog_start     (TshDiffDialog *dialog);
+
 void       tsh_diff_dialog_add       (TshDiffDialog *dialog,
                                        const char *line,
                                        gint len);
diff --git a/tvp-svn-helper/tsh-diff.c b/tvp-svn-helper/tsh-diff.c
index 7b6b331..6b05e7e 100644
--- a/tvp-svn-helper/tsh-diff.c
+++ b/tvp-svn-helper/tsh-diff.c
@@ -71,6 +71,8 @@ static gpointer diff_thread (gpointer user_data)
 
   size = files?g_strv_length(files):0;
 
+  tsh_diff_dialog_start(dialog);
+
   subpool = svn_pool_create (pool);
 
   if(size)


More information about the Xfce4-commits mailing list