// Catalog.GetString ("Music Library") public MusicLibrarySource() : base(Catalog.GetString("Music"), "Library", 40) { MediaTypes = TrackMediaAttributes.Music | TrackMediaAttributes.AudioStream; NotMediaTypes = TrackMediaAttributes.Podcast | TrackMediaAttributes.VideoStream | TrackMediaAttributes.AudioBook; Properties.SetStringList("Icon.Name", "audio-x-generic", "source-library"); // Migrate the old library-location schema, if necessary if (DatabaseConfigurationClient.Client.Get <int> ("MusicLibraryLocationMigrated", 0) != 1) { string old_location = OldLocationSchema.Get(); if (!String.IsNullOrEmpty(old_location)) { BaseDirectory = old_location; } DatabaseConfigurationClient.Client.Set <int> ("MusicLibraryLocationMigrated", 1); } Section file_system = PreferencesPage.Add(new Section("file-system", Catalog.GetString("File System Organization"), 5)); file_system.Add(new SchemaPreference <string> (LibrarySchema.FolderPattern, Catalog.GetString("Folder hie_rarchy"))); file_system.Add(new SchemaPreference <string> (LibrarySchema.FilePattern, Catalog.GetString("File _name"))); PreferencesPage.Add(new Section("misc", Catalog.GetString("Miscellaneous"), 10)); }
// Catalog.GetString ("Music Library") public MusicLibrarySource() : base(Catalog.GetString("Music"), "Library", 40) { MediaTypes = TrackMediaAttributes.Music | TrackMediaAttributes.AudioStream; NotMediaTypes = TrackMediaAttributes.Podcast | TrackMediaAttributes.VideoStream | TrackMediaAttributes.AudioBook; Properties.SetStringList("Icon.Name", "audio-x-generic", "source-library"); Properties.Set <string> ("SearchEntryDescription", Catalog.GetString("Search your music")); // Migrate the old library-location schema, if necessary if (DatabaseConfigurationClient.Client.Get <int> ("MusicLibraryLocationMigrated", 0) != 1) { string old_location = OldLocationSchema.Get(); if (!String.IsNullOrEmpty(old_location)) { BaseDirectory = old_location; } DatabaseConfigurationClient.Client.Set <int> ("MusicLibraryLocationMigrated", 1); } SetFileNamePattern(MusicFileNamePattern); Section misc = PreferencesPage.Add(new Section("misc", Catalog.GetString("Miscellaneous"), 10)); misc.Add(new SchemaPreference <bool> (LibrarySchema.SortByAlbumYear, Catalog.GetString("_Sort an artist's albums by year, not title"), null, delegate { DatabaseTrackModel.Resort(); DatabaseTrackModel.Reload(); } )); }
public void WhenIEnterMyGasEnergyDetailsIncludingMyAnd(string gasTariff, string howIPay) { _energyPage.SelectGasTariff(gasTariff); _energyPage.SelectHowYouPayForGas(howIPay); if (_user.isGasMainSourceOfHeating) { _energyPage.ClickGasIsMainSourceOfHeating(); } else { _energyPage.ClickGasIsNotMainSourceOfHeating(); } if (_user.measureGasUseIn == "kWh") { _energyPage.ClickGasUsageInkWh(); } else { _energyPage.ClickGasUsageInPound(); } _energyPage.EnterGasUsageValue(_user.gasUsesageValue.ToString()); _energyPage.SelectGasUsageInterval(_user.gasUseageIncrement); _energyPage.ClickGasBillDateBox(); _energyPage.PickGasBillDateFromTable(); _preferencesPage = _energyPage.ClickNext(); }
protected void SetFileNamePattern(PathPattern pattern) { PathPattern = pattern; var file_system = PreferencesPage.Add(new Section("file-system", Catalog.GetString("File Organization"), 5)); file_system.Add(new SchemaPreference <string> (pattern.FolderSchema, Catalog.GetString("Folder hie_rarchy"))); file_system.Add(new SchemaPreference <string> (pattern.FileSchema, Catalog.GetString("File _name"))); }
public Preferences(TestStartInfo teststartinfo, DataManager datamanager) { _PreferencesData = new PreferencesData(datamanager); _PreferencesPage = new PreferencesPage(teststartinfo); _ModesData = new ModesData(datamanager); _AvailableEquipmentData = new AvailableEquipmentData(datamanager); _PreferredlaneData = new PreferredlaneData(datamanager); _driver = teststartinfo.Driver; }
public LibrarySource(string label, string name, int order) : base(label, label, name, order) { Properties.SetString("GtkActionPath", "/LibraryContextMenu"); Properties.SetString("RemoveTracksActionLabel", Catalog.GetString("Remove From Library")); IsLocal = true; base_dir_schema = CreateSchema <string> ("library-location", null, "The base directory under which files for this library are stored", null); AfterInitialized(); Section library_section = PreferencesPage.Add(new Section("library-location", SectionName, 2)); library_section.Add(base_dir_schema); }
public PreferencesTests() { var geckoService = FirefoxDriverService.CreateDefaultService(Environment.CurrentDirectory); geckoService.Host = "::1"; var firefoxOptions = new FirefoxOptions { AcceptInsecureCertificates = true }; _driver = new FirefoxDriver(geckoService, firefoxOptions); _page = new PreferencesPage(_driver, "Settings/Preferences"); _loginHelper = new LoginHelper(_driver); _page.Navigate(); }
public void WhenIEnterElectrictyEnergyDetailsIncludingMyAnd(string electricityTariff, string howIPay) { _user.paymentMethod = howIPay; _energyPage.SelectEletricTariff(electricityTariff); if (_user.hasEconomy7Meter) { _energyPage.ClickEconomy7MeterYes(); } else { _energyPage.ClickEconomy7MeterNo(); } _energyPage.SelectHowYouPayForElectric(howIPay); if (_user.isElecticMainSourceOfHeating) { _energyPage.ClickElectricIsMainSourceOfHeating(); } else { _energyPage.ClickElectricIsNotMainSourceOfHeating(); } if (_user.measureElectricalUseIn == "kWh") { _energyPage.ClickUsageInkWh(); } else { _energyPage.ClickUsageInPound(); } _energyPage.EnterElecticUsageValue(_user.electricalUsesageValue.ToString()); _energyPage.SelectElectricalUsageInterval(_user.electricalUseageIncrement); _energyPage.ClickElectricBillDateBox(); _energyPage.PickElectricBillDateFromTable(); _preferencesPage = _energyPage.ClickNext(); }
public LibrarySource(string label, string name, int order) : base(label, label, name, order) { Properties.SetString("GtkActionPath", "/LibraryContextMenu"); Properties.SetString("RemoveSelectedTracksActionLabel", Catalog.GetString("Remove From Library")); Properties.SetString("RemovePlayingTrackActionLabel", Catalog.GetString("Remove From Library")); IsLocal = true; base_dir_schema = CreateSchema <string> ("library-location", null, "The base directory under which files for this library are stored", null); copy_on_import = CreateSchema <bool> ("copy-on-import", false, "Copy files on import", "Copy and rename files to library directory when importing"); move_files = CreateSchema <bool>("move-on-info-save", false, "Move files on info save", "Move files within the library directory when saving track info"); AfterInitialized(); Section library_section = PreferencesPage.Add(new Section("library-location", SectionName, 2)); library_section.Add(base_dir_schema); if (this.HasCopyOnImport || this.HasMoveFiles) { var file_system = PreferencesPage.FindOrAdd( new Section("file-system", Catalog.GetString("File Organization"), 5)); if (this.HasCopyOnImport) { file_system.Add(new SchemaPreference <bool> ( copy_on_import, Catalog.GetString("Co_py files to media folder when importing"))); } if (this.HasMoveFiles) { file_system.Add(new SchemaPreference <bool> ( move_files, Catalog.GetString("_Update file and folder names"), Catalog.GetString("Rename files and folders according to media metadata") )); } } }
public static bool IsSupportedCosmetic(OperatingSystemVersion mininum, OperatingSystemVersion maximum = OperatingSystemVersion.None) => IsSupported(GetVersion(mininum), PreferencesPage.GetCosmeticVersion(), GetVersion(maximum));
public void InitializePage() { _page = new PreferencesPage(); }
public void WhenIEnterMyEnergyDetails() { _energyPage.enterCombinedUsages(_user.electricalUsesageValue.ToString(), _user.gasUsesageValue.ToString()); _preferencesPage = _energyPage.ClickNext(); }