Inheritance: System.Windows.Forms.Form, IScannerPanel, IExtension
Esempio n. 1
0
        /// <summary>
        /// Close the launchapp scanner
        /// </summary>
        private void closeScanner()
        {
            if (_launchAppScanner != null)
            {
                Windows.CloseForm(_launchAppScanner);

                _launchAppScanner = null;
            }
        }
Esempio n. 2
0
        /// <summary>
        /// Release resources and close
        /// </summary>
        /// <param name="sender">event sender</param>
        /// <param name="e">event args</param>
        private void _form_FormClosing(object sender, FormClosingEventArgs e)
        {
            if (_launchAppScanner != null)
            {
                _launchAppScanner.FormClosing    -= _form_FormClosing;
                _launchAppScanner.EvtQuit        -= _launchAppScanner_EvtQuit;
                _launchAppScanner.EvtLaunchApp   -= _launchAppScanner_EvtLaunchApp;
                _launchAppScanner.EvtShowScanner -= launchAppScanner_EvtShowScanner;
            }

            _launchAppScanner = null;
        }
Esempio n. 3
0
        /// <summary>
        /// Invoked when the Functional agent is activated.  This is
        /// the entry point.
        /// </summary>
        /// <returns>true on success</returns>
        public override bool Activate()
        {
            ExitCode          = CompletionCode.ContextSwitch;
            _appToLaunchInfo  = null;
            _launchAppScanner = Context.AppPanelManager.CreatePanel("LaunchAppScanner") as LaunchAppScanner;

            if (_launchAppScanner != null)
            {
                _launchAppScanner.FormClosing    += _form_FormClosing;
                _launchAppScanner.EvtQuit        += _launchAppScanner_EvtQuit;
                _launchAppScanner.EvtLaunchApp   += _launchAppScanner_EvtLaunchApp;
                _launchAppScanner.EvtShowScanner += launchAppScanner_EvtShowScanner;

                Context.AppPanelManager.ShowDialog(_launchAppScanner);
            }

            return(true);
        }
        /// <summary>
        /// Close the launchapp scanner
        /// </summary>
        private void closeScanner()
        {
            if (_launchAppScanner != null)
            {
                Windows.CloseForm(_launchAppScanner);

                _launchAppScanner = null;
            }
        }
        /// <summary>
        /// Release resources and close
        /// </summary>
        /// <param name="sender">event sender</param>
        /// <param name="e">event args</param>
        private void _form_FormClosing(object sender, FormClosingEventArgs e)
        {
            if (_launchAppScanner != null)
            {
                _launchAppScanner.FormClosing -= _form_FormClosing;
                _launchAppScanner.EvtQuit -= _launchAppScanner_EvtQuit;
                _launchAppScanner.EvtLaunchApp -= _launchAppScanner_EvtLaunchApp;
                _launchAppScanner.EvtShowScanner -= launchAppScanner_EvtShowScanner;
            }

            _launchAppScanner = null;
        }
        /// <summary>
        /// Invoked when the Functional agent is activated.  This is
        /// the entry point.
        /// </summary>
        /// <returns>true on success</returns>
        public override bool Activate()
        {
            ExitCode = CompletionCode.ContextSwitch;
            _appToLaunchInfo = null;
            _launchAppScanner = Context.AppPanelManager.CreatePanel("LaunchAppScanner") as LaunchAppScanner;

            if (_launchAppScanner != null)
            {
                _launchAppScanner.FormClosing += _form_FormClosing;
                _launchAppScanner.EvtQuit += _launchAppScanner_EvtQuit;
                _launchAppScanner.EvtLaunchApp += _launchAppScanner_EvtLaunchApp;
                _launchAppScanner.EvtShowScanner += launchAppScanner_EvtShowScanner;

                Context.AppPanelManager.ShowDialog(_launchAppScanner);
            }

            return true;
        }