Exemplo n.º 1
0
        protected bool SetResourceMaps(ResourceMaps maps, bool selectevent, bool dontselect, bool nosave)
        {
            last = maps;
            if (FileTable.WrapperRegistry != null)
            {
                tv.ImageList      = FileTable.WrapperRegistry.WrapperImageList;
                tv.StateImageList = tv.ImageList;
            }
            if (!nosave)
            {
                SaveLastSelection();
            }

            this.Clear();
            firstnode = builder.BuildNodes(maps);
            tv.Nodes.Add(firstnode);
            firstnode.Expand();

            allowselectevent = selectevent;
            if (!dontselect && ((maps.Everything.Count <= Helper.WindowsRegistry.BigPackageResourceCount || Helper.WindowsRegistry.ResoruceTreeAllwaysAutoselect)))
            {
                if (!SelectID(firstnode, builder.LastSelectedId))
                {
                    SelectAll();
                    allowselectevent = true;
                    return(false);
                }
            }

            allowselectevent = true;
            return(true);
        }
Exemplo n.º 2
0
        public override ResourceTreeNodeExt BuildNodes(ResourceMaps maps)
        {
            ResourceTreeNodeExt tn = new ResourceTreeNodeExt(0, maps.Everything, SimPe.Localization.GetString("AllRes"));

            AddInstances(maps.ByInstance, tn, true, true);

            tn.ImageIndex = 0;
            return(tn);
        }
Exemplo n.º 3
0
        public ResourceViewManager()
        {
            InitializeComponent();

            maps = new ResourceMaps();
        }
Exemplo n.º 4
0
 public bool SetResourceMaps(ResourceMaps maps, bool selectevent, bool dontselect)
 {
     return(SetResourceMaps(maps, selectevent, dontselect, false));
 }
Exemplo n.º 5
0
 public abstract ResourceTreeNodeExt BuildNodes(ResourceMaps maps);