Ejemplo n.º 1
0
 public PEHeadersOptionsVM(Machine defaultMachine, Subsystem defaultSubsystem)
 {
     this.defaultMachine   = defaultMachine;
     this.defaultSubsystem = defaultSubsystem;
     Machine = new EnumListVM(machineList, (a, b) => {
         Characteristics = CharacteristicsHelper.GetCharacteristics(Characteristics ?? 0, (dnlib.PE.Machine)Machine.SelectedItem);
     });
     TimeDateStamp               = new NullableUInt32VM(a => HasErrorUpdated());
     PointerToSymbolTable        = new NullableUInt32VM(a => HasErrorUpdated());
     NumberOfSymbols             = new NullableUInt32VM(a => HasErrorUpdated());
     MajorLinkerVersion          = new NullableByteVM(a => HasErrorUpdated());
     MinorLinkerVersion          = new NullableByteVM(a => HasErrorUpdated());
     ImageBase                   = new NullableUInt64VM(a => HasErrorUpdated());
     SectionAlignment            = new NullableUInt32VM(a => HasErrorUpdated());
     FileAlignment               = new NullableUInt32VM(a => HasErrorUpdated());
     MajorOperatingSystemVersion = new NullableUInt16VM(a => HasErrorUpdated());
     MinorOperatingSystemVersion = new NullableUInt16VM(a => HasErrorUpdated());
     MajorImageVersion           = new NullableUInt16VM(a => HasErrorUpdated());
     MinorImageVersion           = new NullableUInt16VM(a => HasErrorUpdated());
     MajorSubsystemVersion       = new NullableUInt16VM(a => HasErrorUpdated());
     MinorSubsystemVersion       = new NullableUInt16VM(a => HasErrorUpdated());
     Win32VersionValue           = new NullableUInt32VM(a => HasErrorUpdated());
     SizeOfStackReserve          = new NullableUInt64VM(a => HasErrorUpdated());
     SizeOfStackCommit           = new NullableUInt64VM(a => HasErrorUpdated());
     SizeOfHeapReserve           = new NullableUInt64VM(a => HasErrorUpdated());
     SizeOfHeapCommit            = new NullableUInt64VM(a => HasErrorUpdated());
     LoaderFlags                 = new NullableUInt32VM(a => HasErrorUpdated());
     NumberOfRvaAndSizes         = new NullableUInt32VM(a => HasErrorUpdated());
 }
Ejemplo n.º 2
0
        public LocalSettingsVM(LocalHexSettings options)
        {
            this.origOptions = options;
            this.bytesGroupCountVM = new NullableInt32VM(a => HasErrorUpdated());
            this.bytesPerLineVM = new NullableInt32VM(a => HasErrorUpdated(), true) {
                Min = 0,
                Max = HexEditorSettings.MAX_BYTES_PER_LINE,
            };
            this.hexOffsetSizeVM = new Int32VM(a => HasErrorUpdated(), true) {
                Min = 0,
                Max = 64,
            };
            this.baseOffsetVM = new UInt64VM(a => HasErrorUpdated());
            this.startOffsetVM = new NullableUInt64VM(a => HasErrorUpdated());
            this.endOffsetVM = new NullableUInt64VM(a => HasErrorUpdated());
            this.asciiEncodingVM = new EnumListVM(asciiEncodingList);

            Reinitialize();
        }
Ejemplo n.º 3
0
        public LocalSettingsVM(LocalHexSettings options)
        {
            this.origOptions       = options;
            this.bytesGroupCountVM = new NullableInt32VM(a => HasErrorUpdated());
            this.bytesPerLineVM    = new NullableInt32VM(a => HasErrorUpdated(), true)
            {
                Min = 0,
                Max = HexSettings.MAX_BYTES_PER_LINE,
            };
            this.hexOffsetSizeVM = new Int32VM(a => HasErrorUpdated(), true)
            {
                Min = 0,
                Max = 64,
            };
            this.baseOffsetVM    = new UInt64VM(a => HasErrorUpdated());
            this.startOffsetVM   = new NullableUInt64VM(a => HasErrorUpdated());
            this.endOffsetVM     = new NullableUInt64VM(a => HasErrorUpdated());
            this.asciiEncodingVM = new EnumListVM(asciiEncodingList);

            Reinitialize();
        }
Ejemplo n.º 4
0
 public PEHeadersOptionsVM(Machine defaultMachine, Subsystem defaultSubsystem)
 {
     this.defaultMachine = defaultMachine;
     this.defaultSubsystem = defaultSubsystem;
     this.machineVM = new EnumListVM(machineList, (a, b) => {
         Characteristics = CharacteristicsHelper.GetCharacteristics(Characteristics ?? 0, (dnlib.PE.Machine)Machine.SelectedItem);
     });
     this.timeDateStamp = new NullableUInt32VM(a => HasErrorUpdated());
     this.majorLinkerVersion = new NullableByteVM(a => HasErrorUpdated());
     this.minorLinkerVersion = new NullableByteVM(a => HasErrorUpdated());
     this.imageBase = new NullableUInt64VM(a => HasErrorUpdated());
     this.sectionAlignment = new NullableUInt32VM(a => HasErrorUpdated());
     this.fileAlignment = new NullableUInt32VM(a => HasErrorUpdated());
     this.majorOperatingSystemVersion = new NullableUInt16VM(a => HasErrorUpdated());
     this.minorOperatingSystemVersion = new NullableUInt16VM(a => HasErrorUpdated());
     this.majorImageVersion = new NullableUInt16VM(a => HasErrorUpdated());
     this.minorImageVersion = new NullableUInt16VM(a => HasErrorUpdated());
     this.majorSubsystemVersion = new NullableUInt16VM(a => HasErrorUpdated());
     this.minorSubsystemVersion = new NullableUInt16VM(a => HasErrorUpdated());
     this.win32VersionValue = new NullableUInt32VM(a => HasErrorUpdated());
     this.sizeOfStackReserve = new NullableUInt64VM(a => HasErrorUpdated());
     this.sizeOfStackCommit = new NullableUInt64VM(a => HasErrorUpdated());
     this.sizeOfHeapReserve = new NullableUInt64VM(a => HasErrorUpdated());
     this.sizeOfHeapCommit = new NullableUInt64VM(a => HasErrorUpdated());
     this.loaderFlags = new NullableUInt32VM(a => HasErrorUpdated());
     this.numberOfRvaAndSizes = new NullableUInt32VM(a => HasErrorUpdated());
 }