コード例 #1
0
        /// <summary>
        /// Form loader handler
        /// </summary>
        /// <param name="sender">event sender</param>
        /// <param name="e">event args</param>
        private void Form_Load(object sender, EventArgs e)
        {
            updateUserProfileInfo();
            _dialogCommon.OnLoad();

            PanelCommon.AnimationManager.Start(PanelCommon.RootWidget);
        }
コード例 #2
0
 /// <summary>
 /// Form has been loaded
 /// </summary>
 private void WindowMoveResizeScannerForm_Load(object sender, EventArgs e)
 {
     _dialogCommon.OnLoad();
     EnumWindows.RestoreFocusToTopWindow(Handle.ToInt32());
     setMoveResizeMode();
     PanelCommon.AnimationManager.Start(PanelCommon.RootWidget);
 }
コード例 #3
0
ファイル: PhraseEditorForm.cs プロジェクト: zezo010/acat
        /// <summary>
        /// Form has been loaded. Perform initialization
        /// </summary>
        /// <param name="sender">event sender</param>
        /// <param name="e">event args</param>
        private void PhraseEditorForm_Load(object sender, EventArgs e)
        {
            Text             = R.GetString("PhraseEditor");
            labelPhrase.Text = R.GetString("Phrase") + ":";

            float currentAspectRatio = (float)ClientSize.Height / ClientSize.Width;

            if (_designTimeAspectRatio != 0.0f && currentAspectRatio != _designTimeAspectRatio)
            {
                ClientSize = new System.Drawing.Size(ClientSize.Width, (int)(_designTimeAspectRatio * ClientSize.Width));
            }

            PhraseSpeakAgent.Instance.EvtCommandEnabled += Instance_EvtCommandEnabled;
            textBoxPhrase.TextChanged += TextBoxPhrase_TextChanged;

            textBoxPhrase.KeyDown += TextBoxPhrase_KeyDown;
            _windowActiveWatchdog  = new WindowActiveWatchdog(this);

            initWidgetSettings();

            _dialogCommon.OnLoad();

            buttonOKWidget = _dialogCommon.RootWidget.Finder.FindChild(buttonOK.Handle);

            updateUI();

            PanelCommon.AnimationManager.Start(PanelCommon.RootWidget);
        }
コード例 #4
0
        /// <summary>
        /// Form loader handler
        /// </summary>
        /// <param name="sender">event sender</param>
        /// <param name="e">event args</param>
        private void Form_Load(object sender, EventArgs e)
        {
            updateUserProfileInfo();
            _dialogCommon.OnLoad();

            _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
        }
コード例 #5
0
ファイル: PhraseListEditForm.cs プロジェクト: zezo010/acat
        private void PhraseListEditForm_Load(object sender, EventArgs e)
        {
            float currentAspectRatio = (float)ClientSize.Height / ClientSize.Width;

            if (_designTimeAspectRatio != 0.0f && currentAspectRatio != _designTimeAspectRatio)
            {
                ClientSize = new System.Drawing.Size(ClientSize.Width, (int)(_designTimeAspectRatio * ClientSize.Width));
            }

            Text = R.GetString("EditPhrases");

            labelFavoritePhrase.Text = "* " + R.GetString("FavoritePhrase");

            _phrases = Phrases.Load();

            foreach (var phrase in _phrases.PhraseList)
            {
                phraseAdd(phrase);
            }

            listBoxPhrases.Focus();
            if (listBoxPhrases.Items.Count > 0)
            {
                listBoxPhrases.SelectedIndex = 0;
            }

            _windowActiveWatchdog = new WindowActiveWatchdog(this);

            _dialogCommon.OnLoad();

            PanelCommon.AnimationManager.Start(PanelCommon.RootWidget);
        }
コード例 #6
0
        /// <summary>
        /// Form has been loaded
        /// </summary>
        void AlternatePronunciationDataForm_Load(object sender, EventArgs e)
        {
            Log.Debug("Entering...");
            _windowActiveWatchdog = new WindowActiveWatchdog(this);

            _dialogCommon.OnLoad();

            _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());

            // populate listview from xml config file
            ImportPronunciationIntoListView(listViewAP, true);

            // select the first item by default
            const int DEFAULT_INITIAL_LISTVIEW_POSITION = 0;

            if (listViewAP.Items.Count > 0)
            {
                listViewAP.Items[DEFAULT_INITIAL_LISTVIEW_POSITION].Selected = true; // DEFAULT_INITIAL_LISTVIEW_POSITION;
            }
            else
            {
                Log.Debug("did not load any items!");
            }

            listViewAP.AllowColumnReorder = false;
            listViewAP.AllowDrop          = false;
            listViewAP.MultiSelect        = false;
            listViewAP.FullRowSelect      = true;

            setButtonStates();
        }
