コード例 #1
0
 protected virtual void OnCopyProgressChanged(CopyProgressChangedEventArgs e)
 {
     if (this.CopyProgressChanged == null)
     {
         return;
     }
     this.CopyProgressChanged((object)this, e);
 }
コード例 #2
0
        public void DirectoryMove(string sourceDirName, string destDirName, bool moveSubDirs = false)
        {
            int filesToCopy = FilesToCopy(sourceDirName, moveSubDirs, new List <string>());

            eventArgs = new CopyProgressChangedEventArgs(0, null, 0, filesToCopy);
            DirectoryMoveInternal(sourceDirName, destDirName, moveSubDirs);
            Directory.Delete(sourceDirName, true);
        }
コード例 #3
0
        public void DirectoryCopy(string sourceDirName, string destDirName, bool copySubDirs = false,
                                  List <string> ignoredFiles = null)
        {
            if (ignoredFiles == null)
            {
                ignoredFiles = new List <string>();
            }
            int filesToCopy = FilesToCopy(sourceDirName, copySubDirs, ignoredFiles);

            eventArgs = new CopyProgressChangedEventArgs(0, null, 0, filesToCopy);
            DirectoryCopyInternal(sourceDirName, destDirName, copySubDirs, ignoredFiles);
        }