aboutsummaryrefslogtreecommitdiffstats
path: root/ui/gtk/prefs_dlg.c
AgeCommit message (Collapse)AuthorFilesLines
2014-04-29prefs: spelling fix, simplify codePeter Wu1-19/+10
Found spelling error "a another". All those dynamic allocations and magic numbers are horrible and unnecessary. Simplify the gtk code rewording the message and merging strings. Simplify the version code by using fscanf to take care of matching the first line of a preference file. Change-Id: I1e75803aacaa494ba5005791bcbd023e0807aaaa Reviewed-on: https://code.wireshark.org/review/1424 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-03-11Migrate GTK icon handling to GTK 3.10 APIBalint Reczey1-2/+2
GtkStockItem usage is deprecated with all the GTK_STOCK_.* stock ids. We keep a stock id based approach but without relying on GTK's GtkStockItem system. We create our own internal stock ids for {icon, label} tuples and keep the original GTK stock id #define-s and values to preserve backward compatibility. Change-Id: Ia0b35a5903f079e92c8026e3df21bbf0be2d06b0 Reviewed-on: https://code.wireshark.org/review/302 Reviewed-by: Gerald Combs <gerald@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-03-04Remove all $Id$ from top of fileAlexis La Goutte1-2/+0
(Using sed : sed -i '/^ \* \$Id\$/,+1 d') Fix manually some typo (in export_object_dicom.c and crc16-plain.c) Change-Id: I4c1ae68d1c4afeace8cb195b53c715cf9e1227a8 Reviewed-on: https://code.wireshark.org/review/497 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-02-25Remove trailing whitespaceBill Meier1-4/+4
Change-Id: I8116f63ff88687c8db3fd6e8e23b22ab2f759af0 Reviewed-on: https://code.wireshark.org/review/385 Reviewed-by: Bill Meier <wmeier@newsguy.com> Tested-by: Bill Meier <wmeier@newsguy.com>
2013-12-10Do not show uat preferences if not registered for the gui.Irene Rüngeler1-3/+4
svn path=/trunk/; revision=53904
2013-12-03When including <epan/prefs.h> don't force inclusion of <epan/uat.h>Jakub Zawadzki1-0/+1
svn path=/trunk/; revision=53769
2013-10-09Prefix all "Wireshark application specific" display filters with a "_ws." to ↵Michael Mann1-2/+2
distinguish them from dissector filters. This was committed now to get it into the 1.11 release so users can start getting used to the changed filter names. svn path=/trunk/; revision=52462
2013-07-18Fix errors :Alexis La Goutte1-9/+9
prefs_dlg.c:1395:69: error: unused parameter ‘parent_w’ [-Werror=unused-parameter] prefs_dlg.c:1414:19: error: initialization discards ‘const’ qualifier from pointer target type [-Werror] prefs_dlg.c:1415:19: error: initialization discards ‘const’ qualifier from pointer target type [-Werror] prefs_dlg.c:1417:19: error: initialization discards ‘const’ qualifier from pointer target type [-Werror] prefs_dlg.c:1418:19: error: initialization discards ‘const’ qualifier from pointer target type [-Werror] prefs_dlg.c:1419:19: error: initialization discards ‘const’ qualifier from pointer target type [-Werror] prefs_dlg.c:1427:7: error: format not a string literal and no format arguments [-Werror=format-security] prefs_dlg.c:1432:7: error: format not a string literal and no format arguments [-Werror=format-security] svn path=/trunk/; revision=50724
2013-07-18From Cal Turney:Anders Broman1-5/+54
Unrecognized preferences and color filters created in proprietary or older versions are discarded when saved. If the user attempts to save the preferences or colorfilters file, a popup is displayed that warns that unrecognized prefs or color filters have been detected and will be discarded if the save operation is allowed to proceed. In the case of Preferences, the popup message includes the version at which the file was last saved. A "Continue without Saving" button is provided so that the user can save the profile under a different name. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8942 svn path=/trunk/; revision=50716
2013-07-17Backing out r50690 (exept simple_dialog)Anders Broman1-54/+5
struct FILE is different on windows vs *nix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8942 svn path=/trunk/; revision=50691
2013-07-17From Cal Turney:Anders Broman1-5/+54
Unrecognized preferences and color filters created in proprietary or older versions are discarded when saved. If the user attempts to save the preferences or colorfilters file, a popup is displayed that warns that unrecognized prefs or color filters have been detected and will be discarded if the save operation is allowed to proceed. In the case of Preferences, the popup message includes the version at which the file was last saved. A "Continue without Saving" button is provided so that the user can save the profile under a different name. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8942 svn path=/trunk/; revision=50690
2013-07-12Move the print modules into epan.Jeff Morriss1-1/+1
svn path=/trunk/; revision=50526
2013-05-29Fix and clarify name resolution preference tooltips. Print theGerald Combs1-3/+4
description before the name+type since that's presumably what people are looking for. svn path=/trunk/; revision=49622
2013-03-24Redissect extra packet windows in all cases (that I know of) where weEvan Huus1-0/+5
redissect normal packet list. Fixes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8482 svn path=/trunk/; revision=48528
2013-03-21From beroset:Bill Meier1-55/+55
remove C++ incompatibilities https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416 attachment #10404 Note: The following parts of the patch had been previously done: asn1/snmp/packet-snmp-template.c epan/dissectors/packet-snmp.c epan/dissectors/packet-x11.c Also; hostlist_table.c: code under '#ifdef HAVE_GEOIP' didn't compile and needed a few additional patches. svn path=/trunk/; revision=48447
2013-03-13gtk_widget_set_vexpand() is only for GTK3.Bill Meier1-0/+2
svn path=/trunk/; revision=48281
2013-03-13Certain prefs window contents should not be centered vertically in GTK3.Bill Meier1-1/+2
(Fix: prevent vertical expand/fill of grid widget in certain cases). (This stuff in GTK3 about "parents inheriting expand/fill properties from children" is driving me crazy). svn path=/trunk/; revision=48280
2013-03-04Fir Gtk 3.8 & newer: gtk_scrolled_window_add_with_viewport() ==> ↵Bill Meier1-0/+8
gtk_container_add(). svn path=/trunk/; revision=48065
2013-02-25it's ==> its & its ==> it's as needed.Bill Meier1-1/+1
In a few cases: Fix spelling; Clean up whitespace and formatting style. svn path=/trunk/; revision=47889
2013-02-08Add a directory name preference type (PREF_DIRNAME) and registrationGerald Combs1-9/+29
routine (prefs_register_directory_preference). Add PREF_FILENAME and PREF_DIRNAME support to the Qt module preferences. Change a couple of preferences to directory names. Clean up some names and default settings. svn path=/trunk/; revision=47573
2013-01-24Use ws_gtk_grid...() in place of gtk_table...().Bill Meier1-55/+47
This completes the process of replacing Wireshark gtk_table...() usage !! (However: the prefs dialogs still have a few Gtk3 related Expand/Fill issues which need to be fixed). svn path=/trunk/; revision=47262
2013-01-18Fix compilation on Windows.Gerald Combs1-0/+8
svn path=/trunk/; revision=47140
2013-01-18Rename the "saved_val" preference element to "stashed_val" in order toGerald Combs1-229/+18
more clearly indicate that it's a copy of a preference value rather than something we've saved in the preferences file. Update prefs_pref_to_str() to handle default, stashed, and current prefs. Create ui/preference_utils.[ch] and move some common routines there. Use prefs_pref_type_name() in the GTK+ preferences dialog. Make the "OK" button in the Qt preferences dialog work. We simply write the prefs and redissect on "OK" and do nothing on "Cancel". This is intentionally different from the Apply/OK/Cancel behavior in the GTK+ version. Add a general "emitAppSignal" method to wsApp and use it for packet dissection and preference changes. Suggest that we might want to create a WsString class to make conversion between QStrings, gchar *s, and GStrings easier. svn path=/trunk/; revision=47139
2013-01-03Move the font preferences to the colors pane and change its name toGerald Combs1-35/+17
"Font and Colors". Use a GtkFontButton to select the font and update the sample text accordingly. Instead of attempting to resize the sample color text (which didn't appear to work) scroll to the text that matches the current combo box selection. svn path=/trunk/; revision=46909
2013-01-01Use scrolled-windows to enclose "custom" prefs pages (User Interface, ↵Bill Meier1-2/+11
Layout, etc) in the same manner as to "protocol prefs" pages. This ensures that the bottom row buttons won't disappear off the bottom of the prefs window if one (or more) of the custom prefs pages is too large to fit vertically within the available screen space. In Wireshark 1.8, more items were added to the "User Interface" prefs page thus leading to an increased possibility of this issue occurring. I believe this fixes Bug #8078. #Backport Wireshark 1.8 svn path=/trunk/; revision=46885
2012-12-26Fix a bunch of warnings.Guy Harris1-1/+1
Cast away some implicit 64-bit-to-32-bit conversion errors due to use of sizeof. Cast away some implicit 64-bit-to-32-bit conversion errors due to use of strtol() and strtoul(). Change some data types to avoid those implicit conversion warnings. When assigning a constant to a float, make sure the constant isn't a double, by appending "f" to the constant. Constify a bunch of variables, parameters, and return values to eliminate warnings due to strings being given const qualifiers. Cast away those warnings in some cases where an API we don't control forces us to do so. Enable a bunch of additional warnings by default. Note why at least some of the other warnings aren't enabled. randpkt.c and text2pcap.c are used to build programs, so they don't need to be in EXTRA_DIST. If the user specifies --enable-warnings-as-errors, add -Werror *even if the user specified --enable-extra-gcc-flags; assume they know what they're doing and are willing to have the compile fail due to the extra GCC warnings being treated as errors. svn path=/trunk/; revision=46748
2012-12-15From Masatake Yamato, adding preference names used with -o option to tooltip ↵Michael Mann1-9/+40
text. Bug 6641 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6641) svn path=/trunk/; revision=46545
2012-11-25Fix several [-Wshadow] warnings;Bill Meier1-66/+65
Also: Do some minor whitespace and formatting changes. svn path=/trunk/; revision=46183
2012-11-05Try to fix prefs_dlg.c:1814: warning: 'abbrev' may be used uninitialized in ↵Anders Broman1-5/+2
this function. svn path=/trunk/; revision=45919
2012-11-05From Michal Labedzki:Anders Broman1-8/+40
Add Preferences submenu to packet list menu Preferences point to protocol which is on top expect "malformed", "text" and "expert" fields. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7754 svn path=/trunk/; revision=45914
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss1-3/+1
svn path=/trunk/; revision=45016
2012-09-03cinfo.columns_changed is only used by ui/gtk, move it to cfile structure.Jakub Zawadzki1-1/+1
svn path=/trunk/; revision=44750
2012-08-08Have (almost) all preferences use the generic preferences API (per ↵Michael Mann1-16/+0
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7402). This cleaned up a lot of hardcoded code and allows breaking up the prefs structure (or at least prevent it from growing too large) if desired. Bugfixed problems mentioned in http://www.wireshark.org/lists/wireshark-dev/201208/msg00001.html Column preferences now support default '#' character svn path=/trunk/; revision=44348
2012-08-08Base framework to allow all preferences to be part of generic preferences ↵Michael Mann1-0/+63
API. Implementation will follow, but I wanted the framework in place first. svn path=/trunk/; revision=44331
2012-08-03Fix a typo.Jeff Morriss1-1/+1
svn path=/trunk/; revision=44251
2012-08-03(Attempt to) avoid using capture_page uninitialized when we don't HAVE_LIBPCAP.Jeff Morriss1-3/+6
svn path=/trunk/; revision=44250
2012-08-03Make the columns of the capture options dialog selectable. Changes are ↵Irene Rüngeler1-4/+9
stored in the preferences file. The ordering can be changed by dragging the column. The order is not stored. svn path=/trunk/; revision=44239
2012-07-20gtk_container_add() -> gtk_box_pack_start() [bug #7377]Jakub Zawadzki1-3/+3
svn path=/trunk/; revision=43874
2012-07-07Only one place is needed for creating preference panes; this clears upGuy Harris1-93/+43
some warnings from GTK+. For interior nodes in the preference module tree, we create a page even if the module itself has no preferences, so there's *something* we can show if the user clicks on it. (Showing the top-level protocols page is a bit weird, and requires us to keep track of it.) svn path=/trunk/; revision=43596
2012-07-07Uniformly use two-space indents (most of the file uses it).Guy Harris1-31/+31
svn path=/trunk/; revision=43593
2012-07-06From Michael Mann:Anders Broman1-21/+0
Generic preferences implementation - Printing and Name Resolution. svn path=/trunk/; revision=43579
2012-06-28Update Free Software Foundation address.Jakub Zawadzki1-1/+1
(COPYING will be updated in next commit) svn path=/trunk/; revision=43536
2012-06-25Get rid of a couple of unused variables and parameters.Jeff Morriss1-3/+2
svn path=/trunk/; revision=43486
2012-06-25From Michael Mann:Anders Broman1-66/+89
generic preferences implementation https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7402 svn path=/trunk/; revision=43484
2012-06-19Revert:Anders Broman1-1/+1
airpcap_tb -> wireless_tb Second try. svn path=/trunk/; revision=43364
2012-06-13Create, and start using, file name preferences.Jeff Morriss1-1/+57
File name preferences are basically just string preferences except that the GUI will present a "Browse" button that allows the user to go and find the file s/he wants (rather than having to blindly type in the full path). svn path=/trunk/; revision=43228
2012-06-02From Evan Huus Convert a bunch more GTK-2 calls to their cross-version ws_ ↵Anders Broman1-5/+5
equivalent svn path=/trunk/; revision=43009
2012-04-23Use GtkFontChooser if GTK >= 3.2Anders Broman1-2/+4
svn path=/trunk/; revision=42205
2012-01-16Move some headers for UI stuff, and the alert_box.c UI-specific file, toGuy Harris1-1/+1
the ui directory. (Perhaps some other files that would be used by all flavors of Wireshark, for any GUI toolkit or for someting such as ncurses, and not for any command-line tool such as TShark, should be moved there as well.) Shuffle some #includes to put the "ui/XXX.h" includes together. svn path=/trunk/; revision=40529
2012-01-15Move gtk to ui/gtk.Jörg Mayer1-0/+1834
This looses the last checkin to gtk, will add this manually back. svn path=/trunk/; revision=40518