Commit Graph

117 Commits

Author SHA1 Message Date
Ulf Lamping 6a5b1e0ec0 use the ending "_win32" for every windows specific file
svn path=/trunk/; revision=24972
2008-04-13 12:14:57 +00:00
Ulf Lamping 644a474c95 sort #includes by directories
svn path=/trunk/; revision=24969
2008-04-13 03:32:24 +00:00
Ulf Lamping 55c2be83db move stock icon code from toolbar.c into specific stock_icons file(s)
svn path=/trunk/; revision=24921
2008-04-12 00:49:20 +00:00
Stephen Fisher 3702095876 Add a cast to fix compilation on Unix.
svn path=/trunk/; revision=24919
2008-04-11 23:46:06 +00:00
Ulf Lamping 8e58ec7085 last round to replace SIGNAL_CONNECT with g_signal_connect
svn path=/trunk/; revision=24918
2008-04-11 23:16:06 +00:00
Ulf Lamping 1ab5a1ea4b replace RADIO_BUTTON_NEW_WITH_MNEMONIC with gtk_radio_button_new_with_mnemonic_from_widget
svn path=/trunk/; revision=24908
2008-04-11 19:26:22 +00:00
Ulf Lamping 4de04eae27 replace CHECK_BUTTON_NEW_WITH_MNEMONIC with gtk_check_button_new_with_mnemonic
svn path=/trunk/; revision=24905
2008-04-11 19:04:34 +00:00
Ulf Lamping ae5f841083 replace all appearances of BUTTON_NEW_FROM_STOCK with GTK2's gtk_button_new_from_stock
svn path=/trunk/; revision=24904
2008-04-11 18:58:19 +00:00
Bill Meier b5309506a4 OBECT_..._DATA --> g_object_..._data
svn path=/trunk/; revision=24892
2008-04-11 15:41:51 +00:00
Ulf Lamping 3b7fe5fc6c remove GTK1 code
svn path=/trunk/; revision=24823
2008-04-07 00:42:04 +00:00
Stig Bjørlykke 5800abad46 From Francesco Fondelli (bug 2349):
Attached is a patch to export packets data as "C Arrays".  I often have
the need to [re]send data captured with wireshark using a raw/pf_packet socket.
Output format is one char[] per packet, it looks like almost the same as
the one produced by "Follow TCP stream".

svn path=/trunk/; revision=24604
2008-03-11 18:23:16 +00:00
Ulf Lamping 05bedd5d0f add some file dialog related help pages
use file related instead of print related help pages for the export dialogs

svn path=/trunk/; revision=19089
2006-08-30 20:27:12 +00:00
Ulf Lamping 321316861e bugfix: open the Win32 print dialog a second time resulted in "funny" behaviour
printing on Win32 uses the print to file "option", don't overwrite the internal settings while doing so

svn path=/trunk/; revision=18631
2006-07-01 12:11:11 +00:00
Anders Broman 05448fcc3d Ethereal->Wireshark
svn path=/trunk/; revision=18232
2006-05-28 17:19:08 +00:00
Guy Harris 92552c2d76 Get rid of a bunch of "Ethereal"s and "ethereal"s in comments, GUI
strings, and function names.

svn path=/trunk/; revision=18205
2006-05-22 07:29:40 +00:00
Ronnie Sahlberg 89f022b12b name change
svn path=/trunk/; revision=18197
2006-05-21 05:12:17 +00:00
Guy Harris 84aef00bad Move the file selection dialog routines to file_dlg.c, and give it a
header file.

#if 0 out some includes; if none of the builds have a problem with
that, I'll remove them.

svn path=/trunk/; revision=18036
2006-04-30 01:47:58 +00:00
Guy Harris 0ce9a23b25 Most of the stuff in file_dlg.c is specific to capture files, so rename
it to capture_file_dlg.c, and rename its header file.  We might want to
move the generic file dialog stuff to a file_dlg.c file (it's currently
in dlg_utils.c), and move the non-capture-file dialog stuff in
capture_file_dlg.c to another file.

svn path=/trunk/; revision=18034
2006-04-29 23:03:57 +00:00
Ulf Lamping 82f80a6daa add missing #include "tempfile.h"
svn path=/trunk/; revision=17289
2006-02-13 22:10:42 +00:00
Gerald Combs 80e5e0fb15 Copy over the file open/save code from the Win32 native branch.
The Windows-native routines were integrated by inserting

#if GTK_MAJOR_VERSION >= 2 && _WIN32
  win32_native_routine(GDK_WINDOW_HWND(top_level->window));
  return;
#endif

at the beginning of each GTK+ file routine.  There's probably a prettier
way to do this.

Some of the sizes need to be tweaked in win32-file-dlg.rc, but everything
seems to work.

Fix up whitespace.

svn path=/trunk/; revision=17285
2006-02-13 21:25:43 +00:00
Ulf Lamping b847af543d fix #358: instead of simply using tpmnam() for the Win32 print function, use the "official" function to create a temporary file
Well, we actually only need the filename here, so create a temp file with the "official" create_tempfile function, keep that tempfile name and then delete this file again, leaving only the name.

I know that's a bit uncommon, but should work and uses the same mechanisms as with other temporary files. So if there are still problems with the official function, we only have one place to fix :-)

svn path=/trunk/; revision=16597
2005-11-26 01:56:22 +00:00
Ulf Lamping c3187174bf replace *a lot* of file related calls by their GLib counterparts. This is necessary for the switch to GTK 2.6 (at least on WIN32).
to do this, I've added file_util.h to wiretap (would file_compat.h be a better name?), and provide compat_macros like eth_open() instead of open(). While at it, move other file related things there, like #include <io.h>, definition of O_BINARY and alike, so it's all in one place.

deleted related things from config.h.win32

As of these massive changes, I'm almost certain that this will break the Unix build. I'll keep an eye on the buildbot so hopefully everything is working again soon.

svn path=/trunk/; revision=16403
2005-11-06 22:43:25 +00:00
Jörg Mayer 0edcc8920e - Declare some functions static
- Add plugins_dlg.h
- Include .h files in their respective .c files
- Include .h and remove extern declarations in .c files
- set eol-style and keywords on gui_utils.[hc]

svn path=/trunk/; revision=15471
2005-08-20 14:02:00 +00:00
Ulf Lamping eafbbbcabb renamed ui_util.c/.h to gui_utils.c/.h to prevent confusion with identical named ui_util.h in / dir
svn path=/trunk/; revision=15465
2005-08-20 12:09:48 +00:00
Jörg Mayer 4e1f4b18ab More char -> const char warning fixes.
Removed (very few) casts that only change the warning message
  but don't remove it (with gcc-4).

svn path=/trunk/; revision=15227
2005-08-05 20:59:08 +00:00
Ulf Lamping 801e9dd35e from Stefano Pettini: add CSV export function, similar to PSML export
svn path=/trunk/; revision=13724
2005-03-11 20:56:31 +00:00
Guy Harris 2c89242aac Instead of having a single enumerated type for status return values from
cf_ functions, have separate ones for different classes of routines, and
use gboolean when the return value is just "success" or "failure" - that
way you don't get compiler warnings if a case statement isn't handling a
particular status value if the routine in question won't return it.

svn path=/trunk/; revision=13293
2005-02-04 20:54:12 +00:00
Ulf Lamping 0861927ce3 huge cleanup of capture file API (functions in file.c/file.h).
This includes: all functions in file.h now have a cf_ prefix, will have doxygen tags, will have the capture_file *cf as the first parameter and I tried to generalize the return values for non trivial functions.

Hopefully, I didn't introduced any new bugs, as I had to change a lot of files...

svn path=/trunk/; revision=13289
2005-02-04 18:44:44 +00:00
Ulf Lamping 5c19161dc2 if context menu item "Print" is clicked from the packet list context menu, it should use the selected range setting as default. As we currently have only one packet selectable, this will print only this one.
If we would allow selecting multiple packets in the packet list in the future, this option would print all selected packets.

svn path=/trunk/; revision=13169
2005-01-24 19:33:47 +00:00
Ulf Lamping 66ce7f3623 add some more online help functionality and help buttons at various dialog boxes, if a help page *is* available. However, the new help system needs a lot more work before completed.
svn path=/trunk/; revision=13152
2005-01-20 23:17:23 +00:00
Guy Harris 0f039d5245 From Brett Kuskie: recalculate the ranges every time an export dialog is
opened, not just the first time, so that if the packet counts change
up-to-date values are displayed.

svn path=/trunk/; revision=12813
2004-12-22 09:19:01 +00:00
Guy Harris 727ad67453 Remove the fixed maximum number of subranges in a range_t; dynamically
allocate them to be large enough.

Add checks that the numbers in the range fit in a guint32.

Check the validity of a range before saving or printing, and report
errors in an alert box.

Clean up white space.

svn path=/trunk/; revision=12320
2004-10-16 23:32:24 +00:00
Guy Harris 2398487dc2 For file browsing dialog boxes, the affirmative button should be "OK",
not "Save".

