diff --git a/gfx/src/gtk/nsRenderingContextGTK.h b/gfx/src/gtk/nsRenderingContextGTK.h index 5a302fa6ccc..708a4b384b0 100644 --- a/gfx/src/gtk/nsRenderingContextGTK.h +++ b/gfx/src/gtk/nsRenderingContextGTK.h @@ -44,6 +44,14 @@ #define USE_NATIVE_TILING 1 +#ifndef GTK_CHECK_VERSION +#define GTK_CHECK_VERSION(major,minor,micro) \ + (GTK_MAJOR_VERSION > (major) || \ + (GTK_MAJOR_VERSION == (major) && GTK_MINOR_VERSION > (minor)) || \ + (GTK_MAJOR_VERSION == (major) && GTK_MINOR_VERSION == (minor) && \ + GTK_MICRO_VERSION >= (micro))) +#endif + class nsFontGTK; class nsRenderingContextGTK : public nsRenderingContextImpl @@ -243,7 +251,7 @@ private: GdkFunction mFunction; GdkLineStyle mLineStyle; // gtk+ 1.2.7 introduces an incompatible API change -#if defined(GTK_CHECK_VERSION) && GTK_CHECK_VERSION(1,2,7) +#if GTK_CHECK_VERSION(1,2,7) gint8 mDashList[2]; #else gchar mDashList[2];