From: Florian Brosch Date: Mon, 27 Feb 2012 00:34:37 +0000 (+0100) Subject: libvaladoc/html: Sort subnamespaces in navis X-Git-Tag: 0.37.1~3^2~204 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5dbaebf86e6584b403f75e3502d68a45abc82544;p=thirdparty%2Fvala.git libvaladoc/html: Sort subnamespaces in navis --- diff --git a/src/libvaladoc/html/basicdoclet.vala b/src/libvaladoc/html/basicdoclet.vala index d2ab882ee..75a52cfef 100755 --- a/src/libvaladoc/html/basicdoclet.vala +++ b/src/libvaladoc/html/basicdoclet.vala @@ -257,7 +257,11 @@ public abstract class Valadoc.Html.BasicDoclet : Api.Visitor, Doclet { } protected void fetch_subnamespace_names (Api.Node node, Gee.ArrayList namespaces) { - foreach (Api.Node child in node.get_children_by_type (Api.NodeType.NAMESPACE)) { + Gee.ArrayList sorted_list = new Gee.ArrayList (); + sorted_list.add_all (node.get_children_by_type (Api.NodeType.NAMESPACE)); + sorted_list.sort (); + + foreach (Api.Node child in sorted_list) { namespaces.add ((Namespace) child); this.fetch_subnamespace_names (child, namespaces); }