1 // ZipRegistry.h 2 3 #ifndef __ZIP_REGISTRY_H 4 #define __ZIP_REGISTRY_H 5 6 #include "../../../Common/MyTypes.h" 7 #include "../../../Common/MyString.h" 8 9 #include "ExtractMode.h" 10 11 namespace NExtract 12 { 13 struct CInfo 14 { 15 NPathMode::EEnum PathMode; 16 NOverwriteMode::EEnum OverwriteMode; 17 bool PathMode_Force; 18 bool OverwriteMode_Force; 19 20 CBoolPair SplitDest; 21 CBoolPair ElimDup; 22 // CBoolPair AltStreams; 23 CBoolPair NtSecurity; 24 CBoolPair ShowPassword; 25 26 UStringVector Paths; 27 28 void Save() const; 29 void Load(); 30 }; 31 32 void Save_ShowPassword(bool showPassword); 33 bool Read_ShowPassword(); 34 } 35 36 namespace NCompression 37 { 38 struct CFormatOptions 39 { 40 UInt32 Level; 41 UInt32 Dictionary; 42 UInt32 Order; 43 UInt32 BlockLogSize; 44 UInt32 NumThreads; 45 46 CSysString FormatID; 47 UString Method; 48 UString Options; 49 UString EncryptionMethod; 50 Reset_BlockLogSizeCFormatOptions51 void Reset_BlockLogSize() 52 { 53 BlockLogSize = (UInt32)(Int32)-1; 54 } 55 ResetForLevelChangeCFormatOptions56 void ResetForLevelChange() 57 { 58 BlockLogSize = NumThreads = Level = Dictionary = Order = (UInt32)(Int32)-1; 59 Method.Empty(); 60 // Options.Empty(); 61 // EncryptionMethod.Empty(); 62 } CFormatOptionsCFormatOptions63 CFormatOptions() { ResetForLevelChange(); } 64 }; 65 66 struct CInfo 67 { 68 UInt32 Level; 69 bool ShowPassword; 70 bool EncryptHeaders; 71 UString ArcType; 72 UStringVector ArcPaths; 73 74 CObjectVector<CFormatOptions> Formats; 75 76 CBoolPair NtSecurity; 77 CBoolPair AltStreams; 78 CBoolPair HardLinks; 79 CBoolPair SymLinks; 80 81 void Save() const; 82 void Load(); 83 }; 84 } 85 86 namespace NWorkDir 87 { 88 namespace NMode 89 { 90 enum EEnum 91 { 92 kSystem, 93 kCurrent, 94 kSpecified 95 }; 96 } 97 struct CInfo 98 { 99 NMode::EEnum Mode; 100 FString Path; 101 bool ForRemovableOnly; 102 SetForRemovableOnlyDefaultCInfo103 void SetForRemovableOnlyDefault() { ForRemovableOnly = true; } SetDefaultCInfo104 void SetDefault() 105 { 106 Mode = NMode::kSystem; 107 Path.Empty(); 108 SetForRemovableOnlyDefault(); 109 } 110 111 void Save() const; 112 void Load(); 113 }; 114 } 115 116 117 struct CContextMenuInfo 118 { 119 CBoolPair Cascaded; 120 CBoolPair MenuIcons; 121 CBoolPair ElimDup; 122 123 bool Flags_Def; 124 UInt32 Flags; 125 126 void Save() const; 127 void Load(); 128 }; 129 130 #endif 131