[gimp/gimp-2-6] Bug 594998 - Keyboard shortcuts does not work for first image when dock is focused
- From: Martin Nordholts <martinn src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gimp/gimp-2-6] Bug 594998 - Keyboard shortcuts does not work for first image when dock is focused
- Date: Sat, 12 Sep 2009 12:56:19 +0000 (UTC)
commit cd9d331b6e650dcf56e15d9eb70e47fd57c1d65c
Author: Martin Nordholts <martinn src gnome org>
Date: Sat Sep 12 14:57:46 2009 +0200
Bug 594998 - Keyboard shortcuts does not work for first image when dock is focused
The dock needs to listen to image changes in the context and not only
display changes since the introduction of the empty-image-window does
not cause any display changes when creating the first image.
app/widgets/gimpimagedock.c | 14 ++++++++++++++
1 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/app/widgets/gimpimagedock.c b/app/widgets/gimpimagedock.c
index 11250fe..aafb87d 100644
--- a/app/widgets/gimpimagedock.c
+++ b/app/widgets/gimpimagedock.c
@@ -46,6 +46,9 @@ static void gimp_image_dock_destroy (GtkObject *object);
static void gimp_image_dock_display_changed (GimpContext *context,
GimpObject *display,
GimpImageDock *dock);
+static void gimp_image_dock_image_changed (GimpContext *context,
+ GimpImage *image,
+ GimpImageDock *dock);
static void gimp_image_dock_image_flush (GimpImage *image,
gboolean invalidate_preview,
GimpImageDock *dock);
@@ -115,6 +118,9 @@ gimp_image_dock_constructor (GType type,
g_signal_connect_object (GIMP_DOCK (dock)->context, "display-changed",
G_CALLBACK (gimp_image_dock_display_changed),
dock, 0);
+ g_signal_connect_object (gimp_dock_get_context (GIMP_DOCK (dock)), "image-changed",
+ G_CALLBACK (gimp_image_dock_image_changed),
+ dock, 0);
g_signal_connect_object (GIMP_DOCK (dock)->context->gimp->config,
"notify::transient-docks",
@@ -167,6 +173,14 @@ gimp_image_dock_display_changed (GimpContext *context,
}
static void
+gimp_image_dock_image_changed (GimpContext *context,
+ GimpImage *image,
+ GimpImageDock *dock)
+{
+ gimp_ui_manager_update (dock->ui_manager, gimp_context_get_display (context));
+}
+
+static void
gimp_image_dock_image_flush (GimpImage *image,
gboolean invalidate_preview,
GimpImageDock *dock)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]