[gimp] 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] Bug 594998 - Keyboard shortcuts does not work for first image when dock is focused
- Date: Sat, 12 Sep 2009 12:56:45 +0000 (UTC)
commit 8794d2481a9632f4d5fca9df1198c9e32c06f480
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 f4caed5..5c27413 100644
--- a/app/widgets/gimpimagedock.c
+++ b/app/widgets/gimpimagedock.c
@@ -47,6 +47,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);
@@ -112,6 +115,9 @@ gimp_image_dock_constructor (GType type,
g_signal_connect_object (gimp_dock_get_context (GIMP_DOCK (dock)), "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);
return object;
}
@@ -146,6 +152,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]