? .DS_Store
? alpha_sort_d5_00.patch
? pager_transliteration_d5_00.patch
? tesje.patch
? transliteration_performance_d5_00.patch
? images/.DS_Store
? po/.DS_Store
Index: vocabindex.view.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/vocabindex/vocabindex.view.inc,v
retrieving revision 1.1.2.2.2.47.2.27
diff -u -p -r1.1.2.2.2.47.2.27 vocabindex.view.inc
--- vocabindex.view.inc	14 Jan 2009 14:41:19 -0000	1.1.2.2.2.47.2.27
+++ vocabindex.view.inc	16 Apr 2009 23:37:26 -0000
@@ -479,6 +479,7 @@ function vocabindex_list_render_alphabet
     }
   }
   $tree = $tree_buffer;
+  usort($tree, 'vocabindex_sort');
 
   // Throw a 404 if there are no terms matching this letter.
   if (count($tree) == 0) {
@@ -574,4 +575,16 @@ function vocabindex_term_link($term, $vi
   $term->description = check_plain($term->description);
 
   return theme('vocabindex_link', $term, $vi);
+}
+
+/**
+ * usort() callback. Sort terms on term weight and name.
+ */
+function vocabindex_sort($term_a, $term_b) {
+  if ($term_a->weight == $term_b->weight) {
+    return strcmp($term_a->name, $term_b->name);
+  }
+  else {
+    return ($term_a->weight < $term_b->weight) ? -1 : 1;
+  }
 }
\ No newline at end of file
