... and G_TYPE_INSTANCE_GET_PRIVATE()
g_type_class_add_private() and G_TYPE_INSTANCE_GET_PRIVATE() were
deprecated in GLib 2.58. Instead, use
G_DEFINE_[ABSTRACT_]TYPE_WITH_PRIVATE(), and
G_ADD_PRIVATE[_DYNAMIC](), and the implictly-defined
foo_get_instance_private() functions, all of which are available in
the GLib versions we depend on.
This commit only covers types registered using one of the
G_DEFINE_FOO() macros (i.e., most types), but not types with a
custom registration function, of which we still have a few -- GLib
currently only provides a (non-deprecated) public API for adding a
private struct using the G_DEFINE_FOO() macros.
Note that this commit was 99% auto-generated (because I'm not
*that* crazy :), so if there are any style mismatches... we'll have
to live with them for now.
We cannot simply randomy move the focus from e.g. a text entry back to
the canvas. Instead introduce global handling of "Escape" and a
"primary_focus_widget" that is always set the the image window's
active canvas. When Escape is pressed, move the focus to that primary
focus widget, or beep if it is already there. Text widgets still get
the key events before that logic and can consume the Escape.
which is look at the right modifier when checking if a key event
can invoke an accelerator. Also get the mnemonic modifier from
GTK instead of hardcoding it, and don't check for it if mnemonics
are disabled, which is the right thing to do on all platforms.
* app/widgets/gimpwindow.c: treat GimpCanvas as a text widget and
dispatch all key events to it before invoking menu shortcuts.
* app/display/gimpdisplayshell-callbacks.c: treat all events on the
empty display as unhandled, not handled.
* app/tools/gimptexttool.c: use the right API for invoking the proxy
text view's bindings. Handle some more cursor navigation request and
swallow text deletion requests we don't handle instead of always
doing what the delete key does.
2009-01-17 Michael Natterer <mitch@gimp.org>
* all files with a GPL header and all COPYING files:
Change licence to GPLv3 (and to LGPLv3 for libgimp).
Cleaned up some copyright headers and regenerated the parsers in
the ImageMap plugin.
svn path=/trunk/; revision=27913
2008-05-08 Sven Neumann <sven@gimp.org>
* app/display/gimpdisplayshell-callbacks.c
(gimp_display_shell_events): move the focus to the canvas on
button-press events.
* app/widgets/gimpwindow.c (gimp_window_key_press_event):
removed
a use of G_UNLIKELY() that is somewhat bogus here.
svn path=/trunk/; revision=25587
2008-04-28 Sven Neumann <sven@gimp.org>
* app/widgets/Makefile.am
* app/widgets/widgets-types.h
* app/widgets/gimpwindow.[ch]: added GimpWindow class and moved
key-press-event handler from GimpDock to this class.
* app/widgets/gimpdock.[ch]:
* app/display/gimpdisplayshell.[ch]: derive from GimpWindow.
svn path=/trunk/; revision=25541