コード例 #7
0
ファイル: YesNoDialogForm.cs プロジェクト: zezo010/acat
        /// <summary>
        /// Form has been loaded
        /// </summary>
        /// <param name="sender">event sender</param>
        /// <param name="e">event args</param>
        private void Form_Load(object sender, EventArgs e)
        {
            _dialogCommon.OnLoad();

            initialize();

            PanelCommon.AnimationManager.Start(PanelCommon.RootWidget);
        }
コード例 #8
0
        /// <summary>
        /// Form has been loaded
        /// </summary>
        void AsterScreenTemplateForm_Load(object sender, EventArgs e)
        {
            _windowActiveWatchdog = new WindowActiveWatchdog(this);
            initWidgetSettings();

            _dialogCommon.OnLoad();
            _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
        }
コード例 #9
0
        /// <summary>
        /// Form has been loaded
        /// </summary>
        private void ScannerSettingsForm_Load(object sender, EventArgs e)
        {
            _dialogCommon.OnLoad();

            subscribeToEvents();

            _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
        }
コード例 #10
0
ファイル: YesNoDialogForm2.cs プロジェクト: angellcq/src
        /// <summary>
        /// Form has been loaded
        /// </summary>
        /// <param name="sender">event sender</param>
        /// <param name="e">event args</param>
        private void Form_Load(object sender, EventArgs e)
        {
            _dialogCommon.OnLoad();

            initialize();

            _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
        }
コード例 #11
0
ファイル: GeneralSettingsForm.cs プロジェクト: zezo010/acat
        /// <summary>
        /// Form has been loaded. Initialize the form
        /// </summary>
        private void GeneralSettingsForm_Load(object sender, EventArgs e)
        {
            populateFormText();

            _dialogCommon.OnLoad();

            subscribeToEvents();

            PanelCommon.AnimationManager.Start(PanelCommon.RootWidget);
        }
コード例 #12
0
        /// <summary>
        /// Form has been loaded. Initlialize the controls
        /// on the form
        /// </summary>
        private void TextToSpeechSettingsForm_Load(object sender, EventArgs e)
        {
            lblVolumeText.Text    = _initialVolume.RangeMin + " to " + _initialVolume.RangeMax;
            lblRateText.Text      = _initialRate.RangeMin + " to " + _initialRate.RangeMax;
            lblPitchText.Text     = _initialPitch.RangeMin + " to " + _initialPitch.RangeMax;
            lblTTSEngineName.Text = Context.AppTTSManager.ActiveEngine.Descriptor.Name;

            _windowActiveWatchdog = new WindowActiveWatchdog(this);
            _dialogCommon.OnLoad();
            subscribeToEvents();
            _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
        }
コード例 #13
0
        /// <summary>
        /// Form has been loaded. Initlialize the controls
        /// on the form
        /// </summary>
        private void TextToSpeechSettingsForm_Load(object sender, EventArgs e)
        {
            populateFormText();

            lblVolumeText.Text    = String.Format(R.GetString("RangeFromTo"), _initialVolume.RangeMin, _initialVolume.RangeMax);
            lblRateText.Text      = String.Format(R.GetString("RangeFromTo"), _initialRate.RangeMin, _initialRate.RangeMax);
            lblPitchText.Text     = String.Format(R.GetString("RangeFromTo"), _initialPitch.RangeMin, _initialPitch.RangeMax);
            lblTTSEngineName.Text = Context.AppTTSManager.ActiveEngine.Descriptor.Name;

            _windowActiveWatchdog = new WindowActiveWatchdog(this);
            _dialogCommon.OnLoad();
            subscribeToEvents();
            PanelCommon.AnimationManager.Start(PanelCommon.RootWidget);
        }
