From 2314c89604a5362d58407c2ea18d3695a46c12c6 Mon Sep 17 00:00:00 2001 From: Tino Reichardt Date: Fri, 10 Apr 2020 19:17:11 +0200 Subject: [PATCH] Some more fixes, mainly issue #116 --- C/7zVersionTr.h | 2 +- CPP/7zip/UI/Common/CompressCall.cpp | 13 +++++++++++-- CPP/7zip/UI/GUI/CompressDialog.cpp | 15 +++------------ 3 files changed, 15 insertions(+), 15 deletions(-) diff --git a/C/7zVersionTr.h b/C/7zVersionTr.h index 6ace93fb..da485f89 100644 --- a/C/7zVersionTr.h +++ b/C/7zVersionTr.h @@ -5,7 +5,7 @@ #define MY_AUTHOR_NAME "Tino Reichardt" #undef MY_COPYRIGHT -#define MY_COPYRIGHT "Copyright (c) 2016 - 2019 Tino Reichardt" +#define MY_COPYRIGHT "Copyright (c) 2016 - 2020 Tino Reichardt" #undef MY_COPYRIGHT_DATE #define MY_COPYRIGHT_DATE MY_COPYRIGHT " : " MY_DATE diff --git a/CPP/7zip/UI/Common/CompressCall.cpp b/CPP/7zip/UI/Common/CompressCall.cpp index ad7b842c..5266dfda 100644 --- a/CPP/7zip/UI/Common/CompressCall.cpp +++ b/CPP/7zip/UI/Common/CompressCall.cpp @@ -252,15 +252,22 @@ HRESULT CompressFiles( params += temp; } +#if 0 + // need to split the extra Options /TR 2020-04-10 if (!fo.Options.IsEmpty()) { params += " -m"; params += fo.Options; } + + if (!fo.SplitVolume.IsEmpty()) + { + params += " -v"; + params += fo.SplitVolume; + } +#endif } } - // for testing current params, /TR 2017-05-18 - // ErrorMessage(params); if (email) params += kEmailSwitch; @@ -290,6 +297,8 @@ HRESULT CompressFiles( arcName); } + // for testing current params, /TR 2017-05-18 + // ErrorMessage(params); return Call7zGui(params, // (arcPathPrefix.IsEmpty()? 0: (LPCWSTR)arcPathPrefix), waitFinish, &event); diff --git a/CPP/7zip/UI/GUI/CompressDialog.cpp b/CPP/7zip/UI/GUI/CompressDialog.cpp index 63765ccf..45ec7bfd 100644 --- a/CPP/7zip/UI/GUI/CompressDialog.cpp +++ b/CPP/7zip/UI/GUI/CompressDialog.cpp @@ -33,8 +33,6 @@ extern bool g_IsNT; #include "CompressDialogRes.h" #include "ExtractRes.h" -#define DLGDBG 0 - #ifdef LANG static const UInt32 kLangIDs[] = { @@ -264,7 +262,7 @@ struct CFormatInfo bool EncryptFileNames; }; -#if DLGDBG +#if 0 void ShowInfo(LPCWSTR str, ...) { wchar_t buf[4000]; @@ -274,11 +272,8 @@ void ShowInfo(LPCWSTR str, ...) va_end(args); ShowErrorMessage(NULL, buf); } -#else -#define ShowInfo(x, ...) #endif - #define METHODS_PAIR(x) ARRAY_SIZE(x), x static const CFormatInfo g_Formats[] = @@ -938,12 +933,10 @@ bool CCompressDialog::OnCommand(int code, int itemID, LPARAM lParam) case IDC_COMPRESS_FORMAT: { - //ShowInfo(L"FORMAT level=%d method=%d format=%d", GetLevel(), GetMethodID(), GetFormatIndex()); bool isSFX = IsSFX(); SaveOptionsInMem(); m_Solid.ResetContent(); SetLevel(); - SetMethod(GetMethodID()); SetSolidBlockSize(); SetNumThreads(); SetParams(); @@ -951,12 +944,12 @@ bool CCompressDialog::OnCommand(int code, int itemID, LPARAM lParam) SetArchiveName2(isSFX); SetEncryptionMethod(); SetMemoryUsage(); + SetMethod(GetMethodID()); return true; } case IDC_COMPRESS_LEVEL: { - //ShowInfo(L"LEVEL level=%d method=%d format=%d", GetLevel(), GetMethodID(), GetFormatIndex()); { const CArcInfoEx &ai = (*ArcFormats)[GetFormatIndex()]; int index = FindRegistryFormatAlways(ai.Name); @@ -973,7 +966,6 @@ bool CCompressDialog::OnCommand(int code, int itemID, LPARAM lParam) case IDC_COMPRESS_METHOD: { - //ShowInfo(L"METHOD level=%d method=%d format=%d", GetLevel(), GetMethodID(), GetFormatIndex()); SetMethod(GetMethodID()); SetDictionary(); SetOrder(); @@ -1216,7 +1208,7 @@ void CCompressDialog::SetLevel() } } - ShowInfo(L"SetLevel() methodID=%d level=%d start=%d end=%d", GetMethodID(), level, LevelsStart, LevelsEnd); + // ShowInfo(L"SetLevel() methodID=%d level=%d start=%d end=%d", GetMethodID(), level, LevelsStart, LevelsEnd); SetNearestSelectComboBox(m_Level, level); return; @@ -1234,7 +1226,6 @@ void CCompressDialog::SetMethod(int keepMethodId) int mID = GetMethodID(); static int mID_old = 0; - ShowInfo(L"SetMethod level=%d method=%d methodPrev=%d", GetLevel(), mID, mID_old); if (mID != mID_old) { mID_old = mID; SetLevel();