changeset 337:5f9d5aee0c1c

2003-12-10 Brian Masney <masneyb@gftp.org> * src/gtk/gftp-gtk.c src/gtk/menu-items.c src/gtk/misc-gtk.c - check for a timeout from the remote server when refreshing the directory listing and changing directores. If it did, reconnect to the server.
author masneyb
date Sat, 13 Dec 2003 20:36:39 +0000
parents e0c22c0d9106
children 0f34108f27b7
files ChangeLog src/gtk/gftp-gtk.c src/gtk/menu-items.c src/gtk/misc-gtk.c
diffstat 4 files changed, 18 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Sat Dec 13 19:26:27 2003 +0000
+++ b/ChangeLog	Sat Dec 13 20:36:39 2003 +0000
@@ -1,4 +1,8 @@
 2003-12-10 Brian Masney <masneyb@gftp.org>
+	* src/gtk/gftp-gtk.c src/gtk/menu-items.c src/gtk/misc-gtk.c - check
+	for a timeout from the remote server when refreshing the directory
+	listing and changing directores. If it did, reconnect to the server.
+
 	* lib/rfc2068.c - set the default file attributes to -rw-r--r-- for
 	all files.
 
@@ -1830,7 +1834,7 @@
 
 	* cvsclean - added this script
 
-	* *.[ch] - added $Id: ChangeLog,v 1.183 2003/12/13 19:26:21 masneyb Exp $ tags
+	* *.[ch] - added $Id: ChangeLog,v 1.184 2003/12/13 20:36:37 masneyb Exp $ tags
 
 	* debian/* - updated files from Debian maintainer
 
--- a/src/gtk/gftp-gtk.c	Sat Dec 13 19:26:27 2003 +0000
+++ b/src/gtk/gftp-gtk.c	Sat Dec 13 20:36:39 2003 +0000
@@ -141,6 +141,8 @@
     doexit (widget, data);
 }
 
+/* This function is only here because the callback function cannot have a
+   return value and chdir_dialog() does */
 
 static void
 chfunc (gpointer data)
@@ -507,6 +509,9 @@
   dir = tempfle->isdir;
   success = 0;
 
+  if (check_reconnect (wdata) < 0) 
+    return;
+
   if (tempfle->islink || tempfle->isdir)
     success = chdir_dialog (wdata);
 
--- a/src/gtk/menu-items.c	Sat Dec 13 19:26:27 2003 +0000
+++ b/src/gtk/menu-items.c	Sat Dec 13 20:36:39 2003 +0000
@@ -479,6 +479,10 @@
 
   wdata = data;
   edttxt = gtk_entry_get_text (GTK_ENTRY (GTK_COMBO (wdata->combo)->entry));
+
+  if (check_reconnect (wdata) < 0)
+    return (0);
+
   if (!GFTP_IS_CONNECTED (wdata->request) && *edttxt != '\0')
     {
       toolbar_hostedit (NULL, NULL);
--- a/src/gtk/misc-gtk.c	Sat Dec 13 19:26:27 2003 +0000
+++ b/src/gtk/misc-gtk.c	Sat Dec 13 20:36:39 2003 +0000
@@ -210,6 +210,10 @@
 {
   if (!check_status (_("Refresh"), wdata, 0, 0, 0, 1))
     return;
+
+  if (check_reconnect (wdata) < 0) 
+    return;
+
   gtk_clist_freeze (GTK_CLIST (wdata->listbox));
   remove_files_window (wdata);
   gftp_delete_cache_entry (wdata->request, NULL, 0);