コード例 #14
0
ファイル: ResizeScannerForm.cs プロジェクト: angellcq/src
        /// <summary>
        /// Form has been loaded. Initialize resources
        /// </summary>
        private void ResizeScannerScreen_Load(object sender, EventArgs e)
        {
            var screen = Context.AppPanelManager.CreatePanel(PanelClasses.Alphabet) as IPanel;

            _previewScreen = screen as Form;

            _previewScreenInterface             = screen as IScannerPreview;
            _previewScreenInterface.PreviewMode = true;
            _previewScreen.Show();

            Windows.SetWindowPosition(_previewScreen, Context.AppWindowPosition);

            _dialogCommon.OnLoad();
            _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
        }
コード例 #15
0
        /// <summary>
        /// Form has been loaded. Initialize
        /// </summary>
        private void MuteScreenSettingsForm_Load(object sender, EventArgs e)
        {
            tbPINCode.TextChanged += tbPINCode_TextChanged;
            tbPINCode.KeyPress    += tbPINCode_KeyPress;

            _dialogCommon.OnLoad();

            Invoke(new MethodInvoker(delegate()
            {
                _windowActiveWatchdog = new WindowActiveWatchdog(this);
            }));

            subscribeToEvents();

            _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
        }
コード例 #16
0
        /// <summary>
        /// Form has been loaded. Initialize
        /// </summary>
        private void ScreenLockSettingsForm_Load(object sender, EventArgs e)
        {
            populateFormText();

            tbPINCode.TextChanged += tbPINCode_TextChanged;
            tbPINCode.KeyPress    += textBoxPinCode_KeyPress;

            _dialogCommon.OnLoad();

            Invoke(new MethodInvoker(delegate
            {
                _windowActiveWatchdog = new WindowActiveWatchdog(this);
            }));

            subscribeToEvents();

            PanelCommon.AnimationManager.Start(PanelCommon.RootWidget);
        }
コード例 #17
0
        /// <summary>
        /// Form has been loaded. Initializes resources
        /// </summary>
        private void ResizeScannerScreen_Load(object sender, EventArgs e)
        {
            var panel = Context.AppPanelManager.CreatePanel(PanelClasses.Alphabet) as IPanel;

            _previewScanner = panel as Form;

            _previewScreenInterface             = panel as IScannerPreview;
            _previewScreenInterface.PreviewMode = true;

            var scannerPanel = panel as IScannerPanel;

            // we are going to manually set the position of the scanner below
            scannerPanel.ScannerCommon.PositionSizeController.AutoPosition = false;

            _previewScanner.Show();

            var position = Context.AppWindowPosition;

            if (position == Windows.WindowPosition.CenterScreen)
            {
                position = CoreGlobals.AppPreferences.ScannerPosition;
            }

            if (position == Windows.WindowPosition.CenterScreen)
            {
                position = Windows.WindowPosition.MiddleRight;
            }

            var scanner = _previewScanner as IScannerPanel;

            scanner.ScannerCommon.PositionSizeController.ManualPosition = position;

            _windowOverlapWatchdog = new WindowOverlapWatchdog(this, true);

            _dialogCommon.OnLoad();
            _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
        }
コード例 #18
0
        /// <summary>
        /// Form has been loaded. Perform initialization
        /// </summary>
        /// <param name="sender">event sender</param>
        /// <param name="e">event args</param>
        private void AbbreviationsEditorForm_Load(object sender, EventArgs e)
        {
            if (Add)
            {
                Windows.SetText(labelTitle, "Add Abbreviation");
                var widget = _dialogCommon.GetRootWidget().Finder.FindChild("lblDelete");
                if (widget != null)
                {
                    widget.Enabled = false;
                }
            }
            else
            {
                Windows.SetText(labelTitle, "Edit/Delete Abbreviation");
            }

            _windowActiveWatchdog = new WindowActiveWatchdog(this);

            initWidgetSettings();

            _dialogCommon.OnLoad();

            _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
        }
コード例 #19
0
 /// <summary>
 /// Form has been loaded. Start animation
 /// </summary>
 /// <param name="sender">event sender</param>
 /// <param name="e">event args</param>
 private void AsterLaunchpad_Load(object sender, EventArgs e)
 {
     _dialogCommon.OnLoad();
     _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
 }
コード例 #20
0
 /// <summary>
 /// Form has been loaded
 /// </summary>
 private void ResizeScannerScreen_Load(object sender, EventArgs e)
 {
     _dialogCommon.OnLoad();
     _dialogCommon.GetAnimationManager().Start(_dialogCommon.GetRootWidget());
 }