/** * gimp_ui_get_display_window: * @gdisp_ID: a #GimpDisplay ID. * * Returns the #GdkWindow of a display window. The purpose is to allow * to make plug-in dialogs transient to the image display as explained * with gdk_window_set_transient_for(). * * You shouldn't have to call this function directly. Use * gimp_window_set_transient_for_display() instead. * * Return value: A reference to a #GdkWindow or %NULL. You should * unref the window using g_object_unref() as soon as * you don't need it any longer. * * Since: GIMP 2.4 */ GdkWindow * gimp_ui_get_display_window (guint32 gdisp_ID) { guint32 window; g_return_val_if_fail (gimp_ui_initialized, NULL); window = gimp_display_get_window_handle (gdisp_ID); if (window) return gimp_ui_get_foreign_window (window); return NULL; }
/** * gimp_ui_get_display_window: * * Returns the #GdkWindow of a display window. The purpose is to allow * to make plug-in dialogs transient to the image display as explained * with gdk_window_set_transient_for(). * * You shouldn't have to call this function directly. Use * gimp_window_set_transient_for_display() instead. * * Return value: A reference to a #GdkWindow or %NULL. You should * unref the window using g_object_unref() as soon as * you don't need it any longer. * * Since: GIMP 2.4 */ GdkWindow * gimp_ui_get_display_window (guint32 gdisp_ID) { #ifndef GDK_NATIVE_WINDOW_POINTER GdkNativeWindow window; g_return_val_if_fail (gimp_ui_initialized, NULL); window = gimp_display_get_window_handle (gdisp_ID); if (window) return gdk_window_foreign_new_for_display (gdk_display_get_default (), window); #endif return NULL; }