diff options
author | Daniel Wilhelm <daniel@wili.li> | 2014-04-18 17:22:36 +0200 |
---|---|---|
committer | Daniel Wilhelm <daniel@wili.li> | 2014-04-18 17:22:36 +0200 |
commit | ecb1524f8da7901338b263384fed3c612f117b4c (patch) | |
tree | e7e06423fe27ea5ab45f27fc4b39ae597ba72490 /lib/process_xml.h | |
parent | 5.10 (diff) | |
download | FreeFileSync-ecb1524f8da7901338b263384fed3c612f117b4c.tar.gz FreeFileSync-ecb1524f8da7901338b263384fed3c612f117b4c.tar.bz2 FreeFileSync-ecb1524f8da7901338b263384fed3c612f117b4c.zip |
5.11
Diffstat (limited to 'lib/process_xml.h')
-rw-r--r-- | lib/process_xml.h | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/lib/process_xml.h b/lib/process_xml.h index 8d1d4538..29237081 100644 --- a/lib/process_xml.h +++ b/lib/process_xml.h @@ -48,13 +48,13 @@ typedef std::vector<std::pair<Description, Commandline> > ExternalApps; struct XmlGuiConfig { XmlGuiConfig() : - showFilteredElements(true), + hideExcludedItems(false), handleError(ON_GUIERROR_POPUP), showSyncAction(true) {} //initialize values zen::MainConfiguration mainCfg; - bool showFilteredElements; + bool hideExcludedItems; OnGuiError handleError; //reaction on error situation during synchronization bool showSyncAction; }; @@ -63,10 +63,10 @@ struct XmlGuiConfig inline bool operator==(const XmlGuiConfig& lhs, const XmlGuiConfig& rhs) { - return lhs.mainCfg == rhs.mainCfg && - lhs.showFilteredElements == rhs.showFilteredElements && - lhs.handleError == rhs.handleError && - lhs.showSyncAction == rhs.showSyncAction; + return lhs.mainCfg == rhs.mainCfg && + lhs.hideExcludedItems == rhs.hideExcludedItems && + lhs.handleError == rhs.handleError && + lhs.showSyncAction == rhs.showSyncAction; } @@ -232,6 +232,7 @@ struct XmlGlobalSettings //struct Batch }; +//read/write specific config types void readConfig(const Zstring& filename, XmlGuiConfig& config); // void readConfig(const Zstring& filename, XmlBatchConfig& config); //throw FfsXmlError void readConfig( XmlGlobalSettings& config); // @@ -240,11 +241,6 @@ void writeConfig(const XmlGuiConfig& config, const Zstring& filename); // void writeConfig(const XmlBatchConfig& config, const Zstring& filename); //throw FfsXmlError void writeConfig(const XmlGlobalSettings& config); // -//config conversion utilities -XmlGuiConfig convertBatchToGui(const XmlBatchConfig& batchCfg); -XmlBatchConfig convertGuiToBatch(const XmlGuiConfig& guiCfg, const Zstring& referenceFile); - - //convert (multiple) *.ffs_gui, *.ffs_batch files or combinations of both into target config structure: enum MergeType { @@ -253,10 +249,14 @@ enum MergeType MERGE_GUI_BATCH, //gui and batch files MERGE_OTHER }; -MergeType getMergeType(const std::vector<Zstring>& filenames); //throw () +MergeType getMergeType(const std::vector<Zstring>& filenames); //noexcept -void mergeConfigs(const std::vector<Zstring>& filenames, XmlGuiConfig& config); //throw xmlAccess::FfsXmlError -void mergeConfigs(const std::vector<Zstring>& filenames, XmlBatchConfig& config); //throw xmlAccess::FfsXmlError +void readAnyConfig(const std::vector<Zstring>& filenames, XmlGuiConfig& config); //throw FfsXmlError + +//config conversion utilities +XmlGuiConfig convertBatchToGui(const XmlBatchConfig& batchCfg); //noexcept +XmlBatchConfig convertGuiToBatch(const XmlGuiConfig& guiCfg ); // +XmlBatchConfig convertGuiToBatchPreservingExistingBatch(const xmlAccess::XmlGuiConfig& guiCfg, const Zstring& referenceBatchFile); //noexcept std::wstring extractJobName(const Zstring& configFilename); } |