mirror of
https://github.com/ZoiteChat/zoitechat.git
synced 2026-03-15 18:20:20 +00:00
Added a GTK3 version fallback in sexy-spell-entry.c so Windows builds use the GTK3 code paths even when HAVE_GTK3 isn’t defined by config headers.
Avoided MSVC unused-variable warnings in setup.c by scoping GTK2-only locals to GTK2 code paths.
This commit is contained in:
@@ -941,7 +941,10 @@ setup_spin_cb (GtkSpinButton *spin, const setting *set)
|
|||||||
static GtkWidget *
|
static GtkWidget *
|
||||||
setup_create_spin (GtkWidget *table, int row, const setting *set)
|
setup_create_spin (GtkWidget *table, int row, const setting *set)
|
||||||
{
|
{
|
||||||
GtkWidget *label, *wid, *rbox, *align;
|
GtkWidget *label, *wid, *rbox;
|
||||||
|
#if !HAVE_GTK3
|
||||||
|
GtkWidget *align;
|
||||||
|
#endif
|
||||||
char *text;
|
char *text;
|
||||||
|
|
||||||
label = gtk_label_new (_(set->label));
|
label = gtk_label_new (_(set->label));
|
||||||
@@ -1700,8 +1703,8 @@ setup_color_button_apply (GtkWidget *button, const PaletteColor *color)
|
|||||||
GTK_STATE_SELECTED,
|
GTK_STATE_SELECTED,
|
||||||
GTK_STATE_INSENSITIVE
|
GTK_STATE_INSENSITIVE
|
||||||
};
|
};
|
||||||
#endif
|
|
||||||
guint i;
|
guint i;
|
||||||
|
#endif
|
||||||
|
|
||||||
#if HAVE_GTK3
|
#if HAVE_GTK3
|
||||||
gtkutil_apply_palette (apply_widget, color, NULL, NULL);
|
gtkutil_apply_palette (apply_widget, color, NULL, NULL);
|
||||||
|
|||||||
@@ -51,6 +51,14 @@
|
|||||||
#include "xtext.h"
|
#include "xtext.h"
|
||||||
#include "gtkutil.h"
|
#include "gtkutil.h"
|
||||||
|
|
||||||
|
#ifndef HAVE_GTK3
|
||||||
|
#if GTK_MAJOR_VERSION >= 3
|
||||||
|
#define HAVE_GTK3 1
|
||||||
|
#else
|
||||||
|
#define HAVE_GTK3 0
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
#if HAVE_GTK3
|
#if HAVE_GTK3
|
||||||
#define ICON_ADD "list-add"
|
#define ICON_ADD "list-add"
|
||||||
#define ICON_REMOVE "list-remove"
|
#define ICON_REMOVE "list-remove"
|
||||||
|
|||||||
Reference in New Issue
Block a user