summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2023-01-13 00:10:48 +0000
committerMatthias Clasen <mclasen@redhat.com>2023-01-13 00:10:48 +0000
commit434d8ef0ea356f5be60aa1f167ec34da29f973d9 (patch)
tree34ed51af94c422bff6cc21c67538d966015357e9
parent31a6d7363533e5cab1337a37f3d61aefa4727ee0 (diff)
parent958ecf285522082a8023eb03bfccadd1975f1dd8 (diff)
downloadgtk+-434d8ef0ea356f5be60aa1f167ec34da29f973d9.tar.gz
Merge branch 'wip/chergert/fix-macos-warnings' into 'main'
Fixes a few compilation warnings on macOS See merge request GNOME/gtk!5415
-rw-r--r--gdk/gdkdisplay.c2
-rw-r--r--gdk/macos/gdkmacoscursor.c4
-rw-r--r--gsk/gl/gskgldriver.c2
3 files changed, 6 insertions, 2 deletions
diff --git a/gdk/gdkdisplay.c b/gdk/gdkdisplay.c
index 66216a4401..34b0f014c1 100644
--- a/gdk/gdkdisplay.c
+++ b/gdk/gdkdisplay.c
@@ -1777,11 +1777,11 @@ gdk_display_init_egl (GdkDisplay *self,
gpointer
gdk_display_get_egl_display (GdkDisplay *self)
{
+#ifdef HAVE_EGL
GdkDisplayPrivate *priv = gdk_display_get_instance_private (self);
g_return_val_if_fail (GDK_IS_DISPLAY (self), NULL);
-#ifdef HAVE_EGL
if (!priv->egl_display &&
!gdk_display_prepare_gl (self, NULL))
return NULL;
diff --git a/gdk/macos/gdkmacoscursor.c b/gdk/macos/gdkmacoscursor.c
index cf571a9a11..64b328850f 100644
--- a/gdk/macos/gdkmacoscursor.c
+++ b/gdk/macos/gdkmacoscursor.c
@@ -23,6 +23,10 @@
#include "gdkmacoscursor-private.h"
+@interface NSCursor()
+-(long long)_coreCursorType;
+@end
+
/* OS X only exports a number of cursor types in its public NSCursor interface.
* By overriding the private _coreCursorType method, we can tell OS X to load
* one of its internal cursors instead (since cursor images are loaded on demand
diff --git a/gsk/gl/gskgldriver.c b/gsk/gl/gskgldriver.c
index 71ebf73ef8..3d58ee71e0 100644
--- a/gsk/gl/gskgldriver.c
+++ b/gsk/gl/gskgldriver.c
@@ -184,7 +184,7 @@ gsk_gl_driver_shader_weak_cb (gpointer data,
}
}
-G_GNUC_NULL_TERMINATED static inline GBytes *
+G_GNUC_UNUSED G_GNUC_NULL_TERMINATED static inline GBytes *
join_sources (GBytes *first_bytes,
...)
{