+2009-02-18 Sven Neumann <sven@gimp.org>
+
+ Bug 533456 – Memory leak when window is destroyed
+
+ * gdk/directfb/gdkdirectfb.h
+ * gdk/directfb/gdkprivate-directfb.h
+ * gdk/directfb/gdkcursor-directfb.c
+ * gdk/directfb/gdkevents-directfb.c
+ * gdk/directfb/gdkwindow-directfb.c: removed all #ifdef checks for
+ DIRECTFB_MAJOR_VERSION >= 1. We depend on DirectFB >= 1.0.0 now.
+ Fixes a potential build issue that would lead to a memory leak as
+ described in bug #533456.
+
2009-02-18 Sven Neumann <sven@gimp.org>
Bug 513422 – Unknown meaning of translatable messages
#include <directfb_version.h>
-#if DIRECTFB_MAJOR_VERSION < 1
-#define u32 __u32
-#define u8 __u8
-#endif
static struct {
const guchar *bits;
IDirectFBWindow *gdk_directfb_window_lookup(GdkWindow *window);
IDirectFBSurface *gdk_directfb_surface_lookup(GdkWindow *window);
-#if (DIRECTFB_MAJOR_VERSION >= 1)
GdkWindow *gdk_directfb_create_child_window(GdkWindow *parent,
- IDirectFBSurface *subsurface);
-#endif
+ IDirectFBSurface *subsurface);
G_END_DECLS
impl->window->CreateEventBuffer (impl->window, &EventBuffer);
}
-#if (DIRECTFB_MAJOR_VERSION >= 1)
void
gdk_directfb_event_windows_remove (GdkWindow *window)
{
impl->window->DetachEventBuffer (impl->window, EventBuffer);
/* FIXME: should we warn if (! EventBuffer) ? */
}
-#endif
GdkWindow *
gdk_directfb_child_at (GdkWindow *window,
gint width,
gint height);
-void gdk_directfb_event_windows_add (GdkWindow *window);
-#if (DIRECTFB_MAJOR_VERSION >= 1)
+void gdk_directfb_event_windows_add (GdkWindow *window);
void gdk_directfb_event_windows_remove (GdkWindow *window);
-#endif
GdkGrabStatus gdk_directfb_keyboard_grab (GdkDisplay *display,
GdkWindow *window,
impl = GDK_WINDOW_IMPL_DIRECTFB (private->impl);
_gdk_selection_window_destroyed (window);
-#if (DIRECTFB_MAJOR_VERSION >= 1)
gdk_directfb_event_windows_remove (window);
-#endif
+
if (window == _gdk_directfb_pointer_grab_window)
gdk_pointer_ungrab (GDK_CURRENT_TIME);
if (window == _gdk_directfb_keyboard_grab_window)
* Given a directfb window and a subsurface of that window
* create a gdkwindow child wrapper
*/
-#if (DIRECTFB_MAJOR_VERSION >= 1)
GdkWindow *gdk_directfb_create_child_window(GdkWindow *parent,
- IDirectFBSurface *subsurface)
+ IDirectFBSurface *subsurface)
{
GdkWindow *window;
GdkWindowObject *private;
return window;
}
-#endif
/*
* The wrapping is not perfect since directfb does not give full access