aboutsummaryrefslogtreecommitdiffstats
path: root/gtk
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2001-12-31 20:40:34 +0000
committerGerald Combs <gerald@wireshark.org>2001-12-31 20:40:34 +0000
commite8839785ad4073dbb2838888a21a976c20ba8276 (patch)
tree665ddb309cc496226b09b5d7a24e8dadd4962605 /gtk
parent30c5551caa87a95fcbe75dd9df654ffd8464f305 (diff)
Fix a pointer error in find_stat_node.
Define a default width and maximum height for the stats dialog. svn path=/trunk/; revision=4463
Diffstat (limited to 'gtk')
-rw-r--r--gtk/proto_hier_stats_dlg.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/gtk/proto_hier_stats_dlg.c b/gtk/proto_hier_stats_dlg.c
index 1bc3163ade..c5536016bf 100644
--- a/gtk/proto_hier_stats_dlg.c
+++ b/gtk/proto_hier_stats_dlg.c
@@ -1,6 +1,6 @@
/* proto_hier_stats_dlg.c
*
- * $Id: proto_hier_stats_dlg.c,v 1.6 2001/12/31 04:41:50 gerald Exp $
+ * $Id: proto_hier_stats_dlg.c,v 1.7 2001/12/31 20:40:34 gerald Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@zing.org>
@@ -113,6 +113,8 @@ fill_in_ctree(GtkWidget *tree, ph_stats_t *ps)
fill_in_ctree_node, &di);
}
+#define MAX_DLG_HEIGHT 450
+#define DEF_DLG_WIDTH 600
static void
create_tree(GtkWidget *container, ph_stats_t *ps)
{
@@ -158,7 +160,8 @@ create_tree(GtkWidget *container, ph_stats_t *ps)
fill_in_ctree(tree, ps);
height = GTK_CLIST(tree)->rows * (GTK_CLIST(tree)->row_height + 5);
- gtk_widget_set_usize(tree, 500, height);
+ height = MIN(height, MAX_DLG_HEIGHT);
+ gtk_widget_set_usize(tree, DEF_DLG_WIDTH, height);
gtk_container_add(GTK_CONTAINER(sw), tree);