diff options
| author | Jabier Arraiza Cenoz <jabier.arraiza@marker.es> | 2015-04-22 16:48:27 +0000 |
|---|---|---|
| committer | Jabiertxof <jtx@jtx.marker.es> | 2015-04-22 16:48:27 +0000 |
| commit | 7fe44eb152a2e8daffc7b4789c9ebba92bed6989 (patch) | |
| tree | 760a36258a65a33533eb237cd14e3c6eafc9fc44 /src/widgets | |
| parent | adding suport to full path reverse (diff) | |
| parent | extensions. ink2canvas.py - do not parse html comments. (Bug 1446204) (diff) | |
| download | inkscape-7fe44eb152a2e8daffc7b4789c9ebba92bed6989.tar.gz inkscape-7fe44eb152a2e8daffc7b4789c9ebba92bed6989.zip | |
update to trunk
(bzr r13645.1.83)
Diffstat (limited to 'src/widgets')
| -rw-r--r-- | src/widgets/paintbucket-toolbar.cpp | 21 |
1 files changed, 9 insertions, 12 deletions
diff --git a/src/widgets/paintbucket-toolbar.cpp b/src/widgets/paintbucket-toolbar.cpp index d8edeb9f6..eb55287c4 100644 --- a/src/widgets/paintbucket-toolbar.cpp +++ b/src/widgets/paintbucket-toolbar.cpp @@ -121,17 +121,16 @@ void sp_paintbucket_toolbox_prep(SPDesktop *desktop, GtkActionGroup* mainActions { GtkListStore* model = gtk_list_store_new( 2, G_TYPE_STRING, G_TYPE_INT ); - GList* items = 0; gint count = 0; - for ( items = Inkscape::UI::Tools::flood_channels_dropdown_items_list(); items ; items = g_list_next(items) ) - { + const std::vector<Glib::ustring>& channel_list = Inkscape::UI::Tools::FloodTool::channel_list; + for (std::vector<Glib::ustring>::const_iterator iterator = channel_list.begin(); + iterator != channel_list.end(); ++iterator ) { GtkTreeIter iter; gtk_list_store_append( model, &iter ); - gtk_list_store_set( model, &iter, 0, reinterpret_cast<gchar*>(items->data), 1, count, -1 ); + gtk_list_store_set( model, &iter, 0, (*iterator).c_str(), 1, count, -1 ); count++; } - g_list_free( items ); - items = 0; + EgeSelectOneAction* act1 = ege_select_one_action_new( "ChannelsAction", _("Fill by"), (""), NULL, GTK_TREE_MODEL(model) ); g_object_set( act1, "short_label", _("Fill by:"), NULL ); ege_select_one_action_set_appearance( act1, "compact" ); @@ -188,17 +187,15 @@ void sp_paintbucket_toolbox_prep(SPDesktop *desktop, GtkActionGroup* mainActions { GtkListStore* model = gtk_list_store_new( 2, G_TYPE_STRING, G_TYPE_INT ); - GList* items = 0; gint count = 0; - for ( items = Inkscape::UI::Tools::flood_autogap_dropdown_items_list(); items ; items = g_list_next(items) ) - { + const std::vector<Glib::ustring>& gap_list = Inkscape::UI::Tools::FloodTool::gap_list; + for (std::vector<Glib::ustring>::const_iterator iterator = gap_list.begin(); + iterator != gap_list.end(); ++iterator ) { GtkTreeIter iter; gtk_list_store_append( model, &iter ); - gtk_list_store_set( model, &iter, 0, reinterpret_cast<gchar*>(items->data), 1, count, -1 ); + gtk_list_store_set( model, &iter, 0, (*iterator).c_str(), 1, count, -1 ); count++; } - g_list_free( items ); - items = 0; EgeSelectOneAction* act2 = ege_select_one_action_new( "AutoGapAction", _("Close gaps"), (""), NULL, GTK_TREE_MODEL(model) ); g_object_set( act2, "short_label", _("Close gaps:"), NULL ); ege_select_one_action_set_appearance( act2, "compact" ); |
