aboutsummaryrefslogtreecommitdiffstats
path: root/gtk/simple_dialog.c
AgeCommit message (Collapse)AuthorFilesLines
2005-09-20enhance simple dialog: add the possibility to use no buttons at all and add ↵Ulf Lamping1-3/+22
a stop icon (similar to the splash_window, but with a slightly different layout and a way to choose the icon shown) svn path=/trunk/; revision=15886
2005-08-20renamed ui_util.c/.h to gui_utils.c/.h to prevent confusion with identical ↵Ulf Lamping1-1/+1
named ui_util.h in / dir svn path=/trunk/; revision=15465
2005-08-08fix some MSVC const warningsUlf Lamping1-2/+2
svn path=/trunk/; revision=15263
2005-04-16temporarily fix a GTK1.x related bugUlf Lamping1-0/+3
svn path=/trunk/; revision=14108
2005-04-16prepare for "Don't show this message again" checkboxes in the simple_dialogUlf Lamping1-2/+29
svn path=/trunk/; revision=14100
2004-07-18Set the svn:eol-style property on all text files to "native", so thatGuy Harris1-1/+1
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-13From Daniel Thompson: add additional message/alert box options toGuy Harris1-2/+16
display "Save", "Continue without Saving", and "Cancel", for the "do you want to save?" messages. svn path=/trunk/; revision=11372
2004-06-29GTK2: convert character encoding from locale to UTF8Ulf Lamping1-2/+11
before displaying message svn path=/trunk/; revision=11274
2004-06-18merge: bugfixes and code cleanupUlf Lamping1-1/+4
svn path=/trunk/; revision=11175
2004-06-17add implementation of button mask ESD_BTNS_YES_NOUlf Lamping1-7/+14
svn path=/trunk/; revision=11170
2004-06-04Make the definition of "simple_dialog()" match its declaration.Guy Harris1-3/+3
Make the "type" argument to "vsimple_dialog()" also be an ESD_TYPE_E. svn path=/trunk/; revision=11112
2004-05-26more code cleanup from dialog things:Ulf Lamping1-13/+5
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-17GTK2 only: catch window state event, and call display_queued_messages()Ulf Lamping1-16/+7
if window not iconified any longer. Queue up simple_dialog messages, if window *is* iconified svn path=/trunk/; revision=10914
2004-05-16don't show simple_dialogs, if main window iconified (minimized),Ulf Lamping1-1/+25
this would lead to an unresponsive program. Simply discard the messages, as we don't have a way to queue and show this message if the main window is becoming "visible" again. svn path=/trunk/; revision=10910
2004-05-01The display filter engine can return an error message that is not safeOlivier Biot1-1/+20
when using GTK2 code for rendering the error. In order to correctly render the error message, it must be XML escaped. TODO: track down the remaining places where this XML escaping is required, and fix it there too (not sure if they exist though). svn path=/trunk/; revision=10764
2004-04-16Add a "report_failure()" routine to allow dissectors to report arbitraryGuy Harris1-30/+86
errors to the user. Use that, rather than "g_warning()", in the Diameter dissector to report errors reading the dictionary. Make the format argument to "simple_dialog()" a "const" pointer. Fix up the read-error message in Tethereal to end with a newline. If a simple dialog is requested before the main window or the capture-control window is popped up, queue it up and pop the queued messages up once the main or capture-control window is displayed. svn path=/trunk/; revision=10616
2004-03-13replaced vsnprintf by g_vsnprintfUlf Lamping1-2/+2
svn path=/trunk/; revision=10374
2004-03-13replaced sprintf / snprintf by g_snprintf,Ulf Lamping1-5/+1
various other string related changes svn path=/trunk/; revision=10373
2004-02-23Put in a comment noting a problem with dialog boxes popped up before theGuy Harris1-1/+9
main window is popped up. svn path=/trunk/; revision=10193
2004-02-12The HIG's and/or GUI toolkit documentation for:Guy Harris1-4/+3
Mac OS X GNOME Qt KDE Windows all indicate that {message,alert} boxes are modal, at least for the window to which they apply. (Presumably the idea is that not forcing the user to pay attention to the alert box, and allowing more than one alert box to be up for a given window, causes more problems than not letting the user do stuff to that window in order to figure out what the underlying problem is or figure out what to do to fix it - the message should be sufficient, in most if not all cases, to let you know what the problem is.) Make "simple_dialog()" unconditionally make the alert box modal, and get rid of ESD_TYPE_MODAL. XXX - we need to make it possible to make an alert box modal for a given window, rather than just the top-level window. svn path=/trunk/; revision=10051
2004-02-11Get rid of the "Question" alert box type - rename it to "Confirmation",Guy Harris1-4/+3
as that seems to be the name used in the GNOME HIG, at least. Make it use the Warning icon (that's what the GNOME HIG says - and it's also what's used for the equivalent on Windows), and use it for the "Save current capture?" alert boxes. svn path=/trunk/; revision=10030
2004-02-11Give alert boxes an empty title on UN*X and a title of "Ethereal" onGuy Harris1-9/+39
Win32, to match the GNOME HIG on UN*X and the Win32 HIG on Windows (or, at least, to approximate the Win32 HIG on Windows). svn path=/trunk/; revision=10029
2004-02-04Add some comments about the types of alert boxes you get with theGuy Harris1-4/+3
simple_dialog routines (which are really just message box/alert box routines). Add some macros for combinations of buttons (corresponding to combinations that some GUI toolkits, which only support some combinations, allow). svn path=/trunk/; revision=9977
2004-02-03enhanced some dialog messages,Ulf Lamping1-1/+13
close capture file when user told so svn path=/trunk/; revision=9965
2004-01-31gtk_label_set_selectable() is only available from GTK version 2Ulf Lamping1-2/+2
svn path=/trunk/; revision=9923
2004-01-31cleanup of new "question dialogs",Ulf Lamping1-23/+43
using GTK2 primary/secondary message text from GNOME HIG for simple_dialogs, added a "question dialog" for the coloring rules "Clear" button svn path=/trunk/; revision=9921
2004-01-31Pass ESD_BTN_OK rather than NULL as a second argument toGuy Harris1-2/+3
"simple_dialog()"; NULL might be #defined to be a pointer expression on some platforms, causing compiler warnings (and, on platforms where a null pointer doesn't have all its bits 0, possibly causing misbehavior, although I don't think there are any such platforms on which Ethereal runs). Don't allow 0 as button mask argument to "simple_dialog()". Squelch a compiler warning. Report fatal problems as errors, not warnings. Report file I/O errors with "file_open_error_message()". Report file write errors (including those reported by "close()", e.g. some errors writing to an NFS server) when saving raw packet data to a file. svn path=/trunk/; revision=9915
2004-01-31renamed ESD_TYPE_CRIT to ESD_TYPE_ERROR toUlf Lamping1-2/+2
better reflect the real error text svn path=/trunk/; revision=9913
2004-01-31using GTK2 stock icons for dialogs instead of Ethereal specific onesUlf Lamping1-11/+10
svn path=/trunk/; revision=9911
2004-01-29added "Yes" and "No" buttons to the simple_dialog,Ulf Lamping1-30/+68
added a callback method, to be called if a button was pressed svn path=/trunk/; revision=9907
2004-01-21implemented dlg_button_row_new to get a standard function forUlf Lamping1-17/+14
layouting the dialog buttons, and use it where appropriate. This will help us with the GTK1/2 conflict on button layouts and will also result in a more consistent look of the dialogs at all. svn path=/trunk/; revision=9771
2004-01-10using button compatibility macrosUlf Lamping1-11/+3
svn path=/trunk/; revision=9636
2002-11-11Use gtk1/gtk2 compatibility macros to reduce #ifdefs.Olivier Abad1-12/+6
svn path=/trunk/; revision=6610
2002-11-03Merge gtk and gtk2 directories.Olivier Abad1-3/+16
svn path=/trunk/; revision=6552
2002-09-05Include cleanups in gtk and gtk2:Jörg Mayer1-4/+1
Remove unneded includes Add include wrappers where missing svn path=/trunk/; revision=6191
2002-08-28Removed trailing whitespaces from .h and .c files using theJörg Mayer1-11/+11
winapi_cleanup tool written by Patrik Stridvall for the wine project. svn path=/trunk/; revision=6117
2002-06-04From Graeme Hewson: varargs code cleanup in "simple_dialog.c".Guy Harris1-1/+2
svn path=/trunk/; revision=5617
2002-03-05From Joerg Mayer: use _U_ to flag unused arguments.Guy Harris1-2/+2
svn path=/trunk/; revision=4878
2001-12-12Go nuts with the 3D logo.Gerald Combs1-6/+6
Add a routine to ui_util.c that sets a window's icon pixmap to a 16x16 version of the 3D logo. Call the routine for each window that is created. This has been tested with kwm and Sawfish (which expect a 16x16 icon), but we may have to come up with a better solution for other window managers (e.g. olwm and mwm). Add a 3D exclamation point image. Replace the exclamation point and Ethereal logo images used in simple_dialog() with their 3D counterparts. Remove the old icons from the source distribution. svn path=/trunk/; revision=4390
2000-10-09Add support for modal message boxes ("simple dialog").Guy Harris1-2/+5
Make the message boxes popped up for errors when selecting a font modal, so that the user has to say "yes, I know, I'll do better next time" before hitting "OK" again, so that you don't get a pile of message boxes. svn path=/trunk/; revision=2485
2000-08-23Bleah. What was I thinking? "dlg_window_new()" should take the titleGuy Harris1-7/+6
for the dialog window as an argument (as various dialog creators in GTK+ do), not oblige every caller of it to cut-and-paste a "gtk_window_set_title()" call after it. svn path=/trunk/; revision=2345
2000-08-11Miscellaneous code cleaningLaurent Deniel1-6/+1
- add <stdarg.h> or <varargs.h> in snprintf.h and remove those inclusions in the other #ifdef NEED_SNPRINTF_H codes - remove the check of multiple inclusions in source (.c) code (there is a bit loss of _cpp_ performance, but I prefer the gain of code reading and maintenance; and nowadays, disk caches and VM are correctly optimized ;-). - protect all (well almost) header files against multiple inclusions - add header (i.e. GPL license) in some include files - reorganize a bit the way header files are included: First: #include <system_include_files> #include <external_package_include_files (e.g. gtk, glib etc.)> Then #include "ethereal_include_files" with the correct HAVE_XXX or NEED_XXX protections. - add some HAVE_XXX checks before including some system header files - add the same HAVE_XXX in wiretap as in ethereal Please forgive me, if I break something (I've only compiled and regression tested on Linux). svn path=/trunk/; revision=2254
2000-07-20Use ESD_TYPE_CRIT for most errors (the model used by various GUIs seemsGuy Harris1-2/+2
to use "warning" dialog boxes only to warn the user "if you do that, bad things may happen" *and* to offer them the option either to drive on or quit, so perhaps ESD_TYPE_CRIT should be used for all errors). However, put "Ethereal: Error" rather than "Ethereal: Critical" in the title bar, in the hopes that it'll make it clearer that Something Bad Happened. If the user specifies that captures should be saved to a user-specified file rather than a temporary file, report errors trying to create that file with "file_open_error_message()". Make the "for_writing" argument to "file_open_error_message()" a "gboolean", as it's either TRUE (if the file is being opened for writing) or FALSE (if it's being opened for reading). Report EISDIR as "XXX is a directory (folder), not a file.". svn path=/trunk/; revision=2143
2000-07-05Add a "dlg_window_new()" routine, which creates a GTK_WINDOW_DIALOGGuy Harris1-4/+4
window and makes it transient for the top-level window; the transient-for at least provides a hint to X window managers to minimize the dialog if the main window is minimized; keep the dialog on top of the main window in the Z order for windows; perhaps (if there are any window managers that actually *do* this) even put it atop the main window in the X-Y plane (KWM doesn't and I seem to remember that the Exceed X server for Windows doesn't). It's generally considered the Right Thing To Do for dialog boxes. Use that routine to create dialog boxes, rather than doing it directly in the code for that dialog box. svn path=/trunk/; revision=2112
2000-05-03Make dialog boxes created with "simple_dialog()" use the new utilitiesGuy Harris1-1/+12
to make the Esc key cancel the dialog box (or accept it, if it has no "Cancel" button). svn path=/trunk/; revision=1905
2000-01-03Take the "simple_dialog()" stuff out of "ui_util.h" and "gtk/ui_util.c",Guy Harris1-0/+169
and move it to "simple_dialog.h" and "gtk/simple_dialog.c". svn path=/trunk/; revision=1414