[gimp/gimp-2-8] app: allow to pass NULL to gimp_window_set_primary_focus_widget() (cherry picked from commit 754e4eb
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/gimp-2-8] app: allow to pass NULL to gimp_window_set_primary_focus_widget() (cherry picked from commit 754e4eb
- Date: Wed, 10 Apr 2013 17:31:53 +0000 (UTC)
commit 3aaa69642e218cb495a2cc6691368a901df26e18
Author: Michael Natterer <mitch gimp org>
Date: Wed Apr 10 19:28:49 2013 +0200
app: allow to pass NULL to gimp_window_set_primary_focus_widget()
(cherry picked from commit 754e4eb91946ebb70ff1f6e81e8e7a694d81573d)
app/widgets/gimpwindow.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/app/widgets/gimpwindow.c b/app/widgets/gimpwindow.c
index 0cdb7ab..ce6ce19 100644
--- a/app/widgets/gimpwindow.c
+++ b/app/widgets/gimpwindow.c
@@ -168,8 +168,9 @@ gimp_window_set_primary_focus_widget (GimpWindow *window,
GtkWidget *primary_focus)
{
g_return_if_fail (GIMP_IS_WINDOW (window));
- g_return_if_fail (GTK_IS_WIDGET (primary_focus));
- g_return_if_fail (gtk_widget_get_toplevel (primary_focus) ==
+ g_return_if_fail (primary_focus == NULL || GTK_IS_WIDGET (primary_focus));
+ g_return_if_fail (primary_focus == NULL ||
+ gtk_widget_get_toplevel (primary_focus) ==
GTK_WIDGET (window));
if (window->primary_focus_widget)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]