상속: System.EventArgs
예제 #1
0
        public static Category RegisterCategory(string name)
        {
            Category category;
            if (m_mapCategories.TryGetValue(name, out category))
                return category;

            category = new Category(name);
            m_hshCategories.Add(category);
            m_mapCategories.Add(name, category);

            if (CategoryAdded != null)
            {
                var args = new CategoryManagerEventArgs(category);
                CategoryAdded(null, args);
            }

            return category;
        }
예제 #2
0
        public static Category RegisterCategory(string name)
        {
            Category category;

            if (m_mapCategories.TryGetValue(name, out category))
            {
                return(category);
            }

            category = new Category(name);
            m_hshCategories.Add(category);
            m_mapCategories.Add(name, category);

            if (CategoryAdded != null)
            {
                var args = new CategoryManagerEventArgs(category);
                CategoryAdded(null, args);
            }

            return(category);
        }
예제 #3
0
 void CategoryManager_CategoryAdded(object sender, Assets.CategoryManagerEventArgs e)
 {
     cbCategories.Items.Add(e.Category);
 }