diff options
author | guy <guy@f5534014-38df-0310-8fa8-9805f1628bb7> | 1999-07-28 03:29:02 +0000 |
---|---|---|
committer | guy <guy@f5534014-38df-0310-8fa8-9805f1628bb7> | 1999-07-28 03:29:02 +0000 |
commit | 4c5b99ff167b4eb46a14bca7f75ca1b5185003e0 (patch) | |
tree | fd5c732c7824276a6a9f9e023bd4f28b67b7bc61 /column.c | |
parent | 6e7e537b2e2f84d4690e137deb357f442c2941b2 (diff) |
Have:
COL_INFO columns resize automatically even during a live
capture;
columns showing network addresses never resize automatically;
other columns resize only when a capture is done;
and make all columns resizeable by hand (once they've resized, for
auto-resizeable columns).
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@394 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'column.c')
-rw-r--r-- | column.c | 56 |
1 files changed, 55 insertions, 1 deletions
@@ -1,7 +1,7 @@ /* column.c * Routines for handling column preferences * - * $Id: column.c,v 1.19 1999/07/23 08:29:23 guy Exp $ + * $Id: column.c,v 1.20 1999/07/28 03:29:00 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@zing.org> @@ -233,6 +233,60 @@ get_column_width(gint format, GdkFont *font) { } } +enum col_resize_type +get_column_resize_type(gint format) { + switch (format) { + case COL_NUMBER: + case COL_CLS_TIME: + case COL_ABS_TIME: + case COL_REL_TIME: + case COL_DELTA_TIME: + case COL_DEF_SRC_PORT: + case COL_RES_SRC_PORT: + case COL_UNRES_SRC_PORT: + case COL_DEF_DST_PORT: + case COL_RES_DST_PORT: + case COL_UNRES_DST_PORT: + case COL_PROTOCOL: + case COL_PACKET_LENGTH: + /* We don't want these to resize during a live capture, as that + gets in the way of trying to look at the data while it's being + captured. */ + return (RESIZE_AUTO); + break; + case COL_DEF_SRC: + case COL_RES_SRC: + case COL_UNRES_SRC: + case COL_DEF_DL_SRC: + case COL_RES_DL_SRC: + case COL_UNRES_DL_SRC: + case COL_DEF_NET_SRC: + case COL_RES_NET_SRC: + case COL_UNRES_NET_SRC: + case COL_DEF_DST: + case COL_RES_DST: + case COL_UNRES_DST: + case COL_DEF_DL_DST: + case COL_RES_DL_DST: + case COL_UNRES_DL_DST: + case COL_DEF_NET_DST: + case COL_RES_NET_DST: + case COL_UNRES_NET_DST: + /* We don't want these to resize dynamically; if they get resolved + to names, those names could be very long, and auto-resizing + columns showing those names may leave too little room for + other columns such as the "Info" column. */ + return (RESIZE_MANUAL); + break; + default: /* COL_INFO */ + /* We want this to resize dynamically, even during a live capture, + because otherewise you won't be able to see all that's in + it. */ + return (RESIZE_LIVE); + break; + } +} + #define TIME_DEF 0 #define TIME_REL 1 #define TIME_ABS 2 |