diff -urN gtk+2.0-2.18.5.orig/debian/changelog gtk+2.0-2.18.5/debian/changelog --- gtk+2.0-2.18.5.orig/debian/changelog 2009-12-18 15:01:06.000000000 -0800 +++ gtk+2.0-2.18.5/debian/changelog 2009-12-18 15:06:53.000000000 -0800 @@ -1,3 +1,9 @@ +gtk+2.0 (2.18.5-1.1) unstable; urgency=low + + * Allow inheriting GDK_NATIVE_WINDOWS. + + -- Petr Vandrovec Fri, 18 Dec 2009 15:06:48 -0800 + gtk+2.0 (2.18.5-1) unstable; urgency=low * New upstream bugfix release. diff -urN gtk+2.0-2.18.5.orig/gdk/gdk.c gtk+2.0-2.18.5/gdk/gdk.c --- gtk+2.0-2.18.5.orig/gdk/gdk.c 2009-12-18 15:01:06.000000000 -0800 +++ gtk+2.0-2.18.5/gdk/gdk.c 2009-12-18 15:05:57.000000000 -0800 @@ -187,6 +187,8 @@ void gdk_pre_parse_libgtk_only (void) { + char *nativeWindows; + gdk_initialized = TRUE; /* We set the fallback program class here, rather than lazily in @@ -206,12 +208,16 @@ } #endif /* G_ENABLE_DEBUG */ - if (getenv ("GDK_NATIVE_WINDOWS")) + nativeWindows = getenv ("GDK_NATIVE_WINDOWS"); + if (nativeWindows) { _gdk_native_windows = TRUE; /* Ensure that this is not propagated - to spawned applications */ - g_unsetenv ("GDK_NATIVE_WINDOWS"); + to spawned applications unless 'inherit' is used */ + if (strcmp (nativeWindows, "inherit")) + { + g_unsetenv ("GDK_NATIVE_WINDOWS"); + } } g_type_init ();