Ejemplo n.º 1
0
        void ldapRowCollapsed(object o, RowCollapsedArgs args)
        {
            string name       = (string)browserStore.GetValue(args.Iter, (int)TreeCols.DN);
            string serverName = FindServerName(args.Iter, browserStore);

            if (name == serverName)
            {
                return;
            }

            Log.Debug("collapsed row: {0}", name);

            TreeIter child;

            browserStore.IterChildren(out child, args.Iter);

//			string fcName = (string) browserStore.GetValue (child, (int)TreeCols.DN);

            TreeIter lastChild = child;

            while (browserStore.IterNext(ref child))
            {
                browserStore.Remove(ref lastChild);

//				string cn = (string) browserStore.GetValue (child, (int)TreeCols.DN);

                lastChild = child;
            }

            browserStore.Remove(ref lastChild);

            Gdk.Pixbuf pb = parent.RenderIcon(Stock.Open, IconSize.Menu, "");
            browserStore.AppendValues(args.Iter, pb, "");
        }