Commit ffd6baec authored by Matthias Clasen's avatar Matthias Clasen
Browse files

gtk: Intern css names

This avoids a bunch of strdups at startup.
parent 4dc4db56
......@@ -253,7 +253,7 @@ gtk_accel_label_class_init (GtkAccelLabelClass *class)
g_object_class_install_properties (gobject_class, LAST_PROP, props);
gtk_widget_class_set_css_name (widget_class, "accellabel");
gtk_widget_class_set_css_name (widget_class, I_("accellabel"));
}
static void
......
......@@ -402,7 +402,7 @@ gtk_action_bar_class_init (GtkActionBarClass *klass)
g_object_class_install_properties (object_class, LAST_PROP, props);
gtk_widget_class_set_accessible_role (widget_class, ATK_ROLE_PANEL);
gtk_widget_class_set_css_name (widget_class, "actionbar");
gtk_widget_class_set_css_name (widget_class, I_("actionbar"));
}
static void
......
......@@ -1176,7 +1176,7 @@ gtk_app_chooser_widget_class_init (GtkAppChooserWidgetClass *klass)
gtk_widget_class_bind_template_callback (widget_class, program_list_selection_activated);
gtk_widget_class_bind_template_callback (widget_class, widget_button_press_event_cb);
gtk_widget_class_set_css_name (widget_class, "appchooser");
gtk_widget_class_set_css_name (widget_class, I_("appchooser"));
}
static void
......
......@@ -134,7 +134,7 @@ gtk_aspect_frame_class_init (GtkAspectFrameClass *class)
TRUE,
GTK_PARAM_READWRITE|G_PARAM_EXPLICIT_NOTIFY));
gtk_widget_class_set_css_name (GTK_WIDGET_CLASS (class), "frame");
gtk_widget_class_set_css_name (GTK_WIDGET_CLASS (class), I_("frame"));
}
static void
......
......@@ -593,7 +593,7 @@ gtk_assistant_class_init (GtkAssistantClass *class)
gtk_widget_class_bind_template_callback (widget_class, on_assistant_cancel);
gtk_widget_class_bind_template_callback (widget_class, on_assistant_last);
gtk_widget_class_set_css_name (widget_class, "assistant");
gtk_widget_class_set_css_name (widget_class, I_("assistant"));
}
static gint
......
......@@ -172,7 +172,7 @@ gtk_button_box_class_init (GtkButtonBoxClass *class)
FALSE,
GTK_PARAM_READWRITE));
gtk_widget_class_set_css_name (widget_class, "buttonbox");
gtk_widget_class_set_css_name (widget_class, I_("buttonbox"));
}
static void
......
......@@ -259,7 +259,7 @@ gtk_box_class_init (GtkBoxClass *class)
gtk_container_class_install_child_properties (container_class, LAST_CHILD_PROP, child_props);
gtk_widget_class_set_accessible_role (widget_class, ATK_ROLE_FILLER);
gtk_widget_class_set_css_name (widget_class, "box");
gtk_widget_class_set_css_name (widget_class, I_("box"));
}
static void
......
......@@ -284,7 +284,7 @@ gtk_button_class_init (GtkButtonClass *klass)
widget_class->activate_signal = button_signals[ACTIVATE];
gtk_widget_class_set_accessible_type (widget_class, GTK_TYPE_BUTTON_ACCESSIBLE);
gtk_widget_class_set_css_name (widget_class, "button");
gtk_widget_class_set_css_name (widget_class, I_("button"));
}
static void
......
......@@ -640,7 +640,7 @@ gtk_calendar_class_init (GtkCalendarClass *class)
G_TYPE_NONE, 0);
gtk_widget_class_set_accessible_role (widget_class, ATK_ROLE_CALENDAR);
gtk_widget_class_set_css_name (widget_class, "calendar");
gtk_widget_class_set_css_name (widget_class, I_("calendar"));
}
static void
......
......@@ -747,7 +747,7 @@ gtk_cell_editable_widget_class_init (GtkCellEditableWidgetClass *class)
g_param_spec_string ("path", NULL, NULL,
NULL, GTK_PARAM_READWRITE));
gtk_widget_class_set_css_name (widget_class, "acceleditor");
gtk_widget_class_set_css_name (widget_class, I_("acceleditor"));
}
static void
......
......@@ -266,7 +266,7 @@ gtk_cell_view_class_init (GtkCellViewClass *klass)
FALSE,
GTK_PARAM_READWRITE|G_PARAM_EXPLICIT_NOTIFY));
gtk_widget_class_set_css_name (widget_class, "cellview");
gtk_widget_class_set_css_name (widget_class, I_("cellview"));
}
static void
......
......@@ -718,7 +718,7 @@ gtk_center_box_class_init (GtkCenterBoxClass *klass)
gtk_widget_class_set_accessible_role (widget_class, ATK_ROLE_FILLER);
gtk_widget_class_set_css_name (widget_class, "box");
gtk_widget_class_set_css_name (widget_class, I_("box"));
}
static void
......
......@@ -328,7 +328,7 @@ gtk_check_button_class_init (GtkCheckButtonClass *class)
g_object_class_install_properties (object_class, NUM_PROPERTIES, props);
gtk_widget_class_set_accessible_role (widget_class, ATK_ROLE_CHECK_BOX);
gtk_widget_class_set_css_name (widget_class, "checkbutton");
gtk_widget_class_set_css_name (widget_class, I_("checkbutton"));
}
static void
......
......@@ -225,7 +225,7 @@ gtk_check_menu_item_class_init (GtkCheckMenuItemClass *klass)
G_TYPE_NONE, 0);
gtk_widget_class_set_accessible_type (widget_class, GTK_TYPE_CHECK_MENU_ITEM_ACCESSIBLE);
gtk_widget_class_set_css_name (widget_class, "menuitem");
gtk_widget_class_set_css_name (widget_class, I_("menuitem"));
}
/**
......
......@@ -697,7 +697,7 @@ gtk_color_chooser_widget_class_init (GtkColorChooserWidgetClass *class)
g_param_spec_boolean ("show-editor", P_("Show editor"), P_("Show editor"),
FALSE, GTK_PARAM_READWRITE));
gtk_widget_class_set_css_name (GTK_WIDGET_CLASS (class), "colorchooser");
gtk_widget_class_set_css_name (GTK_WIDGET_CLASS (class), I_("colorchooser"));
}
/* GtkColorChooser implementation {{{1 */
......
......@@ -563,7 +563,7 @@ gtk_color_swatch_class_init (GtkColorSwatchClass *class)
TRUE, GTK_PARAM_READWRITE));
gtk_widget_class_set_accessible_type (widget_class, GTK_TYPE_COLOR_SWATCH_ACCESSIBLE);
gtk_widget_class_set_css_name (widget_class, "colorswatch");
gtk_widget_class_set_css_name (widget_class, I_("colorswatch"));
}
static void
......
......@@ -894,7 +894,7 @@ gtk_combo_box_class_init (GtkComboBoxClass *klass)
gtk_widget_class_bind_template_callback (widget_class, gtk_combo_box_menu_hide);
gtk_widget_class_set_accessible_type (widget_class, GTK_TYPE_COMBO_BOX_ACCESSIBLE);
gtk_widget_class_set_css_name (widget_class, "combobox");
gtk_widget_class_set_css_name (widget_class, I_("combobox"));
}
static void
......
......@@ -597,7 +597,7 @@ gtk_dialog_class_init (GtkDialogClass *class)
gtk_widget_class_bind_template_child_private (widget_class, GtkDialog, action_box);
gtk_widget_class_bind_template_callback (widget_class, gtk_dialog_delete_event_handler);
gtk_widget_class_set_css_name (widget_class, "dialog");
gtk_widget_class_set_css_name (widget_class, I_("dialog"));
}
static void
......
......@@ -1878,7 +1878,7 @@ gtk_entry_class_init (GtkEntryClass *class)
"toggle-overwrite", 0);
gtk_widget_class_set_accessible_type (widget_class, GTK_TYPE_ENTRY_ACCESSIBLE);
gtk_widget_class_set_css_name (widget_class, "entry");
gtk_widget_class_set_css_name (widget_class, I_("entry"));
}
static void
......
......@@ -341,7 +341,7 @@ gtk_expander_class_init (GtkExpanderClass *klass)
G_TYPE_NONE, 0);
gtk_widget_class_set_accessible_type (widget_class, GTK_TYPE_EXPANDER_ACCESSIBLE);
gtk_widget_class_set_css_name (widget_class, "expander");
gtk_widget_class_set_css_name (widget_class, I_("expander"));
}
static void
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment