Exemple #1
0
        private void Positions_SelectionChangeCommitted(object sender, EventArgs e)
        {
            if (selectedCollection != null)
            {
                ChampionCollection newCollection = getSelectedList();

                if (newCollection != null)
                {

                    selectedCollection.Hide();

                    selectedCollection = newCollection;

                    selectedCollection.Print(textSeaarchBox.Text);
                }
            }
            SetFormState(Form1State.ListsView);
        }
Exemple #2
0
        /// <summary>
        /// initListCollection assumes that the clast list collection has not been loaded or has just been reloaded from a file.
        /// It's job is to set all apropriate variables correctly, unsuring that the screen will load correctly with the new data.
        /// </summary>
        private void initListCollection()
        {
            if (collectionList == null)
            {
                MessageBox.Show("Awww shit n***a");
            }
            else
            {
                foreach (ChampionCollection List in collectionList)
                {

                    List.AddControlPanel(ref this.controlPanel);
                    List.AddFormReference(this);

                    if (List.Name == Constants.ALL_CHAMPIONS)
                    {
                        List.AddContextMenu(this.AllChampsContextMenu);
                        selectedCollection = List;
                        allChampionsCollection = List;
                        allChampionsCollection.Sort();

                    }
                    else
                    {
                        List.AddContextMenu(this.CustomListsStrip);
                    }
                }

            }

            selectedChampion = null;
            updateListCollectionDropdown();
            BuildContextMenu();
            SetFormState(Form1State.InitialView);

            selectedCollection.Print("");
        }