diff options
author | Guy Harris <guy@alum.mit.edu> | 2000-07-03 08:36:52 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2000-07-03 08:36:52 +0000 |
commit | 9e42b3a4edee724033766982c633e70bc621be87 (patch) | |
tree | 1932df4d63878c2e67a4f415016755d869d3ec60 /ui_util.h | |
parent | 6f4d2c0cb873797918499197c45362535aaab885 (diff) |
Remove the progress bar from the status line, and, instead, for any
potentially long-running operation that has a progress indicator, pop up
a modal dialog box with
an indication of what is being done;
a progress bar;
a "Cancel" button to stop the operation.
This:
leaves more room on the status line for a filter expression;
provides a mechanism to allow the user to cancel long-running
operations (although the way we do so may not back out of them
as nicely as the user might like, if it's not obvious what the
"right" way is or if the "right" way is difficult to implement
or involves doing as much work as letting the operation
continue);
means that, because the dialog box is modal, we don't have to
worry about the user performing arbitrary UI operations out from
under the operation and changing arbitrary bits of state being
used by that operation.
svn path=/trunk/; revision=2103
Diffstat (limited to 'ui_util.h')
-rw-r--r-- | ui_util.h | 27 |
1 files changed, 26 insertions, 1 deletions
@@ -1,7 +1,7 @@ /* ui_util.h * Definitions for UI utility routines * - * $Id: ui_util.h,v 1.4 2000/02/29 06:24:16 guy Exp $ + * $Id: ui_util.h,v 1.5 2000/07/03 08:35:42 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@zing.org> @@ -43,6 +43,31 @@ void reactivate_window(GtkWidget *); /* Destroy all popup packet windows. */ void destroy_packet_wins(void); +/* + * Progress (modal) dialog box routines. + */ + +/* + * Create and pop up the progress dialog; return a pointer to it, as + * a "void *", so that our caller doesn't have to know the GUI + * implementation. + * + * The first argument is the title to give the dialog box; the second + * argument is a pointer to a Boolean variable that will be set to + * TRUE if the user hits the "Cancel" button. + */ +void *create_progress_dlg(gchar *title, gboolean *stop_flag); + +/* + * Set the percentage value of the progress bar. + */ +void update_progress_dlg(void *dlg, gfloat percentage); + +/* + * Destroy the progress bar. + */ +void destroy_progress_dlg(void *dlg); + #ifdef __cplusplus } #endif /* __cplusplus */ |