[gimp] app: don't use image_window->menubar if it's NULL
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: don't use image_window->menubar if it's NULL
- Date: Fri, 16 Sep 2011 21:26:20 +0000 (UTC)
commit ed00cff9d3d4e52a7fb5769496d3879ae8a46a91
Author: Michael Natterer <mitch gimp org>
Date: Fri Sep 16 23:23:01 2011 +0200
app: don't use image_window->menubar if it's NULL
app/display/gimpimagewindow.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/app/display/gimpimagewindow.c b/app/display/gimpimagewindow.c
index c853263..55e1b55 100644
--- a/app/display/gimpimagewindow.c
+++ b/app/display/gimpimagewindow.c
@@ -1134,7 +1134,8 @@ gimp_image_window_set_show_menubar (GimpImageWindow *window,
private = GIMP_IMAGE_WINDOW_GET_PRIVATE (window);
- gtk_widget_set_visible (private->menubar, show);
+ if (private->menubar)
+ gtk_widget_set_visible (private->menubar, show);
}
gboolean
@@ -1146,7 +1147,10 @@ gimp_image_window_get_show_menubar (GimpImageWindow *window)
private = GIMP_IMAGE_WINDOW_GET_PRIVATE (window);
- return gtk_widget_get_visible (private->menubar);
+ if (private->menubar)
+ return gtk_widget_get_visible (private->menubar);
+
+ return FALSE;
}
gboolean
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]