コード例 #1
0
        private void Go_Click(object sender, RoutedEventArgs e)
        {
            IFileOrganizer orgainizer;
            if(IsVideos.IsChecked.Value)
                orgainizer = new VideoOrganizer();
            else
                orgainizer = new PhotoOrganizer();

            //get the source and destination
            orgainizer.Source = Source.Text;
            orgainizer.Destination = Destination.Text == "" ? Source.Text : Destination.Text;
            orgainizer.IsCopy = IsCopy.IsChecked.Value;
            Utilities.Log("Source: " + orgainizer.Source);
            Utilities.Log("Destination: " + orgainizer.Destination);

            orgainizer.CreateStructure();
            orgainizer.OrganizeFiles();
        }
コード例 #2
0
        private void Go_Click(object sender, RoutedEventArgs e)
        {
            IFileOrganizer orgainizer;

            if (IsVideos.IsChecked.Value)
            {
                orgainizer = new VideoOrganizer();
            }
            else
            {
                orgainizer = new PhotoOrganizer();
            }

            //get the source and destination
            orgainizer.Source      = Source.Text;
            orgainizer.Destination = Destination.Text == "" ? Source.Text : Destination.Text;
            orgainizer.IsCopy      = IsCopy.IsChecked.Value;
            Utilities.Log("Source: " + orgainizer.Source);
            Utilities.Log("Destination: " + orgainizer.Destination);

            orgainizer.CreateStructure();
            orgainizer.OrganizeFiles();
        }