Exemplo n.º 1
0
        public FormFileNamerPreferences(Preferences prefs)
        {
            _userPrefs = prefs;
            _prefsCopy = _userPrefs.Clone();

            _movieJob = MockJobFactory.CreateMovieJob();
            _movieNamer = new FileNamer(_movieJob, _prefsCopy);

            _tvShowJob = MockJobFactory.CreateTVShowJob();
            _tvShowNamer = new FileNamer(_tvShowJob, _prefsCopy);

            InitializeComponent();
            Load += OnLoad;
            this.EnableSelectAll();
        }
Exemplo n.º 2
0
        public Preferences CopyFrom(Preferences other)
        {
            Movies.CopyFrom(other.Movies);
            TVShows.CopyFrom(other.TVShows);

            Codecs.Clear();
            foreach (var k in other.Codecs.Keys)
            {
                Codecs[k] = other.Codecs[k];
            }

            ReplaceSpaces = other.ReplaceSpaces;
            ReplaceSpacesWith = other.ReplaceSpacesWith;

            return this;
        }
Exemplo n.º 3
0
 public FileNamer(Job job, Preferences prefs)
 {
     _job = job;
     _prefs = prefs;
 }
Exemplo n.º 4
0
 private void SavePreferences(Preferences prefs)
 {
     PluginUtils.SavePreferences(AssemblyInfo, prefs);
 }
Exemplo n.º 5
0
 protected bool Equals(Preferences other)
 {
     return Equals(Movies, other.Movies) &&
            Equals(TVShows, other.TVShows) &&
            Codecs.SequenceEqual(other.Codecs) &&
            ReplaceSpaces.Equals(other.ReplaceSpaces) &&
            string.Equals(ReplaceSpacesWith, other.ReplaceSpacesWith);
 }