diff --git a/CSharp/Libraries/UniversalEditor.Core/Accessors/FileAccessor.cs b/CSharp/Libraries/UniversalEditor.Core/Accessors/FileAccessor.cs index 42a60355..033a8500 100644 --- a/CSharp/Libraries/UniversalEditor.Core/Accessors/FileAccessor.cs +++ b/CSharp/Libraries/UniversalEditor.Core/Accessors/FileAccessor.cs @@ -41,16 +41,16 @@ namespace UniversalEditor.Accessors _ar = base.MakeReferenceInternal(); _ar.Title = "Local file"; - _ar.ImportOptions.Add(new CustomOptionFile("FileName", "_File name:")); - _ar.ImportOptions.Add(new CustomOptionBoolean("ForceOverwrite", "Force _overwrite if file exists", false, false, false)); - _ar.ImportOptions.Add(new CustomOptionBoolean("AllowWrite", "Open file for _writing", false, false, false)); + _ar.ImportOptions.Add(new CustomOptionFile(nameof(FileName), "_File name:")); + _ar.ImportOptions.Add(new CustomOptionBoolean(nameof(ForceOverwrite), "Force _overwrite if file exists", false, false, false)); + _ar.ImportOptions.Add(new CustomOptionBoolean(nameof(AllowWrite), "Open file for _writing", false, false, false)); - CustomOptionFile cofExportFileName = new CustomOptionFile("FileName", "_File name:"); + CustomOptionFile cofExportFileName = new CustomOptionFile(nameof(FileName), "_File name:"); cofExportFileName.DialogMode = CustomOptionFileDialogMode.Save; _ar.ExportOptions.Add(cofExportFileName); - _ar.ExportOptions.Add(new CustomOptionBoolean("ForceOverwrite", "Force _overwrite if file exists", true, true)); - _ar.ExportOptions.Add(new CustomOptionBoolean("AllowWrite", "Open file for _writing", true, false, false)); + _ar.ExportOptions.Add(new CustomOptionBoolean(nameof(ForceOverwrite), "Force _overwrite if file exists", true, true)); + _ar.ExportOptions.Add(new CustomOptionBoolean(nameof(AllowWrite), "Open file for _writing", true, false, false)); } return _ar; } diff --git a/CSharp/Libraries/UniversalEditor.Essential/DataFormats/Binary/PEM/PEMDataFormat.cs b/CSharp/Libraries/UniversalEditor.Essential/DataFormats/Binary/PEM/PEMDataFormat.cs index 83f8bd35..ad4f46f4 100644 --- a/CSharp/Libraries/UniversalEditor.Essential/DataFormats/Binary/PEM/PEMDataFormat.cs +++ b/CSharp/Libraries/UniversalEditor.Essential/DataFormats/Binary/PEM/PEMDataFormat.cs @@ -20,7 +20,7 @@ namespace UniversalEditor.DataFormats.Binary.PEM _dfr.Capabilities.Add(typeof(BinaryObjectModel), DataFormatCapabilities.All); _dfr.Capabilities.Add(typeof(PlainTextObjectModel), DataFormatCapabilities.All); _dfr.Title = "Privacy-Enhanced Mail encoding"; - _dfr.ExportOptions.Add(new CustomOptionText("Signature", "_Signature")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Signature), "_Signature")); } return _dfr; } diff --git a/CSharp/Libraries/UniversalEditor.Essential/DataFormats/PropertyList/Text/TextPropertyListDataFormat.cs b/CSharp/Libraries/UniversalEditor.Essential/DataFormats/PropertyList/Text/TextPropertyListDataFormat.cs index 749fe47c..9916acc3 100644 --- a/CSharp/Libraries/UniversalEditor.Essential/DataFormats/PropertyList/Text/TextPropertyListDataFormat.cs +++ b/CSharp/Libraries/UniversalEditor.Essential/DataFormats/PropertyList/Text/TextPropertyListDataFormat.cs @@ -15,7 +15,6 @@ namespace UniversalEditor.DataFormats.PropertyList.Text { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(PropertyListObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("Title", "&Title: ", "Text Property List")); } return _dfr; } diff --git a/CSharp/Libraries/UniversalEditor.Essential/DataFormats/PropertyList/UniversalPropertyList/UniversalPropertyListDataFormat.cs b/CSharp/Libraries/UniversalEditor.Essential/DataFormats/PropertyList/UniversalPropertyList/UniversalPropertyListDataFormat.cs index 8722658a..878cffb8 100644 --- a/CSharp/Libraries/UniversalEditor.Essential/DataFormats/PropertyList/UniversalPropertyList/UniversalPropertyListDataFormat.cs +++ b/CSharp/Libraries/UniversalEditor.Essential/DataFormats/PropertyList/UniversalPropertyList/UniversalPropertyListDataFormat.cs @@ -18,7 +18,7 @@ namespace UniversalEditor.DataFormats.PropertyList.UniversalPropertyList { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(PropertyListObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionChoice("FormatVersion", "Format version:", true, new CustomOptionFieldChoice("1.0", 1.0f))); + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(FormatVersion), "Format version:", true, new CustomOptionFieldChoice("1.0", 1.0f))); } return _dfr; } diff --git a/CSharp/Libraries/UniversalEditor.Essential/DataFormats/Shortcut/FreeDesktop/DesktopShortcutDataFormat.cs b/CSharp/Libraries/UniversalEditor.Essential/DataFormats/Shortcut/FreeDesktop/DesktopShortcutDataFormat.cs index c9f2f061..3cf96160 100644 --- a/CSharp/Libraries/UniversalEditor.Essential/DataFormats/Shortcut/FreeDesktop/DesktopShortcutDataFormat.cs +++ b/CSharp/Libraries/UniversalEditor.Essential/DataFormats/Shortcut/FreeDesktop/DesktopShortcutDataFormat.cs @@ -18,11 +18,11 @@ namespace UniversalEditor.DataFormats.Shortcut.FreeDesktop { _dfr = new DataFormatReference(GetType()); _dfr.Capabilities.Add(typeof(ShortcutObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("ApplicationTitle", "&Application title: ")); - _dfr.ExportOptions.Add(new CustomOptionText("GenericTitle", "&Generic title: ")); - _dfr.ExportOptions.Add(new CustomOptionBoolean("HideFromMenus", "&Do not display this entry in menus")); - _dfr.ExportOptions.Add(new CustomOptionBoolean("Deleted", "&Mark this shortcut as being deleted by the user")); - _dfr.ExportOptions.Add(new CustomOptionBoolean("DBusActivatable", "&Enable DBus activation")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(ApplicationTitle), "&Application title: ")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(GenericTitle), "&Generic title: ")); + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(HideFromMenus), "&Do not display this entry in menus")); + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(Deleted), "&Mark this shortcut as being deleted by the user")); + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(DBusActivatable), "&Enable DBus activation")); _dfr.Sources.Add("http://standards.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html"); } return _dfr; diff --git a/CSharp/Plugins/UniversalEditor.Plugins.CRI/DataFormats/FileSystem/CPK/CPKDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.CRI/DataFormats/FileSystem/CPK/CPKDataFormat.cs index 6bb22081..8ff7cfac 100755 --- a/CSharp/Plugins/UniversalEditor.Plugins.CRI/DataFormats/FileSystem/CPK/CPKDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.CRI/DataFormats/FileSystem/CPK/CPKDataFormat.cs @@ -45,8 +45,8 @@ namespace UniversalEditor.Plugins.CRI.DataFormats.FileSystem.CPK { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("VersionString", "_Version string", "CPKMC2.14.00, DLL2.74.00")); - _dfr.ExportOptions.Add(new CustomOptionNumber("FileAlignment", "File _alignment", 2048, 0, 2048)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(VersionString), "_Version string", "CPKMC2.14.00, DLL2.74.00")); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(SectorAlignment), "Sector _alignment", 2048, 0, 2048)); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.ChaosWorks/DataFormats/FileSystem/ChaosWorks/ChaosWorksVOLDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.ChaosWorks/DataFormats/FileSystem/ChaosWorks/ChaosWorksVOLDataFormat.cs index 8044a8ac..1e533900 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.ChaosWorks/DataFormats/FileSystem/ChaosWorks/ChaosWorksVOLDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.ChaosWorks/DataFormats/FileSystem/ChaosWorks/ChaosWorksVOLDataFormat.cs @@ -19,8 +19,8 @@ namespace UniversalEditor.DataFormats.FileSystem.ChaosWorks { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionBoolean("Compressed", "&Compress this archive using the LZRW1 algorithm", true)); - _dfr.ExportOptions.Add(new CustomOptionChoice("FormatVersion", "Format &version", true, new CustomOptionFieldChoice[] + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(Compressed), "&Compress this archive using the LZRW1 algorithm", true)); + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(FormatVersion), "Format &version", true, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice("Version 1 (Fire Fight)", ChaosWorksVOLFormatVersion.V1, true), new CustomOptionFieldChoice("Version 2 (Akimbo, Excessive Speed)", ChaosWorksVOLFormatVersion.V2) diff --git a/CSharp/Plugins/UniversalEditor.Plugins.ChaosWorks/DataFormats/Multimedia/PictureCollection/CWESpriteDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.ChaosWorks/DataFormats/Multimedia/PictureCollection/CWESpriteDataFormat.cs index 97f666b8..e17d2f10 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.ChaosWorks/DataFormats/Multimedia/PictureCollection/CWESpriteDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.ChaosWorks/DataFormats/Multimedia/PictureCollection/CWESpriteDataFormat.cs @@ -19,7 +19,7 @@ namespace UniversalEditor.Plugins.ChaosWorks.DataFormats.Multimedia.PictureColle { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(PictureCollectionObjectModel), DataFormatCapabilities.All); - _dfr.ImportOptions.Add(new CustomOptionFile("ExternalPaletteFileName", "External _palette file name")); + _dfr.ImportOptions.Add(new CustomOptionFile(nameof(ExternalPaletteFileName), "External _palette file name")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Apple/HFS/HFSDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Apple/HFS/HFSDataFormat.cs index 48dd8ce1..964d5de3 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Apple/HFS/HFSDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Apple/HFS/HFSDataFormat.cs @@ -21,9 +21,9 @@ namespace UniversalEditor.DataFormats.FileSystem.Apple.HFS { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("VolumeName", "Volume &name")); - _dfr.ExportOptions.Add(new CustomOptionNumber("VolumeBackupSequenceNumber", "&Backup sequence number", 0, Int16.MinValue, Int16.MaxValue)); - _dfr.ExportOptions.Add(new CustomOptionNumber("VolumeWriteCount", "Volume &write count")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(VolumeName), "Volume &name")); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(VolumeBackupSequenceNumber), "&Backup sequence number", 0, Int16.MinValue, Int16.MaxValue)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(VolumeWriteCount), "Volume &write count")); _dfr.Sources.Add("https://developer.apple.com/legacy/library/documentation/mac/Files/Files-102.html"); _dfr.Sources.Add("http://www.cs.fsu.edu/~baker/devices/lxr/http/source/linux/fs/hfs/hfs.h"); _dfr.Sources.Add("www.fenestrated.net/~macman/mirrors/Apple Technotes (As of 2002)/tn/tn1150.html"); diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Box/BoxDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Box/BoxDataFormat.cs index 19afd1f7..8e26826d 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Box/BoxDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Box/BoxDataFormat.cs @@ -18,14 +18,14 @@ namespace UniversalEditor.DataFormats.FileSystem.Box { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionChoice("NumberSize", "Number size:", true, + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(NumberSize), "Number size:", true, new CustomOptionFieldChoice("8-bit, 1 byte per number", 1), new CustomOptionFieldChoice("16-bit, 2 bytes per number", 2), new CustomOptionFieldChoice("24-bit, 3 bytes per number", 3), new CustomOptionFieldChoice("32-bit, 4 bytes per number", 4, true), new CustomOptionFieldChoice("64-bit, 8 bytes per number", 8))); - _dfr.ExportOptions.Add(new CustomOptionNumber("AllocationSize", "Allocation size: ", 512)); - _dfr.ExportOptions.Add(new CustomOptionText("Comment", "Comment: ")); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(AllocationSize), "Allocation size: ", 512)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Comment), "Comment: ")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/CPIO/CPIODataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/CPIO/CPIODataFormat.cs index 6f17a82a..48bb9393 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/CPIO/CPIODataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/CPIO/CPIODataFormat.cs @@ -18,7 +18,7 @@ namespace UniversalEditor.DataFormats.FileSystem.CPIO _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); _dfr.Sources.Add("http://people.freebsd.org/~kientzle/libarchive/man/cpio.5.txt"); - _dfr.ExportOptions.Add(new CustomOptionChoice("Encoding", "&Encoding: ", true, new CustomOptionFieldChoice[] + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(Encoding), "&Encoding: ", true, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice("Binary (little-endian)", CPIOEncoding.BinaryLittleEndian, true), new CustomOptionFieldChoice("Binary (big-endian)", CPIOEncoding.BinaryBigEndian), diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/DeepSilver/SecretFiles/SPRDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/DeepSilver/SecretFiles/SPRDataFormat.cs index cc323266..5948cf4d 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/DeepSilver/SecretFiles/SPRDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/DeepSilver/SecretFiles/SPRDataFormat.cs @@ -17,8 +17,8 @@ namespace UniversalEditor.DataFormats.FileSystem.DeepSilver.SecretFiles { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionNumber("EncryptionDomain", "Encryption &domain:", 0xbebe2, Int32.MaxValue, Int32.MinValue)); - _dfr.ExportOptions.Add(new CustomOptionNumber("EncryptionSeed", "Encryption &seed:", 0, Int32.MaxValue, Int32.MinValue)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(EncryptionDomain), "Encryption &domain:", 0xbebe2, Int32.MaxValue, Int32.MinValue)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(EncryptionSeed), "Encryption &seed:", 0, Int32.MaxValue, Int32.MinValue)); _dfr.Sources.Add("http://wiki.xentax.com/index.php?title=Secret_Files:_Tunguska_%28Demo%29_SPR"); } return _dfr; diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Eighting/FPK/FPKDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Eighting/FPK/FPKDataFormat.cs index b40f6a87..5d35c63d 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Eighting/FPK/FPKDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Eighting/FPK/FPKDataFormat.cs @@ -16,7 +16,7 @@ namespace UniversalEditor.DataFormats.FileSystem.Eighting.FPK { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionNumber("DataAlignment", "Data &alignment (in bytes): ", 16, 0, UInt32.MaxValue)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(DataAlignment), "Data &alignment (in bytes): ", 16, 0, UInt32.MaxValue)); _dfr.Sources.Add("http://wiki.xentax.com/index.php?title=Bleach_%28PSP%29"); } return _dfr; diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/FARC/FARCDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/FARC/FARCDataFormat.cs index 5e296dcc..870d496e 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/FARC/FARCDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/FARC/FARCDataFormat.cs @@ -45,8 +45,8 @@ namespace UniversalEditor.DataFormats.FileSystem.FARC _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionBoolean("Encrypted", "&Encrypt the data with the specified key")); - _dfr.ExportOptions.Add(new CustomOptionBoolean("Compressed", "&Compress the data with the gzip algorithm")); + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(Encrypted), "&Encrypt the data with the specified key")); + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(Compressed), "&Compress the data with the gzip algorithm")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/FAT/FATDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/FAT/FATDataFormat.cs index af5d7107..b57e65b2 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/FAT/FATDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/FAT/FATDataFormat.cs @@ -39,11 +39,11 @@ namespace UniversalEditor.DataFormats.FileSystem.FAT { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("OEMName", "OEM &name:", "MSDOS5.0", 8)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(OEMName), "OEM &name:", "MSDOS5.0", 8)); #region Bios Parameter Block { - CustomOptionGroup grp = new CustomOptionGroup("BiosParameterBlock", "BIOS parameter block"); + CustomOptionGroup grp = new CustomOptionGroup(nameof(BiosParameterBlock), "BIOS parameter block"); grp.Options.Add(new CustomOptionNumber("BytesPerSector", "&Bytes per sector:", 512, 0, short.MaxValue)); grp.Options.Add(new CustomOptionNumber("SectorsPerCluster", "&Sectors per cluster:", 1, 1, 128)); grp.Options.Add(new CustomOptionNumber("ReservedSectorCount", "&Reserved sectors:", 32, 0, short.MaxValue)); @@ -74,7 +74,7 @@ namespace UniversalEditor.DataFormats.FileSystem.FAT #endregion #region Extended BIOS parameter block { - CustomOptionGroup grp = new CustomOptionGroup("ExtendedBiosParameterBlock", "Extended BIOS parameter block"); + CustomOptionGroup grp = new CustomOptionGroup(nameof(ExtendedBiosParameterBlock), "Extended BIOS parameter block"); grp.Options.Add(new CustomOptionNumber("PhysicalDriveNumber", "Physical drive &number:", 0)); grp.Options.Add(new CustomOptionMultipleChoice("CheckDiskFlags", "CHKDSK &flags:", new CustomOptionFieldChoice("Dirty", FATCheckDiskFlags.Dirty), new CustomOptionFieldChoice("Error", FATCheckDiskFlags.Error))); grp.Options.Add(new CustomOptionNumber("NumberOfHeads", "Number of heads:", 0)); diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/GremlinInteractive/ActuaSoccer/MAD/MADDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/GremlinInteractive/ActuaSoccer/MAD/MADDataFormat.cs index 29407161..f3c9ed59 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/GremlinInteractive/ActuaSoccer/MAD/MADDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/GremlinInteractive/ActuaSoccer/MAD/MADDataFormat.cs @@ -16,12 +16,12 @@ namespace UniversalEditor.DataFormats.FileSystem.GremlinInteractive.ActuaSoccer. { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionChoice("FormatVersion", "Format &version:", true, new CustomOptionFieldChoice[] + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(FormatVersion), "Format &version:", true, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice("Type 1 (includes file names)", MADFormatVersion.Type1, true), new CustomOptionFieldChoice("Type 2 (does not include file names)", MADFormatVersion.Type2) })); - _dfr.ImportOptions.Add(new CustomOptionChoice("FormatVersion", "Format &version:", true, new CustomOptionFieldChoice[] + _dfr.ImportOptions.Add(new CustomOptionChoice(nameof(FormatVersion), "Format &version:", true, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice("Type 1 (includes file names)", MADFormatVersion.Type1, true), new CustomOptionFieldChoice("Type 2 (does not include file names)", MADFormatVersion.Type2) diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/HPK/HPKDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/HPK/HPKDataFormat.cs index 69f1acc1..6d928dd8 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/HPK/HPKDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/HPK/HPKDataFormat.cs @@ -17,7 +17,7 @@ namespace UniversalEditor.DataFormats.FileSystem.HPK { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionBoolean("Compressed", "Compress the file using Zlib", false)); + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(Compressed), "Compress the file using Zlib", false)); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Homeworld/HomeworldDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Homeworld/HomeworldDataFormat.cs index 009eb702..ea031f90 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Homeworld/HomeworldDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Homeworld/HomeworldDataFormat.cs @@ -15,7 +15,7 @@ namespace UniversalEditor.DataFormats.FileSystem.Homeworld { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionChoice("Version", "Format &version:", true, + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(Version), "Format &version:", true, new CustomOptionFieldChoice("Version \"VCE0\"", (uint)0), new CustomOptionFieldChoice("Version \"WXD1\"", (uint)1) )); diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/ISO/ISODataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/ISO/ISODataFormat.cs index de19bf4f..2db0c924 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/ISO/ISODataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/ISO/ISODataFormat.cs @@ -18,17 +18,17 @@ namespace UniversalEditor.DataFormats.FileSystem.ISO _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); _dfr.ContentTypes.Add("application/x-iso9660-image"); - _dfr.ExportOptions.Add(new CustomOptionText("SystemName", "System &name:", String.Empty, 128)); - _dfr.ExportOptions.Add(new CustomOptionText("VolumeName", "&Volume name:", String.Empty, 128)); - _dfr.ExportOptions.Add(new CustomOptionNumber("VolumeSetSize", "Number of volumes in this set:", 1, 0, UInt16.MaxValue)); - _dfr.ExportOptions.Add(new CustomOptionNumber("VolumeSequenceNumber", "Index of this volume in set:", 0, 0, UInt16.MaxValue)); - _dfr.ExportOptions.Add(new CustomOptionText("VolumeSet", "Volume &set:", String.Empty, 128)); - _dfr.ExportOptions.Add(new CustomOptionText("Publisher", "&Publisher:", String.Empty, 128)); - _dfr.ExportOptions.Add(new CustomOptionText("DataPreparer", "&Data preparer:", String.Empty, 128)); - _dfr.ExportOptions.Add(new CustomOptionText("Application", "&Application:", "Universal Editor", 128)); - _dfr.ExportOptions.Add(new CustomOptionText("CopyrightFile", "&Copyright file:", String.Empty, 38)); - _dfr.ExportOptions.Add(new CustomOptionText("AbstractFile", "&Abstract file:", String.Empty, 36)); - _dfr.ExportOptions.Add(new CustomOptionText("BibliographicFile", "&Bibliographic file:", String.Empty, 37)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(SystemName), "System &name:", String.Empty, 128)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(VolumeName), "&Volume name:", String.Empty, 128)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(VolumeSetSize), "Number of volumes in this set:", 1, 0, UInt16.MaxValue)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(VolumeSequenceNumber), "Index of this volume in set:", 0, 0, UInt16.MaxValue)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(VolumeSet), "Volume &set:", String.Empty, 128)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Publisher), "&Publisher:", String.Empty, 128)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(DataPreparer), "&Data preparer:", String.Empty, 128)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Application), "&Application:", "Universal Editor", 128)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(CopyrightFile), "&Copyright file:", String.Empty, 38)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(AbstractFile), "&Abstract file:", String.Empty, 36)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(BibliographicFile), "&Bibliographic file:", String.Empty, 37)); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Moero/DownhillNight/PKDDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Moero/DownhillNight/PKDDataFormat.cs index 278ef29c..ee372579 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Moero/DownhillNight/PKDDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Moero/DownhillNight/PKDDataFormat.cs @@ -17,8 +17,8 @@ namespace UniversalEditor.DataFormats.FileSystem.Moero.DownhillNight { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ImportOptions.Add(new CustomOptionNumber("EncryptionKey", "Encryption _key:", 0xC5, 0, 255)); - _dfr.ExportOptions.Add(new CustomOptionNumber("EncryptionKey", "Encryption _key:", 0xC5, 0, 255)); + _dfr.ImportOptions.Add(new CustomOptionNumber(nameof(EncryptionKey), "Encryption _key:", 0xC5, 0, 255)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(EncryptionKey), "Encryption _key:", 0xC5, 0, 255)); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Nero/NeroDiskImageDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Nero/NeroDiskImageDataFormat.cs index e5ad90e3..63bdcf7f 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Nero/NeroDiskImageDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Nero/NeroDiskImageDataFormat.cs @@ -24,8 +24,8 @@ namespace UniversalEditor.DataFormats.FileSystem.Nero { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("ImageName", "Image &name:")); - _dfr.ExportOptions.Add(new CustomOptionText("ImageName2", "Image name (&Joliet):")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(ImageName), "Image &name:")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(ImageName2), "Image name (&Joliet):")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Nvidia/NPK/NPKDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Nvidia/NPK/NPKDataFormat.cs index e0d26307..7b7ef239 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Nvidia/NPK/NPKDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Nvidia/NPK/NPKDataFormat.cs @@ -16,9 +16,9 @@ namespace UniversalEditor.DataFormats.FileSystem.Nvidia.NPK { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ImportOptions.Add(new CustomOptionText("EncryptionKey", "Encryption &key: ", "bogomojo")); - _dfr.ExportOptions.Add(new CustomOptionBoolean("Encrypted", "&Encrypt the data with the specified key")); - _dfr.ExportOptions.Add(new CustomOptionText("EncryptionKey", "Encryption &key: ", "bogomojo")); + _dfr.ImportOptions.Add(new CustomOptionText(nameof(EncryptionKey), "Encryption &key: ", "bogomojo")); + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(Encrypted), "&Encrypt the data with the specified key")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(EncryptionKey), "Encryption &key: ", "bogomojo")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/PKG/PKGDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/PKG/PKGDataFormat.cs index d1213eac..022ac65f 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/PKG/PKGDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/PKG/PKGDataFormat.cs @@ -13,7 +13,7 @@ namespace UniversalEditor.DataFormats.FileSystem.PKG { if (_dfr == null) _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("GameName", "Game &name:")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(GameName), "Game &name:")); return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Roxor/PCK/PCKDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Roxor/PCK/PCKDataFormat.cs index 97303f25..e296b09c 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Roxor/PCK/PCKDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/Roxor/PCK/PCKDataFormat.cs @@ -16,7 +16,7 @@ namespace UniversalEditor.DataFormats.FileSystem.Roxor.PCK { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("Comment", "&Comment: ", String.Empty, 128)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Comment), "&Comment: ", String.Empty, 128)); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/SinisterGames/GUT/GUTDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/SinisterGames/GUT/GUTDataFormat.cs index 133cda31..8baaa9da 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/SinisterGames/GUT/GUTDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/SinisterGames/GUT/GUTDataFormat.cs @@ -17,8 +17,8 @@ namespace UniversalEditor.DataFormats.FileSystem.SinisterGames.GUT { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("GameTitle", "Game &title: ", "Shadow Company: Left for Dead")); - _dfr.ExportOptions.Add(new CustomOptionText("GameCopyright", "Game ©right: ", "Copyright 1998 by Sinister Games Inc.")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(GameTitle), "Game &title: ", "Shadow Company: Left for Dead")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(GameCopyright), "Game ©right: ", "Copyright 1998 by Sinister Games Inc.")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/SquareSoft/LGPDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/SquareSoft/LGPDataFormat.cs index 20cf3396..558c65c6 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/SquareSoft/LGPDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/SquareSoft/LGPDataFormat.cs @@ -34,8 +34,8 @@ namespace UniversalEditor.DataFormats.FileSystem.SquareSoft { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("Creator", "_Creator")); - _dfr.ExportOptions.Add(new CustomOptionText("Description", "_Description")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Creator), "_Creator")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Description), "_Description")); _dfr.Title = "SquareSoft LGP archive"; } return _dfr; diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/TapeArchive/TapeArchiveDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/TapeArchive/TapeArchiveDataFormat.cs index 8d40a00b..8d81a44d 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/TapeArchive/TapeArchiveDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/TapeArchive/TapeArchiveDataFormat.cs @@ -17,7 +17,7 @@ namespace UniversalEditor.DataFormats.FileSystem.TapeArchive { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionBoolean("IsUnixStandardTAR", "Create a UNIX standard tape archive (ustar)", true)); + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(IsUnixStandardTAR), "Create a UNIX standard tape archive (ustar)", true)); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/TerminalReality/POD/PODDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/TerminalReality/POD/PODDataFormat.cs index 25ba0139..29be0cae 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/TerminalReality/POD/PODDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/TerminalReality/POD/PODDataFormat.cs @@ -17,13 +17,13 @@ namespace UniversalEditor.DataFormats.FileSystem.TerminalReality.POD { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionChoice("FormatVersion", "Format &version: ", true, new CustomOptionFieldChoice[] + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(FormatVersion), "Format &version: ", true, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice("POD1", PODVersion.POD1, true), new CustomOptionFieldChoice("POD2", PODVersion.POD2), new CustomOptionFieldChoice("POD3", PODVersion.POD3) })); - _dfr.ExportOptions.Add(new CustomOptionText("Comment", "&Comment: ")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Comment), "&Comment: ")); _dfr.Sources.Add("http://wiki.xentax.com/index.php?title=PODArchive1"); _dfr.Sources.Add("http://wiki.xentax.com/index.php?title=PODArchive2"); _dfr.Sources.Add("http://wiki.xentax.com/index.php?title=PODArchive3"); diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/WAD/WADDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/WAD/WADDataFormat.cs index 9a0bcaaf..0fbdc178 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/WAD/WADDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/WAD/WADDataFormat.cs @@ -15,7 +15,7 @@ namespace UniversalEditor.DataFormats.FileSystem.WAD { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionBoolean("UserContent", "This archive contains public content (PWAD) rather than internal content (IWAD)")); + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(UserContent), "This archive contains public content (PWAD) rather than internal content (IWAD)")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/ZIP/ZIPDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/ZIP/ZIPDataFormat.cs index 717eebd1..72eb35ef 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/ZIP/ZIPDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.FileSystem/DataFormats/FileSystem/ZIP/ZIPDataFormat.cs @@ -40,7 +40,7 @@ namespace UniversalEditor.DataFormats.FileSystem.ZIP DataFormatReference dfr = base.MakeReferenceInternal(); dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); dfr.ContentTypes.Add("application/zip"); - dfr.ExportOptions.Add(new CustomOptionText("Comment", "_Comment: ", String.Empty, Int16.MaxValue)); + dfr.ExportOptions.Add(new CustomOptionText(nameof(Comment), "_Comment: ", String.Empty, Int16.MaxValue)); return dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Lighting/DataFormats/Lighting/Fixture/QLC/QLCFixtureXMLDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Lighting/DataFormats/Lighting/Fixture/QLC/QLCFixtureXMLDataFormat.cs index db8cae88..ccf4bcd9 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Lighting/DataFormats/Lighting/Fixture/QLC/QLCFixtureXMLDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Lighting/DataFormats/Lighting/Fixture/QLC/QLCFixtureXMLDataFormat.cs @@ -17,8 +17,8 @@ namespace UniversalEditor.DataFormats.Lighting.Fixture.QLC { _dfr = new DataFormatReference(this.GetType()); _dfr.Capabilities.Add(typeof(FixtureObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("CreatorApplication", "&Software:", "Q Light Controller Plus")); - _dfr.ExportOptions.Add(new CustomOptionText("Author", "&Author:")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(CreatorApplication), "&Software:", "Q Light Controller Plus")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Author), "&Author:")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.MTP/Accessors/MTP/MTPAccessor.cs b/CSharp/Plugins/UniversalEditor.Plugins.MTP/Accessors/MTP/MTPAccessor.cs index 6fad8e98..d682d7bb 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.MTP/Accessors/MTP/MTPAccessor.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.MTP/Accessors/MTP/MTPAccessor.cs @@ -51,6 +51,8 @@ namespace UniversalEditor.Accessors.MTP return 0; } + public string FileName { get; set; } = null; + protected override AccessorReference MakeReferenceInternal() { if (_ar == null) @@ -58,7 +60,7 @@ namespace UniversalEditor.Accessors.MTP _ar = base.MakeReferenceInternal(); _ar.Title = "Media Transfer Protocol (MTP)"; _ar.Schemas.Add("mtp-disabled"); - _ar.ImportOptions.Add(new CustomOptionText("FileName", "File _name")); + _ar.ImportOptions.Add(new CustomOptionText(nameof(FileName), "File _name")); } return _ar; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/Cabinet/CABDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/Cabinet/CABDataFormat.cs index 0e37920a..88cd69c7 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/Cabinet/CABDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/Cabinet/CABDataFormat.cs @@ -19,14 +19,14 @@ namespace UniversalEditor.DataFormats.FileSystem.Microsoft.Cabinet _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); _dfr.Sources.Add("http://msdn.microsoft.com/en-us/library/bb267310.aspx#struct_spec"); - _dfr.ExportOptions.Add(new CustomOptionNumber("CabinetReservedAreaSize", "Per-&cabinet reserved area size:", 0, 0, UInt16.MaxValue)); - _dfr.ExportOptions.Add(new CustomOptionNumber("FolderReservedAreaSize", "Per-&folder reserved area size:", 0, 0, Byte.MaxValue)); - _dfr.ExportOptions.Add(new CustomOptionNumber("DatablockReservedAreaSize", "Per-&datablock reserved area size:", 0, 0, Byte.MaxValue)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(CabinetReservedAreaSize), "Per-&cabinet reserved area size:", 0, 0, UInt16.MaxValue)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(FolderReservedAreaSize), "Per-&folder reserved area size:", 0, 0, Byte.MaxValue)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(DatablockReservedAreaSize), "Per-&datablock reserved area size:", 0, 0, Byte.MaxValue)); - _dfr.ExportOptions.Add(new CustomOptionText("NextCabinetName", "&Next cabinet file name:")); - _dfr.ExportOptions.Add(new CustomOptionText("NextDiskName", "Ne&xt cabinet disk name:")); - _dfr.ExportOptions.Add(new CustomOptionText("PreviousCabinetName", "&Previous cabinet file name:")); - _dfr.ExportOptions.Add(new CustomOptionText("PreviousDiskName", "Pre&vious cabinet disk name:")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(NextCabinetName), "&Next cabinet file name:")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(NextDiskName), "Ne&xt cabinet disk name:")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(PreviousCabinetName), "&Previous cabinet file name:")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(PreviousDiskName), "Pre&vious cabinet disk name:")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/CompoundDocument/CompoundDocumentDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/CompoundDocument/CompoundDocumentDataFormat.cs index 5c307023..3015369a 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/CompoundDocument/CompoundDocumentDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/CompoundDocument/CompoundDocumentDataFormat.cs @@ -17,9 +17,9 @@ namespace UniversalEditor.DataFormats.FileSystem.Microsoft.CompoundDocument { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionNumber("SectorSize", "&Sector size (in bytes):", 512, 128)); - _dfr.ExportOptions.Add(new CustomOptionNumber("ShortSectorSize", "S&hort sector size (in bytes):", 64)); - _dfr.ExportOptions.Add(new CustomOptionNumber("MinimumStandardStreamSize", "&Minimum standard stream size (in bytes):", 4096, 4096)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(SectorSize), "&Sector size (in bytes):", 512, 128)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(ShortSectorSize), "S&hort sector size (in bytes):", 64)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(MinimumStandardStreamSize), "&Minimum standard stream size (in bytes):", 4096, 4096)); _dfr.Sources.Add("http://www.openoffice.org/sc/compdocfileformat.pdf"); } return _dfr; diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/RKV/RKVDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/RKV/RKVDataFormat.cs index be8c0328..f73e7ee5 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/RKV/RKVDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Microsoft/DataFormats/FileSystem/Microsoft/RKV/RKVDataFormat.cs @@ -38,7 +38,7 @@ namespace UniversalEditor.DataFormats.FileSystem.Microsoft.RKV _dfr = base.MakeReferenceInternal(); _dfr.Title = "Microsoft XNA RKV archive"; _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("ArchiveName", "Archive _name")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(ArchiveName), "Archive _name")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Monolith/DataFormats/FileSystem/Monolith/REZ/REZDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Monolith/DataFormats/FileSystem/Monolith/REZ/REZDataFormat.cs index b4bf268c..119f171d 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Monolith/DataFormats/FileSystem/Monolith/REZ/REZDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Monolith/DataFormats/FileSystem/Monolith/REZ/REZDataFormat.cs @@ -15,7 +15,7 @@ namespace UniversalEditor.Plugins.Monolith.DataFormats.FileSystem.Monolith.REZ { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("Description", "&Description:", String.Empty, 127)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Description), "&Description:", String.Empty, 127)); _dfr.Sources.Add("http://wiki.xentax.com/index.php?title=Monolith_REZ"); // _dfr.Filters.Add("Monolith Productions REZ archive", new string[] { "*.rez" }); } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/AudioCollection/Synthesized/SPC2/SPC2DataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/AudioCollection/Synthesized/SPC2/SPC2DataFormat.cs index 299f9ab4..9d1b0302 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/AudioCollection/Synthesized/SPC2/SPC2DataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/AudioCollection/Synthesized/SPC2/SPC2DataFormat.cs @@ -35,8 +35,8 @@ namespace UniversalEditor.DataFormats.Multimedia.AudioCollection.Synthesized.SPC { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(SynthesizedAudioCollectionObjectModel), DataFormatCapabilities.All); - _dfr.ImportOptions.Add(new CustomOptionBoolean("UseID666TagInformationIfAvailable", "Use &ID666 tag information if available")); - _dfr.ExportOptions.Add(new CustomOptionBoolean("IncludeID666TagInformation", "Include &ID666 tag information in output file")); + _dfr.ImportOptions.Add(new CustomOptionBoolean(nameof(UseID666TagInformationIfAvailable), "Use &ID666 tag information if available")); + _dfr.ExportOptions.Add(new CustomOptionBoolean(nameof(UseID666TagInformationIfAvailable), "Include &ID666 tag information in output file")); _dfr.Sources.Add("http://blog.kevtris.org/blogfiles/spc2_file_specification_v1.txt"); } return _dfr; diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Palette/Adobe/ACODataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Palette/Adobe/ACODataFormat.cs index 3fc61f94..5268dec2 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Palette/Adobe/ACODataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Palette/Adobe/ACODataFormat.cs @@ -17,7 +17,7 @@ namespace UniversalEditor.DataFormats.Multimedia.Palette.Adobe _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(PaletteObjectModel), DataFormatCapabilities.All); _dfr.Sources.Add("http://www.nomodes.com/aco.html"); - _dfr.ExportOptions.Add(new CustomOptionNumber("Version", "&Version:", 1, 1, ushort.MaxValue)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(Version), "&Version:", 1, 1, ushort.MaxValue)); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/Autodesk/FLIC/FLICChunkType.cs b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/Autodesk/FLIC/FLICChunkType.cs new file mode 100644 index 00000000..aec269a3 --- /dev/null +++ b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/Autodesk/FLIC/FLICChunkType.cs @@ -0,0 +1,50 @@ +// +// FLICChunkType.cs +// +// Author: +// Mike Becker +// +// Copyright (c) 2020 Mike Becker +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . +using System; +namespace UniversalEditor.DataFormats.Multimedia.Picture.Autodesk.FLIC +{ + public enum FLICChunkType : short + { + None = 0x00, + /// + /// Compressed color map + /// + Color = 0x11, + /// + /// Line compressed -- the most common type of compression for any but the first + /// frame. Describes the pixel difference from the previous frame. + /// + LineCompressed = 0x12, + /// + /// Set whole screen to color 0 (only occurs on the first frame). + /// + Black = 0x13, + /// + /// Bytewise run-length compression -- first frame only + /// + BytewiseRunLengthCompressed = 0x14, + /// + /// Indicates uncompressed 64000 bytes soon to follow. For those times when + /// compression just doesn't work! + /// + Copy = 0x16 + } +} diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/GIM/GIMDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/GIM/GIMDataFormat.cs index e474619b..ab282588 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/GIM/GIMDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/GIM/GIMDataFormat.cs @@ -30,12 +30,12 @@ namespace UniversalEditor.DataFormats.Multimedia.Picture.GIM _dfr.Capabilities.Add(typeof(PictureObjectModel), DataFormatCapabilities.All); _dfr.Sources.Add("http://pspdum.my.land.to/psp/gim.html"); - _dfr.ExportOptions.Add(new CustomOptionChoice("Endianness", "&Endianness:", true, + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(Endianness), "&Endianness:", true, new CustomOptionFieldChoice("Big-Endian", IO.Endianness.BigEndian), new CustomOptionFieldChoice("Little-Endian", IO.Endianness.LittleEndian, true) )); - _dfr.ExportOptions.Add(new CustomOptionChoice("ImageFormat", "&Image format:", true, + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(ImageFormat), "&Image format:", true, new CustomOptionFieldChoice("Indexed (4-bit)", GIMImageFormat.Index4), new CustomOptionFieldChoice("Indexed (8-bit)", GIMImageFormat.Index8), new CustomOptionFieldChoice("Indexed (16-bit)", GIMImageFormat.Index16), @@ -45,20 +45,20 @@ namespace UniversalEditor.DataFormats.Multimedia.Picture.GIM new CustomOptionFieldChoice("Bitmap (R5-G6-B5-A0)", GIMImageFormat.RGBA5650), new CustomOptionFieldChoice("Bitmap (R8-G8-B8-A8)", GIMImageFormat.RGBA8888, true) )); - _dfr.ExportOptions.Add(new CustomOptionChoice("PaletteFormat", "&Palette format:", true, + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(PaletteFormat), "&Palette format:", true, new CustomOptionFieldChoice("Bitmap (R4-G4-B4-A4)", GIMPaletteFormat.RGBA4444), new CustomOptionFieldChoice("Bitmap (R5-G5-B5-A1)", GIMPaletteFormat.RGBA5551), new CustomOptionFieldChoice("Bitmap (R5-G6-B5-A0)", GIMPaletteFormat.RGBA5650), new CustomOptionFieldChoice("Bitmap (R8-G8-B8-A8)", GIMPaletteFormat.RGBA8888, true) )); - _dfr.ExportOptions.Add(new CustomOptionChoice("PixelOrder", "Pixel &order:", true, + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(PixelOrder), "Pixel &order:", true, new CustomOptionFieldChoice("Normal", GIMPixelOrder.Normal, true), new CustomOptionFieldChoice("Faster", GIMPixelOrder.Faster) )); - _dfr.ExportOptions.Add(new CustomOptionText("OriginalFileName", "Original &filename:")); - _dfr.ExportOptions.Add(new CustomOptionText("CreationUserName", "Creation &user:")); - _dfr.ExportOptions.Add(new CustomOptionText("CreationApplication", "&Application name:", "Universal Editor")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(OriginalFileName), "Original &filename:")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(CreationUserName), "Creation &user:")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(CreationApplication), "&Application name:", "Universal Editor")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/Microsoft/Bitmap/BitmapDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/Microsoft/Bitmap/BitmapDataFormat.cs index 9de7273f..87e0a052 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/Microsoft/Bitmap/BitmapDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Picture/Microsoft/Bitmap/BitmapDataFormat.cs @@ -26,7 +26,7 @@ namespace UniversalEditor.DataFormats.Multimedia.Picture.Microsoft.Bitmap { DataFormatReference dfr = base.MakeReferenceInternal(); dfr.Capabilities.Add(typeof(PictureObjectModel), DataFormatCapabilities.All); - dfr.ExportOptions.Add(new CustomOptionChoice("PixelDepth", "Pixel _depth", true, new CustomOptionFieldChoice[] + dfr.ExportOptions.Add(new CustomOptionChoice(nameof(PixelDepth), "Pixel _depth", true, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice("16 colors", BitmapBitsPerPixel.Color16), new CustomOptionFieldChoice("256 colors", BitmapBitsPerPixel.Color256), diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Subtitle/SubStationAlpha/SubStationAlphaDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Subtitle/SubStationAlpha/SubStationAlphaDataFormat.cs index 1e0c6f4e..708d705d 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Subtitle/SubStationAlpha/SubStationAlphaDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia/DataFormats/Multimedia/Subtitle/SubStationAlpha/SubStationAlphaDataFormat.cs @@ -27,8 +27,8 @@ namespace UniversalEditor.DataFormats.Multimedia.Subtitle.SubStationAlpha { _dfr = new DataFormatReference(GetType()); _dfr.Capabilities.Add(typeof(SubtitleObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("Title", "&Title:")); - _dfr.ExportOptions.Add(new CustomOptionFile("VideoFileName", "&Video file:", String.Empty, "*.asf;*.avi;*.avs;*.d2v;*.m2ts;*.m4v;*.mkv;*.mov;*.mp4;*.mpeg;*.mpg;*.ogm;*.webm;*.wmv;*.ts;*.y4m;*.yuv")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Title), "&Title:")); + _dfr.ExportOptions.Add(new CustomOptionFile(nameof(VideoFileName), "&Video file:", String.Empty, "*.asf;*.avi;*.avs;*.d2v;*.m2ts;*.m4v;*.mkv;*.mov;*.mp4;*.mpeg;*.mpg;*.ogm;*.webm;*.wmv;*.ts;*.y4m;*.yuv")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia3D/DataFormats/Multimedia3D/Model/PolygonMovieMaker/PMDModelDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia3D/DataFormats/Multimedia3D/Model/PolygonMovieMaker/PMDModelDataFormat.cs index 72b160a7..150f27aa 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Multimedia3D/DataFormats/Multimedia3D/Model/PolygonMovieMaker/PMDModelDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Multimedia3D/DataFormats/Multimedia3D/Model/PolygonMovieMaker/PMDModelDataFormat.cs @@ -19,10 +19,10 @@ namespace UniversalEditor.DataFormats.Multimedia3D.Model.PolygonMovieMaker { DataFormatReference dfr = base.MakeReferenceInternal(); dfr.Capabilities.Add(typeof(ModelObjectModel), DataFormatCapabilities.All); - dfr.ExportOptions.Add(new CustomOptionText("ModelTitleJapanese", "&Japanese model title:")); - dfr.ExportOptions.Add(new CustomOptionText("ModelTitleEnglish", "&English model title:")); - dfr.ExportOptions.Add(new CustomOptionText("ModelCommentJapanese", "Ja&panese model comment:")); - dfr.ExportOptions.Add(new CustomOptionText("ModelCommentEnglish", "En&glish model comment:")); + dfr.ExportOptions.Add(new CustomOptionText(nameof(ModelTitleJapanese), "&Japanese model title:")); + dfr.ExportOptions.Add(new CustomOptionText(nameof(ModelTitleEnglish), "&English model title:")); + dfr.ExportOptions.Add(new CustomOptionText(nameof(ModelCommentJapanese), "Ja&panese model comment:")); + dfr.ExportOptions.Add(new CustomOptionText(nameof(ModelCommentEnglish), "En&glish model comment:")); return dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Nintendo/DataFormats/Executable/Nintendo/SNES/SMCDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Nintendo/DataFormats/Executable/Nintendo/SNES/SMCDataFormat.cs index 7556a898..deaf5e22 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Nintendo/DataFormats/Executable/Nintendo/SNES/SMCDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Nintendo/DataFormats/Executable/Nintendo/SNES/SMCDataFormat.cs @@ -21,8 +21,8 @@ namespace UniversalEditor.DataFormats.Executable.Nintendo.SNES _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(ExecutableObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("GameName", "Game &name:", String.Empty, 21)); - _dfr.ExportOptions.Add(new CustomOptionChoice("CartridgeType", "Cartridge &type:", true, new CustomOptionFieldChoice[] + _dfr.ExportOptions.Add(new CustomOptionText(nameof(GameName), "Game &name:", String.Empty, 21)); + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(CartridgeType), "Cartridge &type:", true, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice(SMCCartridgeTypes.ROMOnly, true), new CustomOptionFieldChoice(SMCCartridgeTypes.ROMAndRAM), @@ -54,10 +54,10 @@ namespace UniversalEditor.DataFormats.Executable.Nintendo.SNES new CustomOptionFieldChoice(SMCMemorySizes.M4), }; - _dfr.ExportOptions.Add(new CustomOptionChoice("ROMSize", "RO&M size:", true, _smcMemorySizes)); - _dfr.ExportOptions.Add(new CustomOptionChoice("RAMSize", "R&AM size:", true, _smcMemorySizes)); + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(ROMSize), "RO&M size:", true, _smcMemorySizes)); + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(RAMSize), "R&AM size:", true, _smcMemorySizes)); - _dfr.ExportOptions.Add(new CustomOptionChoice("Region", "&Region:", false, new CustomOptionFieldChoice[] + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(Region), "&Region:", false, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice(SMCRegions.Japan), new CustomOptionFieldChoice(SMCRegions.NorthAmerica), @@ -75,7 +75,7 @@ namespace UniversalEditor.DataFormats.Executable.Nintendo.SNES new CustomOptionFieldChoice(SMCRegions.SouthKorea) })); - _dfr.ExportOptions.Add(new CustomOptionChoice("Licensee", "&Licensee:", false, new CustomOptionFieldChoice[] + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(Licensee), "&Licensee:", false, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice(SMCLicensees.None, true), new CustomOptionFieldChoice(SMCLicensees.Nintendo0x01), @@ -260,7 +260,7 @@ namespace UniversalEditor.DataFormats.Executable.Nintendo.SNES new CustomOptionFieldChoice(SMCLicensees.Psygnosis), new CustomOptionFieldChoice(SMCLicensees.Davidson), })); - _dfr.ExportOptions.Add(new CustomOptionNumber("VersionNumber", "&Version number:", 0, Byte.MinValue, Byte.MaxValue)); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(VersionNumber), "&Version number:", 0, Byte.MinValue, Byte.MaxValue)); _dfr.Sources.Add("http://romhack.wikia.com/wiki/SNES_ROM_layout"); _dfr.Sources.Add("http://romhack.wikia.com/wiki/SNES_header"); diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Nintendo/DataFormats/FileSystem/Nintendo/Optical/NintendoOpticalDiscDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Nintendo/DataFormats/FileSystem/Nintendo/Optical/NintendoOpticalDiscDataFormat.cs index c86f4a69..f3e0c4f3 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Nintendo/DataFormats/FileSystem/Nintendo/Optical/NintendoOpticalDiscDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Nintendo/DataFormats/FileSystem/Nintendo/Optical/NintendoOpticalDiscDataFormat.cs @@ -17,7 +17,7 @@ namespace UniversalEditor.DataFormats.FileSystem.Nintendo.Optical { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionChoice("FormatCode", "&Format code:", true, new CustomOptionFieldChoice[] + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(FormatCode), "&Format code:", true, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice(NintendoOpticalDiscFormatCodes.Revolution), new CustomOptionFieldChoice(NintendoOpticalDiscFormatCodes.Wii, true), @@ -30,8 +30,8 @@ namespace UniversalEditor.DataFormats.FileSystem.Nintendo.Optical new CustomOptionFieldChoice(NintendoOpticalDiscFormatCodes.WiiBackup), new CustomOptionFieldChoice(NintendoOpticalDiscFormatCodes.WiiFitChanInstaller) })); - _dfr.ExportOptions.Add(new CustomOptionText("GameCode", "&Game code:", String.Empty, 2)); - _dfr.ExportOptions.Add(new CustomOptionChoice("RegionCode", "&Region code:", true, new CustomOptionFieldChoice[] + _dfr.ExportOptions.Add(new CustomOptionText(nameof(GameCode), "&Game code:", String.Empty, 2)); + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(RegionCode), "&Region code:", true, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice(NintendoOpticalDiscRegionCodes.German), new CustomOptionFieldChoice(NintendoOpticalDiscRegionCodes.UnitedStates, true), @@ -46,13 +46,13 @@ namespace UniversalEditor.DataFormats.FileSystem.Nintendo.Optical new CustomOptionFieldChoice(NintendoOpticalDiscRegionCodes.Australia), })); - _dfr.ExportOptions.Add(new CustomOptionChoice("SystemType", "&System type:", true, new CustomOptionFieldChoice[] + _dfr.ExportOptions.Add(new CustomOptionChoice(nameof(SystemType), "&System type:", true, new CustomOptionFieldChoice[] { new CustomOptionFieldChoice("GameCube", NintendoOpticalDiscSystemType.GameCube), new CustomOptionFieldChoice("Wii", NintendoOpticalDiscSystemType.Wii, true) })); - _dfr.ExportOptions.Add(new CustomOptionText("GameTitle", "Game &title:", String.Empty, 64)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(GameTitle), "Game &title:", String.Empty, 64)); _dfr.Sources.Add("http://wiibrew.org/wiki/Wii_Disc"); _dfr.Sources.Add("http://www.emutalk.net/threads/21512-GCM-file-extension!/page3"); diff --git a/CSharp/Plugins/UniversalEditor.Plugins.UnrealEngine/DataFormats/UnrealEngine/Package/UnrealPackageDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.UnrealEngine/DataFormats/UnrealEngine/Package/UnrealPackageDataFormat.cs index 244b2944..7db03375 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.UnrealEngine/DataFormats/UnrealEngine/Package/UnrealPackageDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.UnrealEngine/DataFormats/UnrealEngine/Package/UnrealPackageDataFormat.cs @@ -17,8 +17,8 @@ namespace UniversalEditor.DataFormats.UnrealEngine.Package { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(UnrealPackageObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("PackageName", "Package &name:")); - _dfr.ExportOptions.Add(new CustomOptionNumber("PackageVersion", "Package &version:", 0, UInt16.MinValue, UInt16.MaxValue)); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(PackageName), "Package &name:")); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(PackageVersion), "Package &version:", 0, UInt16.MinValue, UInt16.MaxValue)); _dfr.Sources.Add("http://wiki.beyondunreal.com/Legacy:Package_File_Format"); } return _dfr; diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Valve/DataFormats/FileSystem/Valve/GCF/GCFDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Valve/DataFormats/FileSystem/Valve/GCF/GCFDataFormat.cs index 47a0ad4a..5746948b 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Valve/DataFormats/FileSystem/Valve/GCF/GCFDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Valve/DataFormats/FileSystem/Valve/GCF/GCFDataFormat.cs @@ -15,9 +15,9 @@ namespace UniversalEditor.DataFormats.FileSystem.Valve.GCF { _dfr = base.MakeReferenceInternal(); _dfr.Capabilities.Add(typeof(FileSystemObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionVersion("FormatVersion", "Format &version: ")); - _dfr.ExportOptions.Add(new CustomOptionNumber("CacheID", "&Cache ID: ")); - _dfr.ExportOptions.Add(new CustomOptionNumber("LastVersionPlayed", "&Last version played: ")); + _dfr.ExportOptions.Add(new CustomOptionVersion(nameof(FormatVersion), "Format &version: ")); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(CacheID), "&Cache ID: ")); + _dfr.ExportOptions.Add(new CustomOptionNumber(nameof(LastVersionPlayed), "&Last version played: ")); } return _dfr; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Web/Accessors/HTTPAccessor.cs b/CSharp/Plugins/UniversalEditor.Plugins.Web/Accessors/HTTPAccessor.cs index 53315e08..02c66432 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Web/Accessors/HTTPAccessor.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Web/Accessors/HTTPAccessor.cs @@ -15,7 +15,7 @@ namespace UniversalEditor.Accessors { _ar = base.MakeReferenceInternal(); _ar.Title = "Internet (HTTP)"; - _ar.ImportOptions.Add(new CustomOptionText("FileName", "File _name: ")); + _ar.ImportOptions.Add(new CustomOptionText(nameof(FileName), "File _name: ")); } return _ar; } diff --git a/CSharp/Plugins/UniversalEditor.Plugins.Web/DataFormats/Text/HTML/HTMLDataFormat.cs b/CSharp/Plugins/UniversalEditor.Plugins.Web/DataFormats/Text/HTML/HTMLDataFormat.cs index 0a031bd3..29b150e6 100644 --- a/CSharp/Plugins/UniversalEditor.Plugins.Web/DataFormats/Text/HTML/HTMLDataFormat.cs +++ b/CSharp/Plugins/UniversalEditor.Plugins.Web/DataFormats/Text/HTML/HTMLDataFormat.cs @@ -24,7 +24,7 @@ namespace UniversalEditor.DataFormats.Text.HTML _dfr.Capabilities.Add(typeof(PlainTextObjectModel), DataFormatCapabilities.All); _dfr.Capabilities.Add(typeof(FormattedTextObjectModel), DataFormatCapabilities.All); - _dfr.ExportOptions.Add(new CustomOptionText("Title", "&Title: ")); + _dfr.ExportOptions.Add(new CustomOptionText(nameof(Title), "&Title: ")); } return _dfr; }