Пример #1
0
        private void AddParent()
        {
            JournalQuest newParent = new JournalQuest();

            //newParent.OrderIndex = prntForm.journal.categories.Count;
            newParent.Tag = "catTag" + prntForm.mod.nextIdNumber.ToString();
            prntForm.journal.Add(newParent);
            UpdateTreeView();
        }
Пример #2
0
        private void AddChild(string parentTag)
        {
            JournalQuest pnt      = GetParentByTag(parentTag);
            JournalEntry newChild = new JournalEntry();

            //newChild.OrderIndex = pnt.Entries.Count;
            newChild.Tag = "entryTag" + prntForm.mod.nextIdNumber.ToString();
            pnt.Entries.Add(newChild);
            UpdateTreeView();
        }
Пример #3
0
        public JournalQuest DeepCopy()
        {
            JournalQuest other = (JournalQuest)this.MemberwiseClone();

            other.Entries = new List <JournalEntry>();
            foreach (JournalEntry jent in this.entries)
            {
                JournalEntry j = jent.DeepCopy();
                other.Entries.Add(j);
            }
            return(other);
        }
Пример #4
0
 private void JournalEditor_Load(object sender, EventArgs e)
 {
     if (prntForm.journal.Count == 0)
     {
         JournalQuest newCat = new JournalQuest();
         //newCat.OrderIndex = prntForm.journal.categories.Count;
         newCat.Tag = "catTag" + prntForm.mod.nextIdNumber.ToString();
         prntForm.journal.Add(newCat);
         JournalEntry newEntry = new JournalEntry();
         //newEntry.OrderIndex = newCat.Entries.Count;
         newEntry.Tag = "entryTag" + prntForm.mod.nextIdNumber.ToString();
         newCat.Entries.Add(newEntry);
     }
     UpdateTreeView();
 }
Пример #5
0
 private void JournalEditor_Load(object sender, EventArgs e)
 {
     if (prntForm.journal.Count == 0)
     {
         JournalQuest newCat = new JournalQuest();
         //newCat.OrderIndex = prntForm.journal.categories.Count;
         newCat.Tag = "catTag" + prntForm.mod.nextIdNumber.ToString();
         prntForm.journal.Add(newCat);
         JournalEntry newEntry = new JournalEntry();
         //newEntry.OrderIndex = newCat.Entries.Count;
         newEntry.Tag = "entryTag" + prntForm.mod.nextIdNumber.ToString();
         newCat.Entries.Add(newEntry);
     }
     UpdateTreeView();
 }
Пример #6
0
 private void AddParent()
 {
     JournalQuest newParent = new JournalQuest();
     //newParent.OrderIndex = prntForm.journal.categories.Count;
     newParent.Tag = "catTag" + prntForm.mod.nextIdNumber.ToString();
     prntForm.journal.Add(newParent);
     UpdateTreeView();
 }