private void btnCancel_Click(object sender, EventArgs e)
        {
            IList <WebSiteInfo> selectedList = GetStopList();

            foreach (WebSiteInfo webSiteInfo in selectedList)
            {
                AbstractDownLoader.StopTask(webSiteInfo);
                webSiteInfo.Status = StatusCode.Wait;
            }
        }
 public void OnDisconnection()
 {
     logger.Info("开始清空正在下载的进程...");
     AbstractDownLoader.ClearDownLoader();
     logger.Info("清空正在下载的进程结束.");
     logger.Info("开始保存配置文件...");
     ConfigManager.SaveProductWebSiteInfo(aliDownloader.ProductWebSiteInfoList);
     logger.Info("保存配置文件结束.");
     DeleteCoreFiles();
 }
Exemple #3
0
 private void toolStripButton1_Click(object sender, EventArgs e)
 {
     if (MessageBox.Show(this, "你确定要删除这些任务么?", "警告", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes)
     {
         foreach (WebSiteInfo webSiteInfo in GetDeleteList())
         {
             AbstractDownLoader.StopTask(webSiteInfo);
             RESOURCE_MANAGER.WebSiteInfoList.Remove(webSiteInfo);
         }
     }
 }
        private void btnDelete_Click(object sender, EventArgs e)
        {
            IList <WebSiteInfo> selectedList = GetSelectedList();

            if (selectedList.Count > 0)
            {
                if (MessageBox.Show(this, "你确定要删除这些任务么?", "警告", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes)
                {
                    foreach (WebSiteInfo webSiteInfo in selectedList)
                    {
                        AbstractDownLoader.StopTask(webSiteInfo);
                        RESOURCE_MANAGER.ProductWebSiteInfoList.Remove(webSiteInfo);
                    }
                }
            }
        }
 public void OnDisconnection()
 {
     AbstractDownLoader.ClearDownLoader();
     ConfigManager.SaveStoreWebSiteInfo(aliDownloader.StoreWebSiteInfoList);
 }