diff options
author | Matthias Clasen <mclasen@redhat.com> | 2015-09-12 09:13:00 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2015-09-12 12:50:39 -0400 |
commit | 66f0bdee0adf422f23b5e0bb5addd6256958eb82 (patch) | |
tree | f6d1dc55558cdd1d56015c74e13b8d4f6e05613f | |
parent | c8dcb690aacccf56d84195a2470da0aad74c9e29 (diff) | |
download | gtk+-66f0bdee0adf422f23b5e0bb5addd6256958eb82.tar.gz |
Intern all signal names beforehand
This avoids pointless allocations
-rw-r--r-- | gdk/gdkkeys.c | 6 | ||||
-rw-r--r-- | gtk/gtkaboutdialog.c | 2 | ||||
-rw-r--r-- | gtk/gtkactionmuxer.c | 3 | ||||
-rw-r--r-- | gtk/gtkappchooserbutton.c | 2 | ||||
-rw-r--r-- | gtk/gtkappchooserwidget.c | 6 | ||||
-rw-r--r-- | gtk/gtkapplication.c | 4 | ||||
-rw-r--r-- | gtk/gtkcolorchooser.c | 2 | ||||
-rw-r--r-- | gtk/gtkcolorswatch.c | 4 | ||||
-rw-r--r-- | gtk/gtkfilesystem.c | 3 | ||||
-rw-r--r-- | gtk/gtkflowbox.c | 26 | ||||
-rw-r--r-- | gtk/gtkfontchooser.c | 2 | ||||
-rw-r--r-- | gtk/gtkgesture.c | 10 | ||||
-rw-r--r-- | gtk/gtkgesturedrag.c | 7 | ||||
-rw-r--r-- | gtk/gtkgesturelongpress.c | 4 | ||||
-rw-r--r-- | gtk/gtkgesturemultipress.c | 6 | ||||
-rw-r--r-- | gtk/gtkgesturepan.c | 2 | ||||
-rw-r--r-- | gtk/gtkgesturerotate.c | 3 | ||||
-rw-r--r-- | gtk/gtkgestureswipe.c | 3 | ||||
-rw-r--r-- | gtk/gtkgesturezoom.c | 3 | ||||
-rw-r--r-- | gtk/gtkglarea.c | 4 | ||||
-rw-r--r-- | gtk/gtklevelbar.c | 2 | ||||
-rw-r--r-- | gtk/gtklistbox.c | 28 | ||||
-rw-r--r-- | gtk/gtkprinteroption.c | 2 | ||||
-rw-r--r-- | gtk/gtkprinteroptionset.c | 3 | ||||
-rw-r--r-- | gtk/gtkprinteroptionwidget.c | 2 | ||||
-rw-r--r-- | gtk/gtksearchengine.c | 7 |
26 files changed, 77 insertions, 69 deletions
diff --git a/gdk/gdkkeys.c b/gdk/gdkkeys.c index 9302f425e9..d9185fda4b 100644 --- a/gdk/gdkkeys.c +++ b/gdk/gdkkeys.c @@ -133,7 +133,7 @@ gdk_keymap_class_init (GdkKeymapClass *klass) * Since: 2.0 */ signals[DIRECTION_CHANGED] = - g_signal_new ("direction-changed", + g_signal_new (g_intern_static_string ("direction-changed"), G_OBJECT_CLASS_TYPE (object_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GdkKeymapClass, direction_changed), @@ -151,7 +151,7 @@ gdk_keymap_class_init (GdkKeymapClass *klass) * Since: 2.2 */ signals[KEYS_CHANGED] = - g_signal_new ("keys-changed", + g_signal_new (g_intern_static_string ("keys-changed"), G_OBJECT_CLASS_TYPE (object_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GdkKeymapClass, keys_changed), @@ -171,7 +171,7 @@ gdk_keymap_class_init (GdkKeymapClass *klass) * Since: 2.16 */ signals[STATE_CHANGED] = - g_signal_new ("state_changed", + g_signal_new (g_intern_static_string ("state_changed"), G_OBJECT_CLASS_TYPE (object_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GdkKeymapClass, state_changed), diff --git a/gtk/gtkaboutdialog.c b/gtk/gtkaboutdialog.c index 0a827318cf..24a8ba0493 100644 --- a/gtk/gtkaboutdialog.c +++ b/gtk/gtkaboutdialog.c @@ -324,7 +324,7 @@ gtk_about_dialog_class_init (GtkAboutDialogClass *klass) * Since: 2.24 */ signals[ACTIVATE_LINK] = - g_signal_new ("activate-link", + g_signal_new (I_("activate-link"), G_TYPE_FROM_CLASS (object_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkAboutDialogClass, activate_link), diff --git a/gtk/gtkactionmuxer.c b/gtk/gtkactionmuxer.c index 408973bc2f..643aeb3190 100644 --- a/gtk/gtkactionmuxer.c +++ b/gtk/gtkactionmuxer.c @@ -23,6 +23,7 @@ #include "gtkactionobservable.h" #include "gtkactionobserver.h" +#include "gtkintl.h" #include <string.h> @@ -632,7 +633,7 @@ gtk_action_muxer_class_init (GObjectClass *class) class->finalize = gtk_action_muxer_finalize; class->dispose = gtk_action_muxer_dispose; - accel_signal = g_signal_new ("primary-accel-changed", GTK_TYPE_ACTION_MUXER, G_SIGNAL_RUN_LAST, + accel_signal = g_signal_new (I_("primary-accel-changed"), GTK_TYPE_ACTION_MUXER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, NULL, G_TYPE_NONE, 2, G_TYPE_STRING, G_TYPE_STRING); properties[PROP_PARENT] = g_param_spec_object ("parent", "Parent", diff --git a/gtk/gtkappchooserbutton.c b/gtk/gtkappchooserbutton.c index adc6ccef68..dc65d72774 100644 --- a/gtk/gtkappchooserbutton.c +++ b/gtk/gtkappchooserbutton.c @@ -661,7 +661,7 @@ gtk_app_chooser_button_class_init (GtkAppChooserButtonClass *klass) * dropdown menu. */ signals[SIGNAL_CUSTOM_ITEM_ACTIVATED] = - g_signal_new ("custom-item-activated", + g_signal_new (I_("custom-item-activated"), GTK_TYPE_APP_CHOOSER_BUTTON, G_SIGNAL_RUN_FIRST | G_SIGNAL_DETAILED, G_STRUCT_OFFSET (GtkAppChooserButtonClass, custom_item_activated), diff --git a/gtk/gtkappchooserwidget.c b/gtk/gtkappchooserwidget.c index 01f9a4b908..aa6b0dff30 100644 --- a/gtk/gtkappchooserwidget.c +++ b/gtk/gtkappchooserwidget.c @@ -1042,7 +1042,7 @@ gtk_app_chooser_widget_class_init (GtkAppChooserWidgetClass *klass) * Emitted when an application item is selected from the widget's list. */ signals[SIGNAL_APPLICATION_SELECTED] = - g_signal_new ("application-selected", + g_signal_new (I_("application-selected"), GTK_TYPE_APP_CHOOSER_WIDGET, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkAppChooserWidgetClass, application_selected), @@ -1063,7 +1063,7 @@ gtk_app_chooser_widget_class_init (GtkAppChooserWidgetClass *klass) * Return or Enter. */ signals[SIGNAL_APPLICATION_ACTIVATED] = - g_signal_new ("application-activated", + g_signal_new (I_("application-activated"), GTK_TYPE_APP_CHOOSER_WIDGET, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkAppChooserWidgetClass, application_activated), @@ -1084,7 +1084,7 @@ gtk_app_chooser_widget_class_init (GtkAppChooserWidgetClass *klass) * if at least one item has been added to the menu. */ signals[SIGNAL_POPULATE_POPUP] = - g_signal_new ("populate-popup", + g_signal_new (I_("populate-popup"), GTK_TYPE_APP_CHOOSER_WIDGET, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkAppChooserWidgetClass, populate_popup), diff --git a/gtk/gtkapplication.c b/gtk/gtkapplication.c index e1a574c320..af13451928 100644 --- a/gtk/gtkapplication.c +++ b/gtk/gtkapplication.c @@ -904,7 +904,7 @@ gtk_application_class_init (GtkApplicationClass *class) * Since: 3.2 */ gtk_application_signals[WINDOW_ADDED] = - g_signal_new ("window-added", GTK_TYPE_APPLICATION, G_SIGNAL_RUN_FIRST, + g_signal_new (I_("window-added"), GTK_TYPE_APPLICATION, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkApplicationClass, window_added), NULL, NULL, g_cclosure_marshal_VOID__OBJECT, @@ -922,7 +922,7 @@ gtk_application_class_init (GtkApplicationClass *class) * Since: 3.2 */ gtk_application_signals[WINDOW_REMOVED] = - g_signal_new ("window-removed", GTK_TYPE_APPLICATION, G_SIGNAL_RUN_FIRST, + g_signal_new (I_("window-removed"), GTK_TYPE_APPLICATION, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkApplicationClass, window_removed), NULL, NULL, g_cclosure_marshal_VOID__OBJECT, diff --git a/gtk/gtkcolorchooser.c b/gtk/gtkcolorchooser.c index f3f41fba8f..f68c13f353 100644 --- a/gtk/gtkcolorchooser.c +++ b/gtk/gtkcolorchooser.c @@ -102,7 +102,7 @@ gtk_color_chooser_default_init (GtkColorChooserInterface *iface) * Since: 3.4 */ signals[COLOR_ACTIVATED] = - g_signal_new ("color-activated", + g_signal_new (I_("color-activated"), GTK_TYPE_COLOR_CHOOSER, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkColorChooserInterface, color_activated), diff --git a/gtk/gtkcolorswatch.c b/gtk/gtkcolorswatch.c index e915741d78..15770baed1 100644 --- a/gtk/gtkcolorswatch.c +++ b/gtk/gtkcolorswatch.c @@ -690,14 +690,14 @@ gtk_color_swatch_class_init (GtkColorSwatchClass *class) widget_class->size_allocate = swatch_size_allocate; signals[ACTIVATE] = - g_signal_new ("activate", + g_signal_new (I_("activate"), GTK_TYPE_COLOR_SWATCH, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkColorSwatchClass, activate), NULL, NULL, NULL, G_TYPE_NONE, 0); signals[CUSTOMIZE] = - g_signal_new ("customize", + g_signal_new (I_("customize"), GTK_TYPE_COLOR_SWATCH, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkColorSwatchClass, customize), diff --git a/gtk/gtkfilesystem.c b/gtk/gtkfilesystem.c index 4ed028f432..09601bd261 100644 --- a/gtk/gtkfilesystem.c +++ b/gtk/gtkfilesystem.c @@ -29,6 +29,7 @@ #include "gtkfilesystem.h" #include "gtkicontheme.h" #include "gtkprivate.h" +#include "gtkintl.h" /* #define DEBUG_MODE */ #ifdef DEBUG_MODE @@ -142,7 +143,7 @@ _gtk_file_system_class_init (GtkFileSystemClass *class) object_class->dispose = gtk_file_system_dispose; fs_signals[VOLUMES_CHANGED] = - g_signal_new ("volumes-changed", + g_signal_new (I_("volumes-changed"), G_TYPE_FROM_CLASS (object_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkFileSystemClass, volumes_changed), diff --git a/gtk/gtkflowbox.c b/gtk/gtkflowbox.c index f53e908c00..95d54c22f6 100644 --- a/gtk/gtkflowbox.c +++ b/gtk/gtkflowbox.c @@ -3775,7 +3775,7 @@ gtk_flow_box_class_init (GtkFlowBoxClass *class) * The ::child-activated signal is emitted when a child has been * activated by the user. */ - signals[CHILD_ACTIVATED] = g_signal_new ("child-activated", + signals[CHILD_ACTIVATED] = g_signal_new (I_("child-activated"), GTK_TYPE_FLOW_BOX, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkFlowBoxClass, child_activated), @@ -3795,7 +3795,7 @@ gtk_flow_box_class_init (GtkFlowBoxClass *class) * gtk_flow_box_get_selected_children() to obtain the * selected children. */ - signals[SELECTED_CHILDREN_CHANGED] = g_signal_new ("selected-children-changed", + signals[SELECTED_CHILDREN_CHANGED] = g_signal_new (I_("selected-children-changed"), GTK_TYPE_FLOW_BOX, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkFlowBoxClass, selected_children_changed), @@ -3811,7 +3811,7 @@ gtk_flow_box_class_init (GtkFlowBoxClass *class) * [keybinding signal][GtkBindingSignal] * which gets emitted when the user activates the @box. */ - signals[ACTIVATE_CURSOR_CHILD] = g_signal_new ("activate-cursor-child", + signals[ACTIVATE_CURSOR_CHILD] = g_signal_new (I_("activate-cursor-child"), GTK_TYPE_FLOW_BOX, G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, G_STRUCT_OFFSET (GtkFlowBoxClass, activate_cursor_child), @@ -3829,7 +3829,7 @@ gtk_flow_box_class_init (GtkFlowBoxClass *class) * * The default binding for this signal is Ctrl-Space. */ - signals[TOGGLE_CURSOR_CHILD] = g_signal_new ("toggle-cursor-child", + signals[TOGGLE_CURSOR_CHILD] = g_signal_new (I_("toggle-cursor-child"), GTK_TYPE_FLOW_BOX, G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, G_STRUCT_OFFSET (GtkFlowBoxClass, toggle_cursor_child), @@ -3861,7 +3861,7 @@ gtk_flow_box_class_init (GtkFlowBoxClass *class) * - Home/End keys move to the ends of the box * - PageUp/PageDown keys move vertically by pages */ - signals[MOVE_CURSOR] = g_signal_new ("move-cursor", + signals[MOVE_CURSOR] = g_signal_new (I_("move-cursor"), GTK_TYPE_FLOW_BOX, G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, G_STRUCT_OFFSET (GtkFlowBoxClass, move_cursor), @@ -3880,7 +3880,7 @@ gtk_flow_box_class_init (GtkFlowBoxClass *class) * * The default bindings for this signal is Ctrl-a. */ - signals[SELECT_ALL] = g_signal_new ("select-all", + signals[SELECT_ALL] = g_signal_new (I_("select-all"), GTK_TYPE_FLOW_BOX, G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, G_STRUCT_OFFSET (GtkFlowBoxClass, select_all), @@ -3899,13 +3899,13 @@ gtk_flow_box_class_init (GtkFlowBoxClass *class) * * The default bindings for this signal is Ctrl-Shift-a. */ - signals[UNSELECT_ALL] = g_signal_new ("unselect-all", - GTK_TYPE_FLOW_BOX, - G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, - G_STRUCT_OFFSET (GtkFlowBoxClass, unselect_all), - NULL, NULL, - g_cclosure_marshal_VOID__VOID, - G_TYPE_NONE, 0); + signals[UNSELECT_ALL] = g_signal_new (I_("unselect-all"), + GTK_TYPE_FLOW_BOX, + G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, + G_STRUCT_OFFSET (GtkFlowBoxClass, unselect_all), + NULL, NULL, + g_cclosure_marshal_VOID__VOID, + G_TYPE_NONE, 0); widget_class->activate_signal = signals[ACTIVATE_CURSOR_CHILD]; diff --git a/gtk/gtkfontchooser.c b/gtk/gtkfontchooser.c index e2ed3a0188..0b2b5144ea 100644 --- a/gtk/gtkfontchooser.c +++ b/gtk/gtkfontchooser.c @@ -116,7 +116,7 @@ gtk_font_chooser_default_init (GtkFontChooserInterface *iface) * Space, Shift+Space, Return or Enter. */ chooser_signals[SIGNAL_FONT_ACTIVATED] = - g_signal_new ("font-activated", + g_signal_new (I_("font-activated"), GTK_TYPE_FONT_CHOOSER, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkFontChooserIface, font_activated), diff --git a/gtk/gtkgesture.c b/gtk/gtkgesture.c index f3556de718..cb0fbbe80b 100644 --- a/gtk/gtkgesture.c +++ b/gtk/gtkgesture.c @@ -899,7 +899,7 @@ gtk_gesture_class_init (GtkGestureClass *klass) * Since: 3.14 */ signals[BEGIN] = - g_signal_new ("begin", + g_signal_new (I_("begin"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureClass, begin), @@ -923,7 +923,7 @@ gtk_gesture_class_init (GtkGestureClass *klass) * Since: 3.14 */ signals[END] = - g_signal_new ("end", + g_signal_new (I_("end"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureClass, end), @@ -940,7 +940,7 @@ gtk_gesture_class_init (GtkGestureClass *klass) * Since: 3.14 */ signals[UPDATE] = - g_signal_new ("update", + g_signal_new (I_("update"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureClass, update), @@ -961,7 +961,7 @@ gtk_gesture_class_init (GtkGestureClass *klass) * Since: 3.14 */ signals[CANCEL] = - g_signal_new ("cancel", + g_signal_new (I_("cancel"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureClass, cancel), @@ -980,7 +980,7 @@ gtk_gesture_class_init (GtkGestureClass *klass) * Since: 3.14 */ signals[SEQUENCE_STATE_CHANGED] = - g_signal_new ("sequence-state-changed", + g_signal_new (I_("sequence-state-changed"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureClass, sequence_state_changed), diff --git a/gtk/gtkgesturedrag.c b/gtk/gtkgesturedrag.c index 7d80cef07f..0c5a7859e8 100644 --- a/gtk/gtkgesturedrag.c +++ b/gtk/gtkgesturedrag.c @@ -33,6 +33,7 @@ #include "config.h" #include "gtkgesturedrag.h" #include "gtkgesturedragprivate.h" +#include "gtkintl.h" typedef struct _GtkGestureDragPrivate GtkGestureDragPrivate; typedef struct _EventData EventData; @@ -149,7 +150,7 @@ gtk_gesture_drag_class_init (GtkGestureDragClass *klass) * Since: 3.14 */ signals[DRAG_BEGIN] = - g_signal_new ("drag-begin", + g_signal_new (I_("drag-begin"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureDragClass, drag_begin), @@ -166,7 +167,7 @@ gtk_gesture_drag_class_init (GtkGestureDragClass *klass) * Since: 3.14 */ signals[DRAG_UPDATE] = - g_signal_new ("drag-update", + g_signal_new (I_("drag-update"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureDragClass, drag_update), @@ -183,7 +184,7 @@ gtk_gesture_drag_class_init (GtkGestureDragClass *klass) * Since: 3.14 */ signals[DRAG_END] = - g_signal_new ("drag-end", + g_signal_new (I_("drag-end"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureDragClass, drag_end), diff --git a/gtk/gtkgesturelongpress.c b/gtk/gtkgesturelongpress.c index 09bbe6436f..405068db53 100644 --- a/gtk/gtkgesturelongpress.c +++ b/gtk/gtkgesturelongpress.c @@ -298,7 +298,7 @@ gtk_gesture_long_press_class_init (GtkGestureLongPressClass *klass) * Since: 3.14 */ signals[PRESSED] = - g_signal_new ("pressed", + g_signal_new (I_("pressed"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureLongPressClass, pressed), @@ -314,7 +314,7 @@ gtk_gesture_long_press_class_init (GtkGestureLongPressClass *klass) * Since: 3.14 */ signals[CANCELLED] = - g_signal_new ("cancelled", + g_signal_new (I_("cancelled"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureLongPressClass, cancelled), diff --git a/gtk/gtkgesturemultipress.c b/gtk/gtkgesturemultipress.c index 7b0067164c..1049eeee50 100644 --- a/gtk/gtkgesturemultipress.c +++ b/gtk/gtkgesturemultipress.c @@ -318,7 +318,7 @@ gtk_gesture_multi_press_class_init (GtkGestureMultiPressClass *klass) * Since: 3.14 */ signals[PRESSED] = - g_signal_new ("pressed", + g_signal_new (I_("pressed"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureMultiPressClass, pressed), @@ -341,7 +341,7 @@ gtk_gesture_multi_press_class_init (GtkGestureMultiPressClass *klass) * Since: 3.14 */ signals[RELEASED] = - g_signal_new ("released", + g_signal_new (I_("released"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureMultiPressClass, released), @@ -358,7 +358,7 @@ gtk_gesture_multi_press_class_init (GtkGestureMultiPressClass *klass) * Since: 3.14 */ signals[STOPPED] = - g_signal_new ("stopped", + g_signal_new (I_("stopped"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureMultiPressClass, stopped), diff --git a/gtk/gtkgesturepan.c b/gtk/gtkgesturepan.c index e796342123..cbc34e6e63 100644 --- a/gtk/gtkgesturepan.c +++ b/gtk/gtkgesturepan.c @@ -252,7 +252,7 @@ gtk_gesture_pan_class_init (GtkGesturePanClass *klass) * Since: 3.14 */ signals[PAN] = - g_signal_new ("pan", + g_signal_new (I_("pan"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGesturePanClass, pan), diff --git a/gtk/gtkgesturerotate.c b/gtk/gtkgesturerotate.c index ad6be308f8..7a1286e961 100644 --- a/gtk/gtkgesturerotate.c +++ b/gtk/gtkgesturerotate.c @@ -34,6 +34,7 @@ #include "gtkgesturerotate.h" #include "gtkgesturerotateprivate.h" #include "gtkmarshalers.h" +#include "gtkintl.h" typedef struct _GtkGestureRotatePrivate GtkGestureRotatePrivate; @@ -227,7 +228,7 @@ gtk_gesture_rotate_class_init (GtkGestureRotateClass *klass) * Since: 3.14 */ signals[ANGLE_CHANGED] = - g_signal_new ("angle-changed", + g_signal_new (I_("angle-changed"), GTK_TYPE_GESTURE_ROTATE, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkGestureRotateClass, angle_changed), diff --git a/gtk/gtkgestureswipe.c b/gtk/gtkgestureswipe.c index 82bfba0eaa..9713226632 100644 --- a/gtk/gtkgestureswipe.c +++ b/gtk/gtkgestureswipe.c @@ -40,6 +40,7 @@ #include "gtkgestureswipeprivate.h" #include "gtkgestureprivate.h" #include "gtkmarshalers.h" +#include "gtkintl.h" #define CAPTURE_THRESHOLD_MS 150 @@ -230,7 +231,7 @@ gtk_gesture_swipe_class_init (GtkGestureSwipeClass *klass) * Since: 3.14 */ signals[SWIPE] = - g_signal_new ("swipe", + g_signal_new (I_("swipe"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGestureSwipeClass, swipe), diff --git a/gtk/gtkgesturezoom.c b/gtk/gtkgesturezoom.c index 00a8f17639..8b61b3594e 100644 --- a/gtk/gtkgesturezoom.c +++ b/gtk/gtkgesturezoom.c @@ -34,6 +34,7 @@ #include <math.h> #include "gtkgesturezoom.h" #include "gtkgesturezoomprivate.h" +#include "gtkintl.h" typedef struct _GtkGestureZoomPrivate GtkGestureZoomPrivate; @@ -196,7 +197,7 @@ gtk_gesture_zoom_class_init (GtkGestureZoomClass *klass) * Since: 3.14 */ signals[SCALE_CHANGED] = - g_signal_new ("scale-changed", + g_signal_new (I_("scale-changed"), GTK_TYPE_GESTURE_ZOOM, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkGestureZoomClass, scale_changed), diff --git a/gtk/gtkglarea.c b/gtk/gtkglarea.c index 5cf8bf2dc6..f357b10098 100644 --- a/gtk/gtkglarea.c +++ b/gtk/gtkglarea.c @@ -902,7 +902,7 @@ gtk_gl_area_class_init (GtkGLAreaClass *klass) * Since: 3.16 */ area_signals[RESIZE] = - g_signal_new ("resize", + g_signal_new (I_("resize"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGLAreaClass, resize), @@ -931,7 +931,7 @@ gtk_gl_area_class_init (GtkGLAreaClass *klass) * Since: 3.16 */ area_signals[CREATE_CONTEXT] = - g_signal_new ("create-context", + g_signal_new (I_("create-context"), G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkGLAreaClass, create_context), diff --git a/gtk/gtklevelbar.c b/gtk/gtklevelbar.c index 7b02097139..60e63c9d07 100644 --- a/gtk/gtklevelbar.c +++ b/gtk/gtklevelbar.c @@ -926,7 +926,7 @@ gtk_level_bar_class_init (GtkLevelBarClass *klass) * Since: 3.6 */ signals[SIGNAL_OFFSET_CHANGED] = - g_signal_new ("offset-changed", + g_signal_new (I_("offset-changed"), GTK_TYPE_LEVEL_BAR, G_SIGNAL_RUN_FIRST | G_SIGNAL_DETAILED, G_STRUCT_OFFSET (GtkLevelBarClass, offset_changed), diff --git a/gtk/gtklistbox.c b/gtk/gtklistbox.c index fe62e1d9a9..bc4a1e6200 100644 --- a/gtk/gtklistbox.c +++ b/gtk/gtklistbox.c @@ -471,7 +471,7 @@ gtk_list_box_class_init (GtkListBoxClass *klass) * Since: 3.10 */ signals[ROW_SELECTED] = - g_signal_new ("row-selected", + g_signal_new (I_("row-selected"), GTK_TYPE_LIST_BOX, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkListBoxClass, row_selected), @@ -489,7 +489,7 @@ gtk_list_box_class_init (GtkListBoxClass *klass) * * Since: 3.14 */ - signals[SELECTED_ROWS_CHANGED] = g_signal_new ("selected-rows-changed", + signals[SELECTED_ROWS_CHANGED] = g_signal_new (I_("selected-rows-changed"), GTK_TYPE_LIST_BOX, G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (GtkListBoxClass, selected_rows_changed), @@ -509,7 +509,7 @@ gtk_list_box_class_init (GtkListBoxClass *klass) * * Since: 3.14 */ - signals[SELECT_ALL] = g_signal_new ("select-all", + signals[SELECT_ALL] = g_signal_new (I_("select-all"), GTK_TYPE_LIST_BOX, G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, G_STRUCT_OFFSET (GtkListBoxClass, select_all), @@ -529,13 +529,13 @@ gtk_list_box_class_init (GtkListBoxClass *klass) * * Since: 3.14 */ - signals[UNSELECT_ALL] = g_signal_new ("unselect-all", - GTK_TYPE_LIST_BOX, - G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, - G_STRUCT_OFFSET (GtkListBoxClass, unselect_all), - NULL, NULL, - g_cclosure_marshal_VOID__VOID, - G_TYPE_NONE, 0); + signals[UNSELECT_ALL] = g_signal_new (I_("unselect-all"), + GTK_TYPE_LIST_BOX, + G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, + G_STRUCT_OFFSET (GtkListBoxClass, unselect_all), + NULL, NULL, + g_cclosure_marshal_VOID__VOID, + G_TYPE_NONE, 0); /** * GtkListBox::row-activated: @@ -547,7 +547,7 @@ gtk_list_box_class_init (GtkListBoxClass *klass) * Since: 3.10 */ signals[ROW_ACTIVATED] = - g_signal_new ("row-activated", + g_signal_new (I_("row-activated"), GTK_TYPE_LIST_BOX, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkListBoxClass, row_activated), @@ -556,7 +556,7 @@ gtk_list_box_class_init (GtkListBoxClass *klass) G_TYPE_NONE, 1, GTK_TYPE_LIST_BOX_ROW); signals[ACTIVATE_CURSOR_ROW] = - g_signal_new ("activate-cursor-row", + g_signal_new (I_("activate-cursor-row"), GTK_TYPE_LIST_BOX, G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, G_STRUCT_OFFSET (GtkListBoxClass, activate_cursor_row), @@ -564,7 +564,7 @@ gtk_list_box_class_init (GtkListBoxClass *klass) g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); signals[TOGGLE_CURSOR_ROW] = - g_signal_new ("toggle-cursor-row", + g_signal_new (I_("toggle-cursor-row"), GTK_TYPE_LIST_BOX, G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, G_STRUCT_OFFSET (GtkListBoxClass, toggle_cursor_row), @@ -572,7 +572,7 @@ gtk_list_box_class_init (GtkListBoxClass *klass) g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); signals[MOVE_CURSOR] = - g_signal_new ("move-cursor", + g_signal_new (I_("move-cursor"), GTK_TYPE_LIST_BOX, G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, G_STRUCT_OFFSET (GtkListBoxClass, move_cursor), diff --git a/gtk/gtkprinteroption.c b/gtk/gtkprinteroption.c index 644fe209dc..412671671e 100644 --- a/gtk/gtkprinteroption.c +++ b/gtk/gtkprinteroption.c @@ -89,7 +89,7 @@ gtk_printer_option_class_init (GtkPrinterOptionClass *class) gobject_class->get_property = gtk_printer_option_get_property; signals[CHANGED] = - g_signal_new ("changed", + g_signal_new (I_("changed"), G_TYPE_FROM_CLASS (class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkPrinterOptionClass, changed), diff --git a/gtk/gtkprinteroptionset.c b/gtk/gtkprinteroptionset.c index b063445b58..5748565c7f 100644 --- a/gtk/gtkprinteroptionset.c +++ b/gtk/gtkprinteroptionset.c @@ -22,6 +22,7 @@ #include <gmodule.h> #include "gtkprinteroptionset.h" +#include "gtkintl.h" /***************************************** * GtkPrinterOptionSet * @@ -66,7 +67,7 @@ gtk_printer_option_set_class_init (GtkPrinterOptionSetClass *class) gobject_class->finalize = gtk_printer_option_set_finalize; signals[CHANGED] = - g_signal_new ("changed", + g_signal_new (I_("changed"), G_TYPE_FROM_CLASS (gobject_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkPrinterOptionSetClass, changed), diff --git a/gtk/gtkprinteroptionwidget.c b/gtk/gtkprinteroptionwidget.c index 8278e18953..509119e0a4 100644 --- a/gtk/gtkprinteroptionwidget.c +++ b/gtk/gtkprinteroptionwidget.c @@ -112,7 +112,7 @@ gtk_printer_option_widget_class_init (GtkPrinterOptionWidgetClass *class) widget_class->mnemonic_activate = gtk_printer_option_widget_mnemonic_activate; signals[CHANGED] = - g_signal_new ("changed", + g_signal_new (I_("changed"), G_TYPE_FROM_CLASS (class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkPrinterOptionWidgetClass, changed), diff --git a/gtk/gtksearchengine.c b/gtk/gtksearchengine.c index fbbb80b0d0..7591700871 100644 --- a/gtk/gtksearchengine.c +++ b/gtk/gtksearchengine.c @@ -25,6 +25,7 @@ #include "gtksearchenginetracker.h" #include "gtksearchenginemodel.h" #include "gtksearchenginequartz.h" +#include "gtkintl.h" #include <gdk/gdk.h> /* for GDK_WINDOWING_QUARTZ */ @@ -168,7 +169,7 @@ _gtk_search_engine_class_init (GtkSearchEngineClass *class) class->stop = stop; signals[HITS_ADDED] = - g_signal_new ("hits-added", + g_signal_new (I_("hits-added"), G_TYPE_FROM_CLASS (class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkSearchEngineClass, hits_added), @@ -178,7 +179,7 @@ _gtk_search_engine_class_init (GtkSearchEngineClass *class) G_TYPE_POINTER); signals[FINISHED] = - g_signal_new ("finished", + g_signal_new (I_("finished"), G_TYPE_FROM_CLASS (class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkSearchEngineClass, finished), @@ -187,7 +188,7 @@ _gtk_search_engine_class_init (GtkSearchEngineClass *class) G_TYPE_NONE, 0); signals[ERROR] = - g_signal_new ("error", + g_signal_new (I_("error"), G_TYPE_FROM_CLASS (class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkSearchEngineClass, error), |