Beispiel #1
0
        /// <summary>
        ///   取消下载
        /// </summary>
        public void CancelDownload()
        {
            StopAllCoroutines();

            if (verifier_ != null)
            {
                verifier_.Abort();
                verifier_ = null;
            }
            if (ab_download_ != null)
            {
                ab_download_.Cancel();
                ab_download_ = null;
            }

            UpdateState(emState.Cancel);
            Done();
        }
Beispiel #2
0
        /// <summary>
        ///   取消更新
        /// </summary>
        public void CancelUpdate()
        {
            StopAllCoroutines();

            if (verifier_ != null)
            {
                verifier_.Abort();
                verifier_ = null;
            }
            if (file_download_ != null)
            {
                file_download_.Cancel();
                file_download_ = null;
            }
            if (ab_download_ != null)
            {
                ab_download_.Cancel();
                ab_download_ = null;
            }
            SaveDownloadCacheData();
            UpdateState(emState.Cancel);
            Done();
        }