Ejemplo n.º 1
0
 private void Initialize(bool isDummy)
 {
     IsDummy         = isDummy;
     MediaCount      = new MediaCount();
     TotalMediaCount = new MediaCount();
     Files           = new List <MediaFile>();
     SubFolders      = new List <MediaFolder>();
 }
Ejemplo n.º 2
0
        private void Initialize(string path, Gallery gallery)
        {
            ID = null;
            string volumeLetter, volumeName, volumeSerial;

            FileSystemHandler.GetVolumeInfo(path, out volumeLetter, out volumeName, out volumeSerial);
            VolumeLetter = volumeLetter;
            VolumeName   = volumeName;
            VolumeSerial = volumeSerial;
            Path         = path.Substring(2);
            CreateID();
            Gallery    = gallery;
            RootFolder = new MediaFolder(Path, null, null, this);
            MediaCount = new MediaCount();
            ScanDate   = DateTime.MinValue;
        }
Ejemplo n.º 3
0
 public MediaCount UpdateMediaCount()
 {
     TotalMediaCount = MediaCount = new MediaCount(Files.Count(file => file is ImageFile), Files.Count(file => file is VideoFile));
     SubFolders.ForEach(folder => TotalMediaCount += folder.UpdateMediaCount());
     return(TotalMediaCount);
 }