Example #1
0
        private void submitButton_Click(object sender, EventArgs e)
        {
            if (playbackComponentRadioButton.Checked)
            {
                PlaybackHandler playbackHandler = new PlaybackHandler(new RichTextBoxOutput(componentTypeMenuRichTextBox));
                playbackHandler.ShowMenuOfPlaybackComponents();
            }

            if (chargerRadioButton.Checked)
            {
                ChargerHandler chargerHandler = new ChargerHandler(new RichTextBoxOutput(componentTypeMenuRichTextBox));
                chargerHandler.ShowMenuOfChargerComponents();
            }

            if (removableStorageRadioButton.Checked)
            {
                StorageHandler storageHandler = new StorageHandler(new RichTextBoxOutput(componentTypeMenuRichTextBox));
                storageHandler.ShowMenuOfStorages();
            }

            if (simCardRadioButton.Checked)
            {
                SimCardHandler simCardHandler = new SimCardHandler(new RichTextBoxOutput(componentTypeMenuRichTextBox));
                simCardHandler.ShowMenuOfSimCards();
            }

            chosenComponentTypeIndex.Text = "";
            outputOfSettingAndRunningComponentRichTextBox.Text = "";
        }
Example #2
0
        public void GetAndProcessUserSelectionOfPlayback(SimCorpMobile simCorpMobile)
        {
            PlaybackHandler playbackHandler = new PlaybackHandler(Output);

            string enteredPlaybackTypeIndex = Input.ReadLine();

            try
            {
                PlaybackComponentTypes playbackTypeIndex = playbackHandler.GetPlaybackType(enteredPlaybackTypeIndex);
                IPlayback playbackComponent = playbackHandler.GetPlayback(playbackTypeIndex);
                playbackHandler.SetAndRunPlayback(simCorpMobile, playbackComponent);
            }
            catch (Exception e)
            {
                Output.Write(e.Message);
            }
        }
Example #3
0
        public void ShowMenuOfPlaybacks()
        {
            PlaybackHandler playbackHandler = new PlaybackHandler(Output);

            playbackHandler.ShowMenuOfPlaybackComponents();
        }
 void Start()
 {
     _PlaybackHandler = GetComponentInParent <PlaybackHandler>();
     m_Play           = _PlaybackHandler.m_play;
     m_togglechange   = _PlaybackHandler.m_togglechange;
 }