Removed GTK2/GTK3 dual-path preprocessor branches across src/fe-gtk by keeping GTK3-native paths only, including the high-density targets you prioritized (xtext.c, setup.c, maingui.c, gtkutil.c, servlistgui.c).

Removed GTK2 compatibility shims from headers (fe-gtk.h, gtkutil.h), leaving direct GTK3-facing declarations/includes only (and platform-specific guards unrelated to GTK2 kept as-is).

Cleaned GTK2-specific comments/wording now that behavior is GTK3-native (menu accelerator note and emoji/userlist comment blocks).
This commit is contained in:
2026-02-22 15:11:35 -07:00
parent 8b344e8bfe
commit 1c5bf9d6b1
33 changed files with 6 additions and 2060 deletions

View File

@@ -31,7 +31,6 @@
#include "menu.h"
#include "gtkutil.h"
#if HAVE_GTK3
#include <gio/gio.h>
#if defined(GTK_DISABLE_DEPRECATED)
typedef struct _GtkStatusIcon GtkStatusIcon;
@@ -43,7 +42,6 @@ typedef struct _GtkStatusIcon GtkStatusIcon;
#include <libappindicator/app-indicator.h>
#endif
#endif
#endif
#define ICON_TRAY_PREFERENCES "zc-menu-preferences"
#define ICON_TRAY_QUIT "zc-menu-quit"
@@ -70,7 +68,7 @@ typedef enum
WS_HIDDEN
} WinStatus;
#if HAVE_GTK3 && !defined(WIN32) && (defined(HAVE_AYATANA_APPINDICATOR) || defined(HAVE_APPINDICATOR))
#if !defined(WIN32) && (defined(HAVE_AYATANA_APPINDICATOR) || defined(HAVE_APPINDICATOR))
#define HAVE_APPINDICATOR_BACKEND 1
#else
#define HAVE_APPINDICATOR_BACKEND 0
@@ -109,7 +107,7 @@ typedef GdkPixbuf* TrayCustomIcon;
#define ICON_HILIGHT pix_tray_highlight
#define ICON_FILE pix_tray_fileoffer
#endif
#if HAVE_GTK3 && defined(GTK_DISABLE_DEPRECATED) && !HAVE_APPINDICATOR_BACKEND
#if defined(GTK_DISABLE_DEPRECATED) && !HAVE_APPINDICATOR_BACKEND
GtkStatusIcon *gtk_status_icon_new_from_pixbuf (GdkPixbuf *pixbuf);
void gtk_status_icon_set_from_pixbuf (GtkStatusIcon *status_icon, GdkPixbuf *pixbuf);
void gtk_status_icon_set_tooltip_text (GtkStatusIcon *status_icon, const gchar *text);
@@ -1098,7 +1096,7 @@ tray_menu_populate (GtkWidget *menu)
mg_create_icon_item (_("_Quit"), ICON_TRAY_QUIT, menu, tray_menu_quit_cb, NULL);
}
#if HAVE_GTK3 && !defined(WIN32)
#if !defined(WIN32)
static void
tray_menu_clear (GtkWidget *menu)
{