Revision: 1099 http://geany-plugins.svn.sourceforge.net/geany-plugins/?rev=1099&view=re... Author: eht16 Date: 2010-01-01 22:26:15 +0000 (Fri, 01 Jan 2010)
Log Message: ----------- Use foreach_document() to iterate over open documents
Modified Paths: -------------- trunk/geany-plugins/addons/src/ao_tasks.c
Modified: trunk/geany-plugins/addons/src/ao_tasks.c =================================================================== --- trunk/geany-plugins/addons/src/ao_tasks.c 2010-01-01 22:24:34 UTC (rev 1098) +++ trunk/geany-plugins/addons/src/ao_tasks.c 2010-01-01 22:26:15 UTC (rev 1099) @@ -438,7 +438,7 @@ }
-static void update_tasks_for_doc(AoTasks *t, G_GNUC_UNUSED GeanyDocument *doc) +static void update_tasks_for_doc(AoTasks *t, GeanyDocument *doc) { guint lines, line; gchar *line_buf, *context, *display_name, *tooltip; @@ -481,7 +481,7 @@ }
-void ao_tasks_update(AoTasks *t, G_GNUC_UNUSED GeanyDocument *cur_doc) +void ao_tasks_update(AoTasks *t, GeanyDocument *cur_doc) { AoTasksPrivate *priv = AO_TASKS_GET_PRIVATE(t);
@@ -496,16 +496,13 @@ } else { - GeanyDocument *doc; guint i; - /* clear all */ gtk_list_store_clear(priv->store); /* iterate over all docs */ - for (i = 0; i < geany->documents_array->len; i++) + foreach_document(i) { - doc = document_index(i); - update_tasks_for_doc(t, doc); + update_tasks_for_doc(t, documents[i]); } } }
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
plugins-commits@lists.geany.org