1 // ExtractDialog.h 2 3 #ifndef __EXTRACT_DIALOG_H 4 #define __EXTRACT_DIALOG_H 5 6 #include "ExtractDialogRes.h" 7 8 #include "../../../Windows/Control/ComboBox.h" 9 #include "../../../Windows/Control/Edit.h" 10 11 #include "../Common/ExtractMode.h" 12 13 #include "../FileManager/DialogSize.h" 14 15 #ifndef NO_REGISTRY 16 #include "../Common/ZipRegistry.h" 17 #endif 18 19 namespace NExtractionDialog 20 { 21 /* 22 namespace NFilesMode 23 { 24 enum EEnum 25 { 26 kSelected, 27 kAll, 28 kSpecified 29 }; 30 } 31 */ 32 } 33 34 class CExtractDialog: public NWindows::NControl::CModalDialog 35 { 36 #ifdef NO_REGISTRY 37 NWindows::NControl::CDialogChildControl _path; 38 #else 39 NWindows::NControl::CComboBox _path; 40 #endif 41 42 #ifndef _SFX 43 NWindows::NControl::CEdit _pathName; 44 NWindows::NControl::CEdit _passwordControl; 45 NWindows::NControl::CComboBox _pathMode; 46 NWindows::NControl::CComboBox _overwriteMode; 47 #endif 48 49 #ifndef _SFX 50 // int GetFilesMode() const; 51 void UpdatePasswordControl(); 52 #endif 53 54 void OnButtonSetPath(); 55 56 void CheckButton_TwoBools(UINT id, const CBoolPair &b1, const CBoolPair &b2); 57 void GetButton_Bools(UINT id, CBoolPair &b1, CBoolPair &b2); 58 virtual bool OnInit(); 59 virtual bool OnButtonClicked(int buttonID, HWND buttonHWND); 60 virtual void OnOK(); 61 62 #ifndef NO_REGISTRY 63 64 virtual void OnHelp(); 65 66 NExtract::CInfo _info; 67 68 #endif 69 IsShowPasswordChecked()70 bool IsShowPasswordChecked() const { return IsButtonCheckedBool(IDX_PASSWORD_SHOW); } 71 public: 72 // bool _enableSelectedFilesButton; 73 // bool _enableFilesButton; 74 // NExtractionDialog::NFilesMode::EEnum FilesMode; 75 76 UString DirPath; 77 UString ArcPath; 78 79 #ifndef _SFX 80 UString Password; 81 #endif 82 bool PathMode_Force; 83 bool OverwriteMode_Force; 84 NExtract::NPathMode::EEnum PathMode; 85 NExtract::NOverwriteMode::EEnum OverwriteMode; 86 87 #ifndef _SFX 88 // CBoolPair AltStreams; 89 CBoolPair NtSecurity; 90 #endif 91 92 CBoolPair ElimDup; 93 94 INT_PTR Create(HWND aWndParent = 0) 95 { 96 #ifdef _SFX 97 BIG_DIALOG_SIZE(240, 64); 98 #else 99 BIG_DIALOG_SIZE(300, 160); 100 #endif 101 return CModalDialog::Create(SIZED_DIALOG(IDD_EXTRACT), aWndParent); 102 } 103 CExtractDialog()104 CExtractDialog(): 105 PathMode_Force(false), 106 OverwriteMode_Force(false) 107 { 108 ElimDup.Val = true; 109 } 110 111 }; 112 113 #endif 114