Move gtk_object_handled_accumulator

This used to live in gtknotebook.c. Since we may use it in
other places in the future, move it to gtkprivate.c where we
already have other shared accumulators.
This commit is contained in:
Matthias Clasen
2016-05-21 10:11:56 -04:00
parent d3adf47d9f
commit 21804b09b4
3 changed files with 21 additions and 16 deletions

View File

@@ -644,22 +644,6 @@ add_reorder_bindings (GtkBindingSet *binding_set,
G_TYPE_BOOLEAN, move_to_last);
}
static gboolean
gtk_object_handled_accumulator (GSignalInvocationHint *ihint,
GValue *return_accu,
const GValue *handler_return,
gpointer dummy)
{
gboolean continue_emission;
GObject *object;
object = g_value_get_object (handler_return);
g_value_set_object (return_accu, object);
continue_emission = !object;
return continue_emission;
}
static void
gtk_notebook_compute_expand (GtkWidget *widget,
gboolean *hexpand_p,

View File

@@ -158,6 +158,22 @@ _gtk_single_string_accumulator (GSignalInvocationHint *ihint,
return continue_emission;
}
gboolean
gtk_object_handled_accumulator (GSignalInvocationHint *ihint,
GValue *return_accu,
const GValue *handler_return,
gpointer dummy)
{
gboolean continue_emission;
GObject *object;
object = g_value_get_object (handler_return);
g_value_set_object (return_accu, object);
continue_emission = !object;
return continue_emission;
}
GdkModifierType
_gtk_replace_virtual_modifiers (GdkKeymap *keymap,
GdkModifierType modifiers)

View File

@@ -73,6 +73,11 @@ gboolean _gtk_single_string_accumulator (GSignalInvocationHint *ihint,
const GValue *handler_return,
gpointer dummy);
gboolean gtk_object_handled_accumulator (GSignalInvocationHint *ihint,
GValue *return_accu,
const GValue *handler_return,
gpointer dummy);
GdkModifierType _gtk_replace_virtual_modifiers (GdkKeymap *keymap,
GdkModifierType modifiers);
GdkModifierType _gtk_get_primary_accel_mod (void);