In UN*X with GTK+ 2.x, put the affirmative button in file dialogs to the
right of the cancel button, as is done with other dialogs.

svn path=/trunk/; revision=12146
2004-09-30 02:02:35 +00:00
Guy Harris bbe7f89742 Move prefs.c and prefs.h into the epan subdirectory.
svn path=/trunk/; revision=12115
2004-09-27 22:55:15 +00:00
Guy Harris 999867b710 Move the code to open the printer/print file from "print_packets()" to
"print_ok_cb()", and have "print_packets()" just work on a
"print_stream_t" handed to it, so that different platforms can open the
printer/print file in different ways (opening the file is probably not
going to be platform-dependent, but opening the printer will be).

svn path=/trunk/; revision=11544
2004-07-27 20:10:02 +00:00
Guy Harris 8a8b883450 Set the svn:eol-style property on all text files to "native", so that
they have LF at the end of the line on UN*X and CR/LF on Windows;
hopefully this means that if a CR/LF version is checked in on Windows,
the CRs will be stripped so that they show up only when checked out on
Windows, not on UN*X.

svn path=/trunk/; revision=11400
2004-07-18 00:24:25 +00:00
Guy Harris b650d01031 Make the "human-readable text vs. PSML vs. PDML" choice separate from
the "text vs.  PostScript" choice.  The "text vs. PostScript" choice
should probably ultimately be done with a generic set of print methods,
to handle various platform-native print mechanisms more cleanly (and
perhaps the dialog box code for "export as {PDML,PSML}" should be
separate from the "export as text"/"print" dialog).

svn path=/trunk/; revision=11342
2004-07-08 10:36:29 +00:00
Jörg Mayer 4bbb32eaaa The patch to fix the race condition introduced by using tmpnam replaced
insecure code by not-working code.  As I currently lack the time to fix
this properly until Monday as the earliest possible date I undo the patch.

Please note that Ethereal should not be used on multiuser systems with
untrusted users until a proper fix has been applied.

svn path=/trunk/; revision=11263
2004-06-29 03:27:52 +00:00
Jörg Mayer 0195deceae tmpnam() really should not be used for security reasons.
Replace it where used and update README.developer accordingly.

svn path=/trunk/; revision=11235
2004-06-25 07:04:03 +00:00
Ulf Lamping 778158c965 win_printer is gboolean, not an int
svn path=/trunk/; revision=11024
2004-05-27 21:52:07 +00:00
Ulf Lamping 7d37fc9d23 more code cleanup from dialog things:
changed window_xy (dialog) function calling in a lot of gtk files
cleanup of file selection code
cleanup in dlg_utils/file_dlg/ui_util
Please report any problems!!!

svn path=/trunk/; revision=11003
2004-05-26 03:49:24 +00:00
Ulf Lamping 0d74ec909c removed some labels
svn path=/trunk/; revision=10705
2004-04-25 22:34:06 +00:00
Guy Harris 047c8af10a Squelch a compiler warning.
svn path=/trunk/; revision=10700
2004-04-25 21:46:19 +00:00
Ulf Lamping 014052caf9 created new "export" dialogs for the current export file formats
svn path=/trunk/; revision=10694
2004-04-25 16:04:13 +00:00
Ulf Lamping 895375603d put all required data into the print_args,
instead of confusing seperation of data

svn path=/trunk/; revision=10692
2004-04-25 12:04:08 +00:00
Ulf Lamping afecdb8461 changed the print dialog, so it will keep the user settings after reopening the dialog
and some code cleanup

svn path=/trunk/; revision=10685
2004-04-25 08:01:06 +00:00
Ulf Lamping 1531315c18 some code cleanup of the printing system
svn path=/trunk/; revision=10682
2004-04-24 23:13:46 +00:00
Ulf Lamping 50533286e2 oops, forgotten to test with GTK1...
svn path=/trunk/; revision=10666
2004-04-22 21:40:48 +00:00
Ulf Lamping 3b86a98d53 seperated common packet range code from the save and the print dialog,
and put it into new range_utils files. This will avoid:
a) duplicate code in save and print dialog and
b) yet another code duplication for future dialogs (export, ...)

svn path=/trunk/; revision=10665
2004-04-22 21:31:09 +00:00
Ulf Lamping 51f987e04f added some options and enhancements to the print output:
-ps: added formatting hints for ghostscript, so pdf conversion will be much better
-ps: print a thin line at the top and bottom of each page
-ps/text: add an option to start a new page for every packet (formfeed)

svn path=/trunk/; revision=10660
2004-04-22 17:03:21 +00:00