examples: fix build on macOS with gtk+-quartz-3.0

gdk_quartz_window_get_nsview is not declared in the header file now:
error: implicit declaration of function 'gdk_quartz_window_get_nsview'
is invalid in C99 [-Werror,-Wimplicit-function-declaration]

fixes #979

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2116>
This commit is contained in:
Zhao Zhili 2021-01-21 16:01:38 +08:00 committed by Tim-Philipp Müller
parent 05ee80f104
commit 28091342da
4 changed files with 16 additions and 0 deletions

View file

@ -11,6 +11,10 @@
#include <gdk/gdkwin32.h>
#elif defined (GDK_WINDOWING_QUARTZ)
#include <gdk/gdkquartz.h>
#if GTK_CHECK_VERSION(3, 24, 10)
#include <AppKit/AppKit.h>
NSView *gdk_quartz_window_get_nsview (GdkWindow * window);
#endif
#endif
/* Structure to contain all our information, so we can pass it around */

View file

@ -33,6 +33,10 @@
#include <gdk/gdkwin32.h>
#elif defined (GDK_WINDOWING_QUARTZ)
#include <gdk/gdkquartz.h>
#if GTK_CHECK_VERSION(3, 24, 10)
#include <AppKit/AppKit.h>
NSView *gdk_quartz_window_get_nsview (GdkWindow * window);
#endif
#endif
#include <gtk/gtk.h>

View file

@ -35,6 +35,10 @@
#endif
#if GST_GL_HAVE_WINDOW_COCOA && defined(GDK_WINDOWING_QUARTZ)
#include <gdk/gdkquartz.h>
#if GTK_CHECK_VERSION(3, 24, 10)
#include <AppKit/AppKit.h>
NSView *gdk_quartz_window_get_nsview (GdkWindow * window);
#endif
#endif
gboolean

View file

@ -41,6 +41,10 @@
#include <gdk/gdkwin32.h>
#elif defined (GDK_WINDOWING_QUARTZ)
#include <gdk/gdkquartz.h>
#if GTK_CHECK_VERSION(3, 24, 10)
#include <AppKit/AppKit.h>
NSView *gdk_quartz_window_get_nsview (GdkWindow * window);
#endif
#endif
#include <gst/video/videooverlay.h>