Ejemplo n.º 1
0
 void AfterDownload()
 {
     if (mDownloadWindow != null)
     {
         mDownloadWindow.Hide();
         mDownloadWindow.Dispose();
         mDownloadWindow = null;
     }
 }
Ejemplo n.º 2
0
        private void RemoteActionButton2_Click(object sender, EventArgs e)
        {
            if (mDownloadWindow == null)
            {
                mDownloadWindow = new DownloadPluginProgressWindow();

                mDownloadWindow.Location = System.Windows.Forms.Cursor.Position;

                mDownloadWindow.Show(this);
            }
            try
            {
                if (SelectedRssItem != null && !string.IsNullOrEmpty(SelectedRssItem.DirectLink))
                {
                    // I wrote this for Glue, didn't realize it was also being used by GlueView
#if GLUE
                    try
                    {
                        EditorObjects.IoC.Container.Get <PluginUpdater>().StartDownload(SelectedRssItem.DirectLink, AfterDownload);
                    }
                    catch (Exception exc)
                    {
                        MessageBox.Show("Failed to download plugin\n\n" + exc);
                    }
#endif
                }
            }
            catch (Exception exception)
            {
                MessageBox.Show("Error downloading:\n\n" + exception.Message);
                if (mDownloadWindow != null)
                {
                    mDownloadWindow.Hide();
                    mDownloadWindow.Dispose();
                    mDownloadWindow = null;
                }
            }
        }
Ejemplo n.º 3
0
        void AfterDownload()
        {
            if (mDownloadWindow != null)
            {
                mDownloadWindow.Hide();
                mDownloadWindow.Dispose();
                mDownloadWindow = null;
            }

        }
Ejemplo n.º 4
0
        private void RemoteActionButton2_Click(object sender, EventArgs e)
        {
            if (mDownloadWindow == null)
            {
                mDownloadWindow = new DownloadPluginProgressWindow();

                mDownloadWindow.Location = System.Windows.Forms.Cursor.Position;
                
                mDownloadWindow.Show(this);

            }
            try
            {
                if (SelectedRssItem != null && !string.IsNullOrEmpty(SelectedRssItem.DirectLink))
                {

                    // I wrote this for Glue, didn't realize it was also being used by GlueView
#if GLUE
                    try
                    {
                        EditorObjects.IoC.Container.Get<PluginUpdater>().StartDownload(SelectedRssItem.DirectLink, AfterDownload);
                    }
                    catch (Exception exc)
                    {
                        MessageBox.Show("Failed to download plugin\n\n" + exc);
                    }
#endif
                }
            }
            catch(Exception exception)
            {
                MessageBox.Show("Error downloading:\n\n" + exception.Message);
                if (mDownloadWindow != null)
                {
                    mDownloadWindow.Hide();
                    mDownloadWindow.Dispose();
                    mDownloadWindow = null;
                }
            }
        }