BackgroundLoading() public method

public BackgroundLoading ( RunFunction newFunction ) : void
newFunction RunFunction
return void
コード例 #1
0
ファイル: PicofDay.cs プロジェクト: jotjot/NPOD
        private void imagesMenuItem_Click(object sender, EventArgs e)
        {
            if (GlobalVariables.LoggingEnabled)
            {
                ExceptionManager.WriteInformation("Images option selected.");
            }
            var processHelper = new ProcessHelper();

            processHelper.BackgroundLoading(TestInternetConnection);
            processHelper.Start();

            if (GlobalVariables.LoggingEnabled)
            {
                ExceptionManager.WriteInformation("Checking internet connectivity");
            }
            //Present the message that an internet connection is required
            if (!_internetAvailable)
            {
                MessageBox.Show(Resources.InternetRequiredMessage, Resources.InternetRequiredTitle, MessageBoxButtons.OK, MessageBoxIcon.Information);
                return;
            }

            var imagesForm = new ImagesForm();

            imagesForm.ShowDialog();
            UpdateControlContent();
        }
コード例 #2
0
ファイル: PicofDay.cs プロジェクト: jotjot/NPOD
        private void updateMenuItem_Click(object sender, EventArgs e)
        {
            if (GlobalVariables.LoggingEnabled)
            {
                ExceptionManager.WriteInformation("Update has been requested.");
            }
            var processHelper = new ProcessHelper();

            processHelper.BackgroundLoading(TestInternetConnection);
            processHelper.Start();

            if (GlobalVariables.LoggingEnabled)
            {
                ExceptionManager.WriteInformation("Checking internet connectivity");
            }
            if (!_internetAvailable)
            {
                MessageBox.Show(Resources.InternetRequiredMessage, Resources.InternetRequiredTitle, MessageBoxButtons.OK, MessageBoxIcon.Information);
                return;
            }

            UpdateContent();
        }
コード例 #3
0
ファイル: PicofDay.cs プロジェクト: BillCacy/NPOD
        private void updateMenuItem_Click(object sender, EventArgs e)
        {
            if (GlobalVariables.LoggingEnabled) ExceptionManager.WriteInformation("Update has been requested.");
            var processHelper = new ProcessHelper();
            processHelper.BackgroundLoading(TestInternetConnection);
            processHelper.Start();

            if (GlobalVariables.LoggingEnabled) ExceptionManager.WriteInformation("Checking internet connectivity");
            if (!_internetAvailable)
            {
                MessageBox.Show(Resources.InternetRequiredMessage, Resources.InternetRequiredTitle, MessageBoxButtons.OK, MessageBoxIcon.Information);
                return;
            }

            UpdateContent();
        }
コード例 #4
0
ファイル: PicofDay.cs プロジェクト: BillCacy/NPOD
        private void imagesMenuItem_Click(object sender, EventArgs e)
        {
            if (GlobalVariables.LoggingEnabled) ExceptionManager.WriteInformation("Images option selected.");
            var processHelper = new ProcessHelper();
            processHelper.BackgroundLoading(TestInternetConnection);
            processHelper.Start();

            if (GlobalVariables.LoggingEnabled) ExceptionManager.WriteInformation("Checking internet connectivity");
            //Present the message that an internet connection is required
            if (!_internetAvailable)
            {
                MessageBox.Show(Resources.InternetRequiredMessage, Resources.InternetRequiredTitle, MessageBoxButtons.OK, MessageBoxIcon.Information);
                return;
            }

            var imagesForm = new ImagesForm();
            imagesForm.ShowDialog();
            UpdateControlContent();
        }