aboutsummaryrefslogtreecommitdiffstats
path: root/ui/gtk/capture_if_dlg.c
diff options
context:
space:
mode:
authorJoão Valverde <joao.valverde@tecnico.ulisboa.pt>2015-10-17 13:47:17 +0100
committerAnders Broman <a.broman58@gmail.com>2015-11-12 07:14:32 +0000
commit2d7b0fc7d046154a393c9a1e5f4b2e9b5fee3738 (patch)
tree8b14d373b97ea9162a46e8b61f42919f2a6c5514 /ui/gtk/capture_if_dlg.c
parent1ab019f409f2855d3b51717a237cc482242887e9 (diff)
[GTK] Replace deprecated gdk_pixbuf_new_from_inline()
Use GResource instead, if available. Add autotools and cmake compile time checks for build requirements (GIO >= 2.32 and GDK-Pixbuf >= 2.26). Merge all the various static pixbuf csource header files into a single pixbuf-csource.h header with external linkage through use of the tools/make-pixbuf-csource.pl script. Fix inline pixbuf build target for some image paths (broken for GTK in gb4a4de7). Add missing 'expert_ok.png' file to distribution (GTK only). Minor improvements to style/structure of ui/gtk/Makefile.am. Bug: 10750 Change-Id: I031296b666ee8b92730400dfa6f71f9ee4304863 Reviewed-on: https://code.wireshark.org/review/10992 Petri-Dish: Anders Broman <a.broman58@gmail.com> Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'ui/gtk/capture_if_dlg.c')
-rw-r--r--ui/gtk/capture_if_dlg.c27
1 files changed, 12 insertions, 15 deletions
diff --git a/ui/gtk/capture_if_dlg.c b/ui/gtk/capture_if_dlg.c
index 19f01838e5..0c205ce6b6 100644
--- a/ui/gtk/capture_if_dlg.c
+++ b/ui/gtk/capture_if_dlg.c
@@ -46,6 +46,9 @@
#endif
#include "ui/gtk/stock_icons.h"
+#ifndef HAVE_GRESOURCE
+#include "ui/gtk/pixbuf-csource.h"
+#endif
#include "ui/gtk/capture_dlg.h"
#include "ui/gtk/capture_if_dlg.h"
#include "ui/gtk/gui_utils.h"
@@ -55,8 +58,6 @@
#include "ui/gtk/help_dlg.h"
#include "ui/gtk/keys.h"
#include "ui/gtk/webbrowser.h"
-#include "ui/gtk/network_icons.h"
-#include "ui/gtk/pipe_icon.h"
#include "ui/gtk/main_welcome.h"
#include "ui/gtk/old-gtk-compat.h"
@@ -67,10 +68,6 @@
#include "../../image/toolbar/capture_airpcap_16.xpm"
#endif
-#if defined(HAVE_PCAP_REMOTE)
-#include "ui/gtk/remote_icons.h"
-#endif
-
#include "../../image/toolbar/modem_16.xpm"
#include "../../image/toolbar/network_virtual_16.xpm"
@@ -399,44 +396,44 @@ GtkWidget * capture_get_if_icon(interface_t *device)
{
#ifdef HAVE_PCAP_REMOTE
if (!device->local) {
- return pixbuf_to_widget(remote_sat_pb_data);
+ return PIXBUF_TO_WIDGET(remote_sat_pb_data, "/org/wireshark/image/toolbar/remote_sat_16.png");
}
#endif
if (device->display_name && strstr(device->display_name,"Wi-Fi") != NULL) {
- return pixbuf_to_widget(network_wireless_pb_data);
+ return PIXBUF_TO_WIDGET(network_wireless_pb_data, "/org/wireshark/image/toolbar/network_wireless_16.png");
}
switch (device->type) {
case IF_DIALUP:
return xpm_to_widget(modem_16_xpm);
case IF_WIRELESS:
- return pixbuf_to_widget(network_wireless_pb_data);
+ return PIXBUF_TO_WIDGET(network_wireless_pb_data, "/org/wireshark/image/toolbar/network_wireless_16.png");
#ifdef HAVE_AIRPCAP
case IF_AIRPCAP:
return xpm_to_widget(capture_airpcap_16_xpm);
#endif
case IF_BLUETOOTH:
- return pixbuf_to_widget(network_bluetooth_pb_data);
+ return PIXBUF_TO_WIDGET(network_bluetooth_pb_data, "/org/wireshark/image/toolbar/network_bluetooth_16.png");
case IF_USB:
- return pixbuf_to_widget(network_usb_pb_data);
+ return PIXBUF_TO_WIDGET(network_usb_pb_data, "/org/wireshark/image/toolbar/network_usb_16.png");
case IF_VIRTUAL:
return xpm_to_widget(network_virtual_16_xpm);
case IF_WIRED:
- return pixbuf_to_widget(network_wired_pb_data);
+ return PIXBUF_TO_WIDGET(network_wired_pb_data, "/org/wireshark/image/toolbar/network_wired_16.png");
#ifdef HAVE_EXTCAP
case IF_EXTCAP:
#ifdef _WIN32
if (strncmp(device->friendly_name, "USBPcap", 7) == 0) {
- return pixbuf_to_widget(network_usb_pb_data);
+ return PIXBUF_TO_WIDGET(network_usb_pb_data, "/org/wireshark/image/toolbar/network_usb_16.png");
}
#endif
#endif
case IF_PIPE:
case IF_STDIN:
- return pixbuf_to_widget(pipe_pb_data);
+ return PIXBUF_TO_WIDGET(pipe_pb_data, "/org/wireshark/image/toolbar/pipe_16.png");
default:
printf("unknown device type\n");
}
- return pixbuf_to_widget(network_wired_pb_data);
+ return PIXBUF_TO_WIDGET(network_wired_pb_data, "/org/wireshark/image/toolbar/network_wired_16.png");
}