Beispiel #1
0
 internal Tab(TabListInFrame tabList, ListKind listKind)
 {
     this.Text = new FreeText(tabList.TabTextBuilder);
     this.Text.TextColor = tabList.TabTextColor;
     this.Text.Align = tabList.TabTextAlign;
     this.tabList = tabList;
     this.listKind = listKind;
     this.Columns = new List<Column>();
 }
Beispiel #2
0
 internal void PushSubKindByName(string name, GameObjectList list)
 {
     if ((list != null) && (list.Count != 0))
     {
         if (this.SubKinds.Count == 0)
         {
             this.RightClickClose   = false;
             this.RootListKind.Kind = this.listKindToDisplay;
             this.RootListKind.List = this.gameObjectList;
         }
         this.SetObjectList(list);
         this.listKindToDisplay = this.GetListKindByName(name);
         if (this.listKindToDisplay != null)
         {
             this.ReCalculate();
             SubKind item = new SubKind();
             item.Kind = this.listKindToDisplay;
             item.List = list;
             this.SubKinds.Push(item);
         }
     }
 }
Beispiel #3
0
 internal void PopSubKind()
 {
     if (this.SubKinds.Count > 0)
     {
         SubKind rootListKind;
         this.SubKinds.Pop();
         if (this.SubKinds.Count > 0)
         {
             rootListKind = this.SubKinds.Peek();
         }
         else
         {
             rootListKind = this.RootListKind;
         }
         this.SetObjectList(rootListKind.List);
         this.listKindToDisplay = rootListKind.Kind;
         this.ReCalculate();
     }
     else
     {
         this.RightClickClose = true;
     }
 }
 internal void PushSubKindByName(string name, GameObjectList list)
 {
     if ((list != null) && (list.Count != 0))
     {
         if (this.SubKinds.Count == 0)
         {
             this.RightClickClose = false;
             this.RootListKind.Kind = this.listKindToDisplay;
             this.RootListKind.List = this.gameObjectList;
         }
         this.SetObjectList(list);
         this.listKindToDisplay = this.GetListKindByName(name);
         if (this.listKindToDisplay != null)
         {
             this.ReCalculate();
             SubKind item = new SubKind();
             item.Kind = this.listKindToDisplay;
             item.List = list;
             this.SubKinds.Push(item);
         }
     }
 }
 internal void PopSubKind()
 {
     if (this.SubKinds.Count > 0)
     {
         SubKind rootListKind;
         this.SubKinds.Pop();
         if (this.SubKinds.Count > 0)
         {
             rootListKind = this.SubKinds.Peek();
         }
         else
         {
             rootListKind = this.RootListKind;
         }
         this.SetObjectList(rootListKind.List);
         this.listKindToDisplay = rootListKind.Kind;
         this.ReCalculate();
     }
     else
     {
         this.RightClickClose = true;
     }
 }
 public void SetListKindByName(string Name, bool showCheckBox, bool multiSelecting)
 {
     this.listKindToDisplay = this.GetListKindByName(Name);
     this.MultiSelecting = multiSelecting;
     if (this.listKindToDisplay != null)
     {
         this.SetShowCheckBox(showCheckBox);
     }
 }
 public void SetListKindByID(int ID, bool showCheckBox, bool multiSelecting)
 {
     this.listKindToDisplay = this.GetListKindByID(ID);
     this.MultiSelecting = multiSelecting;
     if (this.listKindToDisplay != null)
     {
         this.SetShowCheckBox(showCheckBox);
     }
 }
 public void LoadFromXMLNode(XmlNode rootNode)
 {
     this.rowHeight = int.Parse(rootNode.Attributes.GetNamedItem("RowHeight").Value);
     base.defaultFrameWidth = int.Parse(rootNode.Attributes.GetNamedItem("FrameWidth").Value);
     base.defaultFrameHeight = int.Parse(rootNode.Attributes.GetNamedItem("FrameHeight").Value);
     this.client.X = int.Parse(rootNode.Attributes.GetNamedItem("ClientX").Value);
     this.client.Y = int.Parse(rootNode.Attributes.GetNamedItem("ClientY").Value);
     this.client.Width = int.Parse(rootNode.Attributes.GetNamedItem("ClientWidth").Value);
     this.client.Height = int.Parse(rootNode.Attributes.GetNamedItem("ClientHeight").Value);
     this.defaultOKButtonPosition.X = int.Parse(rootNode.Attributes.GetNamedItem("OKButtonX").Value);
     this.defaultOKButtonPosition.Y = int.Parse(rootNode.Attributes.GetNamedItem("OKButtonY").Value);
     this.defaultCancelButtonPosition.X = int.Parse(rootNode.Attributes.GetNamedItem("CancelButtonX").Value);
     this.defaultCancelButtonPosition.Y = int.Parse(rootNode.Attributes.GetNamedItem("CancelButtonY").Value);
     this.defaultMapViewSelectorButtonPosition.X = int.Parse(rootNode.Attributes.GetNamedItem("MapViewSelectorButtonX").Value);
     this.defaultMapViewSelectorButtonPosition.Y = int.Parse(rootNode.Attributes.GetNamedItem("MapViewSelectorButtonY").Value);
     foreach (XmlNode node in rootNode.ChildNodes)
     {
         ListKind item = new ListKind(this);
         item.ID = int.Parse(node.Attributes.GetNamedItem("ID").Value);
         item.Name = node.Attributes.GetNamedItem("Name").Value;
         item.DisplayName = node.Attributes.GetNamedItem("DisplayName").Value;
         item.ShowPortrait = bool.Parse(node.Attributes.GetNamedItem("ShowPortrait").Value);
         item.LoadFromXMLNode(node);
         this.ListKinds.Add(item);
     }
 }