summaryrefslogtreecommitdiff
path: root/ui
diff options
context:
space:
mode:
Diffstat (limited to 'ui')
-rw-r--r--ui/batch_status_handler.cpp10
-rw-r--r--ui/batch_status_handler.h10
-rw-r--r--ui/grid_view.cpp4
-rw-r--r--ui/gui_generated.cpp369
-rw-r--r--ui/gui_generated.h99
-rw-r--r--ui/gui_status_handler.cpp20
-rw-r--r--ui/gui_status_handler.h20
-rw-r--r--ui/main_dlg.cpp81
-rw-r--r--ui/progress_indicator.cpp75
-rw-r--r--ui/small_dlgs.cpp16
-rw-r--r--ui/sync_cfg.cpp41
-rw-r--r--ui/wx_form_build_hide_warnings.h6
12 files changed, 378 insertions, 373 deletions
diff --git a/ui/batch_status_handler.cpp b/ui/batch_status_handler.cpp
index 93237c70..1a710eee 100644
--- a/ui/batch_status_handler.cpp
+++ b/ui/batch_status_handler.cpp
@@ -278,14 +278,14 @@ void BatchStatusHandler::updateProcessedData(int objectsProcessed, zen::Int64 da
}
-void BatchStatusHandler::reportStatus(const wxString& text)
+void BatchStatusHandler::reportStatus(const std::wstring& text)
{
syncStatusFrame.setStatusText_NoUpdate(text);
requestUiRefresh(); //throw AbortThisProcess
}
-void BatchStatusHandler::reportInfo(const wxString& text)
+void BatchStatusHandler::reportInfo(const std::wstring& text)
{
errorLog.logMsg(text, TYPE_INFO);
@@ -294,7 +294,7 @@ void BatchStatusHandler::reportInfo(const wxString& text)
}
-void BatchStatusHandler::reportWarning(const wxString& warningMessage, bool& warningActive)
+void BatchStatusHandler::reportWarning(const std::wstring& warningMessage, bool& warningActive)
{
errorLog.logMsg(warningMessage, TYPE_WARNING);
@@ -339,7 +339,7 @@ void BatchStatusHandler::reportWarning(const wxString& warningMessage, bool& war
}
-ProcessCallback::Response BatchStatusHandler::reportError(const wxString& errorMessage)
+ProcessCallback::Response BatchStatusHandler::reportError(const std::wstring& errorMessage)
{
switch (handleError_)
{
@@ -384,7 +384,7 @@ ProcessCallback::Response BatchStatusHandler::reportError(const wxString& errorM
}
-void BatchStatusHandler::reportFatalError(const wxString& errorMessage)
+void BatchStatusHandler::reportFatalError(const std::wstring& errorMessage)
{
if (handleError_ == xmlAccess::ON_ERROR_POPUP)
exitWhenFinished = false; //log fatal error and show it on status dialog
diff --git a/ui/batch_status_handler.h b/ui/batch_status_handler.h
index 548447f6..998f2bc8 100644
--- a/ui/batch_status_handler.h
+++ b/ui/batch_status_handler.h
@@ -34,13 +34,13 @@ public:
virtual void initNewProcess(int objectsTotal, zen::Int64 dataTotal, Process processID);
virtual void updateProcessedData(int objectsProcessed, zen::Int64 dataProcessed);
- virtual void reportStatus(const wxString& text);
- virtual void reportInfo(const wxString& text);
+ virtual void reportStatus(const std::wstring& text);
+ virtual void reportInfo(const std::wstring& text);
virtual void forceUiRefresh();
- virtual void reportWarning(const wxString& warningMessage, bool& warningActive);
- virtual Response reportError(const wxString& errorMessage);
- virtual void reportFatalError(const wxString& errorMessage);
+ virtual void reportWarning(const std::wstring& warningMessage, bool& warningActive);
+ virtual Response reportError(const std::wstring& errorMessage);
+ virtual void reportFatalError(const std::wstring& errorMessage);
private:
virtual void abortThisProcess();
diff --git a/ui/grid_view.cpp b/ui/grid_view.cpp
index bd2bf4f4..0120764f 100644
--- a/ui/grid_view.cpp
+++ b/ui/grid_view.cpp
@@ -181,18 +181,22 @@ GridView::StatusSyncPreview GridView::updateSyncPreview(bool hideFiltered, //map
switch (fsObj->getSyncOperation()) //evaluate comparison result and sync direction
{
case SO_CREATE_NEW_LEFT:
+ case SO_MOVE_LEFT_TARGET:
output.existsSyncCreateLeft = true;
if (!syncCreateLeftActive) continue;
break;
case SO_CREATE_NEW_RIGHT:
+ case SO_MOVE_RIGHT_TARGET:
output.existsSyncCreateRight = true;
if (!syncCreateRightActive) continue;
break;
case SO_DELETE_LEFT:
+ case SO_MOVE_LEFT_SOURCE:
output.existsSyncDeleteLeft = true;
if (!syncDeleteLeftActive) continue;
break;
case SO_DELETE_RIGHT:
+ case SO_MOVE_RIGHT_SOURCE:
output.existsSyncDeleteRight = true;
if (!syncDeleteRightActive) continue;
break;
diff --git a/ui/gui_generated.cpp b/ui/gui_generated.cpp
index 3704d666..2b3761c5 100644
--- a/ui/gui_generated.cpp
+++ b/ui/gui_generated.cpp
@@ -942,6 +942,167 @@ FolderPairGenerated::~FolderPairGenerated()
{
}
+CompareStatusGenerated::CompareStatusGenerated( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style ) : wxPanel( parent, id, pos, size, style )
+{
+ wxBoxSizer* bSizer40;
+ bSizer40 = new wxBoxSizer( wxVERTICAL );
+
+
+ bSizer40->Add( 0, 0, 1, wxEXPAND, 5 );
+
+ wxBoxSizer* bSizer48;
+ bSizer48 = new wxBoxSizer( wxHORIZONTAL );
+
+ m_staticText30 = new wxStaticText( this, wxID_ANY, _("Operation:"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticText30->Wrap( -1 );
+ m_staticText30->SetFont( wxFont( 10, 70, 90, 92, false, wxEmptyString ) );
+
+ bSizer48->Add( m_staticText30, 0, wxRIGHT|wxALIGN_CENTER_VERTICAL, 5 );
+
+ m_textCtrlStatus = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_READONLY );
+ m_textCtrlStatus->SetBackgroundColour( wxColour( 208, 208, 208 ) );
+
+ bSizer48->Add( m_textCtrlStatus, 1, wxALIGN_CENTER_HORIZONTAL|wxALIGN_CENTER_VERTICAL, 5 );
+
+ bSizer40->Add( bSizer48, 0, wxALIGN_CENTER_HORIZONTAL|wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
+
+ m_gauge2 = new wxGauge( this, wxID_ANY, 100, wxDefaultPosition, wxSize( -1,14 ), wxGA_HORIZONTAL|wxGA_SMOOTH );
+ bSizer40->Add( m_gauge2, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
+
+ bSizer42 = new wxBoxSizer( wxHORIZONTAL );
+
+ wxBoxSizer* bSizer157;
+ bSizer157 = new wxBoxSizer( wxVERTICAL );
+
+ bSizerFilesFound = new wxBoxSizer( wxHORIZONTAL );
+
+ m_staticText321 = new wxStaticText( this, wxID_ANY, _("Items found:"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticText321->Wrap( -1 );
+ m_staticText321->SetFont( wxFont( 10, 70, 90, 90, false, wxEmptyString ) );
+
+ bSizerFilesFound->Add( m_staticText321, 0, wxALIGN_BOTTOM, 5 );
+
+ m_staticTextScanned = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticTextScanned->Wrap( -1 );
+ m_staticTextScanned->SetFont( wxFont( 9, 74, 90, 92, false, wxT("Arial") ) );
+
+ bSizerFilesFound->Add( m_staticTextScanned, 0, wxALIGN_BOTTOM|wxLEFT, 5 );
+
+ bSizer157->Add( bSizerFilesFound, 0, 0, 5 );
+
+ bSizerFilesRemaining = new wxBoxSizer( wxHORIZONTAL );
+
+ m_staticText46 = new wxStaticText( this, wxID_ANY, _("Items remaining:"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticText46->Wrap( -1 );
+ m_staticText46->SetFont( wxFont( 10, 70, 90, 90, false, wxEmptyString ) );
+
+ bSizerFilesRemaining->Add( m_staticText46, 0, wxALIGN_BOTTOM, 5 );
+
+ wxBoxSizer* bSizer154;
+ bSizer154 = new wxBoxSizer( wxHORIZONTAL );
+
+ m_staticTextFilesRemaining = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticTextFilesRemaining->Wrap( -1 );
+ m_staticTextFilesRemaining->SetFont( wxFont( 9, 74, 90, 92, false, wxT("Arial") ) );
+
+ bSizer154->Add( m_staticTextFilesRemaining, 0, wxALIGN_BOTTOM, 5 );
+
+ m_staticText117 = new wxStaticText( this, wxID_ANY, _("("), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticText117->Wrap( -1 );
+ m_staticText117->SetFont( wxFont( 9, 74, 90, 90, false, wxT("Arial") ) );
+
+ bSizer154->Add( m_staticText117, 0, wxLEFT|wxALIGN_BOTTOM, 5 );
+
+ m_staticTextDataRemaining = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticTextDataRemaining->Wrap( -1 );
+ m_staticTextDataRemaining->SetFont( wxFont( 9, 74, 90, 90, false, wxT("Arial") ) );
+
+ bSizer154->Add( m_staticTextDataRemaining, 0, wxALIGN_BOTTOM, 5 );
+
+ m_staticText118 = new wxStaticText( this, wxID_ANY, _(")"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticText118->Wrap( -1 );
+ m_staticText118->SetFont( wxFont( 9, 74, 90, 90, false, wxT("Arial") ) );
+
+ bSizer154->Add( m_staticText118, 0, wxALIGN_BOTTOM, 5 );
+
+ bSizerFilesRemaining->Add( bSizer154, 0, wxALIGN_BOTTOM|wxLEFT, 5 );
+
+ bSizer157->Add( bSizerFilesRemaining, 0, 0, 5 );
+
+ bSizer42->Add( bSizer157, 0, wxALIGN_CENTER_VERTICAL, 5 );
+
+
+ bSizer42->Add( 0, 0, 1, wxEXPAND, 5 );
+
+ sSizerSpeed = new wxBoxSizer( wxHORIZONTAL );
+
+ m_staticText104 = new wxStaticText( this, wxID_ANY, _("Speed:"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticText104->Wrap( -1 );
+ m_staticText104->SetFont( wxFont( 10, 70, 90, 90, false, wxEmptyString ) );
+
+ sSizerSpeed->Add( m_staticText104, 0, wxALIGN_BOTTOM, 5 );
+
+ m_staticTextSpeed = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticTextSpeed->Wrap( -1 );
+ m_staticTextSpeed->SetFont( wxFont( 9, 74, 90, 92, false, wxT("Arial") ) );
+
+ sSizerSpeed->Add( m_staticTextSpeed, 0, wxLEFT|wxALIGN_BOTTOM, 5 );
+
+ bSizer42->Add( sSizerSpeed, 0, wxALIGN_CENTER_VERTICAL, 5 );
+
+
+ bSizer42->Add( 10, 0, 0, wxALIGN_CENTER_VERTICAL, 5 );
+
+ sSizerTimeRemaining = new wxBoxSizer( wxHORIZONTAL );
+
+ m_staticTextTimeRemFixed = new wxStaticText( this, wxID_ANY, _("Time remaining:"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticTextTimeRemFixed->Wrap( -1 );
+ m_staticTextTimeRemFixed->SetFont( wxFont( 10, 70, 90, 90, false, wxEmptyString ) );
+
+ sSizerTimeRemaining->Add( m_staticTextTimeRemFixed, 0, wxALIGN_BOTTOM, 5 );
+
+ m_staticTextRemTime = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticTextRemTime->Wrap( -1 );
+ m_staticTextRemTime->SetFont( wxFont( 9, 74, 90, 92, false, wxT("Arial") ) );
+
+ sSizerTimeRemaining->Add( m_staticTextRemTime, 0, wxLEFT|wxALIGN_BOTTOM, 5 );
+
+ bSizer42->Add( sSizerTimeRemaining, 0, wxALIGN_CENTER_VERTICAL, 5 );
+
+
+ bSizer42->Add( 0, 0, 1, wxEXPAND, 5 );
+
+ sSizerTimeElapsed = new wxBoxSizer( wxHORIZONTAL );
+
+ wxStaticText* m_staticText37;
+ m_staticText37 = new wxStaticText( this, wxID_ANY, _("Time elapsed:"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticText37->Wrap( -1 );
+ m_staticText37->SetFont( wxFont( 10, 70, 90, 90, false, wxEmptyString ) );
+
+ sSizerTimeElapsed->Add( m_staticText37, 0, wxALIGN_BOTTOM, 5 );
+
+ m_staticTextTimeElapsed = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticTextTimeElapsed->Wrap( -1 );
+ m_staticTextTimeElapsed->SetFont( wxFont( 9, 74, 90, 92, false, wxT("Arial") ) );
+
+ sSizerTimeElapsed->Add( m_staticTextTimeElapsed, 0, wxLEFT|wxALIGN_BOTTOM, 5 );
+
+ bSizer42->Add( sSizerTimeElapsed, 0, wxALIGN_CENTER_VERTICAL, 5 );
+
+ bSizer40->Add( bSizer42, 0, wxALIGN_CENTER_HORIZONTAL|wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
+
+
+ bSizer40->Add( 0, 0, 1, wxEXPAND, 5 );
+
+ this->SetSizer( bSizer40 );
+ this->Layout();
+ bSizer40->Fit( this );
+}
+
+CompareStatusGenerated::~CompareStatusGenerated()
+{
+}
+
BatchDlgGenerated::BatchDlgGenerated( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : wxDialog( parent, id, title, pos, size, style )
{
this->SetSizeHints( wxSize( 560,320 ), wxDefaultSize );
@@ -1464,167 +1625,6 @@ BatchFolderPairGenerated::~BatchFolderPairGenerated()
{
}
-CompareStatusGenerated::CompareStatusGenerated( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style ) : wxPanel( parent, id, pos, size, style )
-{
- wxBoxSizer* bSizer40;
- bSizer40 = new wxBoxSizer( wxVERTICAL );
-
-
- bSizer40->Add( 0, 0, 1, wxEXPAND, 5 );
-
- wxBoxSizer* bSizer48;
- bSizer48 = new wxBoxSizer( wxHORIZONTAL );
-
- m_staticText30 = new wxStaticText( this, wxID_ANY, _("Operation:"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticText30->Wrap( -1 );
- m_staticText30->SetFont( wxFont( 10, 70, 90, 92, false, wxEmptyString ) );
-
- bSizer48->Add( m_staticText30, 0, wxRIGHT|wxALIGN_CENTER_VERTICAL, 5 );
-
- m_textCtrlStatus = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_READONLY );
- m_textCtrlStatus->SetBackgroundColour( wxColour( 208, 208, 208 ) );
-
- bSizer48->Add( m_textCtrlStatus, 1, wxALIGN_CENTER_HORIZONTAL|wxALIGN_CENTER_VERTICAL, 5 );
-
- bSizer40->Add( bSizer48, 0, wxALIGN_CENTER_HORIZONTAL|wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
-
- m_gauge2 = new wxGauge( this, wxID_ANY, 100, wxDefaultPosition, wxSize( -1,14 ), wxGA_HORIZONTAL|wxGA_SMOOTH );
- bSizer40->Add( m_gauge2, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
-
- bSizer42 = new wxBoxSizer( wxHORIZONTAL );
-
- wxBoxSizer* bSizer157;
- bSizer157 = new wxBoxSizer( wxVERTICAL );
-
- bSizerFilesFound = new wxBoxSizer( wxHORIZONTAL );
-
- m_staticText321 = new wxStaticText( this, wxID_ANY, _("Items found:"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticText321->Wrap( -1 );
- m_staticText321->SetFont( wxFont( 10, 70, 90, 90, false, wxEmptyString ) );
-
- bSizerFilesFound->Add( m_staticText321, 0, wxALIGN_BOTTOM, 5 );
-
- m_staticTextScanned = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticTextScanned->Wrap( -1 );
- m_staticTextScanned->SetFont( wxFont( 9, 74, 90, 92, false, wxT("Arial") ) );
-
- bSizerFilesFound->Add( m_staticTextScanned, 0, wxALIGN_BOTTOM|wxLEFT, 5 );
-
- bSizer157->Add( bSizerFilesFound, 0, 0, 5 );
-
- bSizerFilesRemaining = new wxBoxSizer( wxHORIZONTAL );
-
- m_staticText46 = new wxStaticText( this, wxID_ANY, _("Items remaining:"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticText46->Wrap( -1 );
- m_staticText46->SetFont( wxFont( 10, 70, 90, 90, false, wxEmptyString ) );
-
- bSizerFilesRemaining->Add( m_staticText46, 0, wxALIGN_BOTTOM, 5 );
-
- wxBoxSizer* bSizer154;
- bSizer154 = new wxBoxSizer( wxHORIZONTAL );
-
- m_staticTextFilesRemaining = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticTextFilesRemaining->Wrap( -1 );
- m_staticTextFilesRemaining->SetFont( wxFont( 9, 74, 90, 92, false, wxT("Arial") ) );
-
- bSizer154->Add( m_staticTextFilesRemaining, 0, wxALIGN_BOTTOM, 5 );
-
- m_staticText117 = new wxStaticText( this, wxID_ANY, _("("), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticText117->Wrap( -1 );
- m_staticText117->SetFont( wxFont( 9, 74, 90, 90, false, wxT("Arial") ) );
-
- bSizer154->Add( m_staticText117, 0, wxLEFT|wxALIGN_BOTTOM, 5 );
-
- m_staticTextDataRemaining = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticTextDataRemaining->Wrap( -1 );
- m_staticTextDataRemaining->SetFont( wxFont( 9, 74, 90, 90, false, wxT("Arial") ) );
-
- bSizer154->Add( m_staticTextDataRemaining, 0, wxALIGN_BOTTOM, 5 );
-
- m_staticText118 = new wxStaticText( this, wxID_ANY, _(")"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticText118->Wrap( -1 );
- m_staticText118->SetFont( wxFont( 9, 74, 90, 90, false, wxT("Arial") ) );
-
- bSizer154->Add( m_staticText118, 0, wxALIGN_BOTTOM, 5 );
-
- bSizerFilesRemaining->Add( bSizer154, 0, wxALIGN_BOTTOM|wxLEFT, 5 );
-
- bSizer157->Add( bSizerFilesRemaining, 0, 0, 5 );
-
- bSizer42->Add( bSizer157, 0, wxALIGN_CENTER_VERTICAL, 5 );
-
-
- bSizer42->Add( 0, 0, 1, wxEXPAND, 5 );
-
- sSizerSpeed = new wxBoxSizer( wxHORIZONTAL );
-
- m_staticText104 = new wxStaticText( this, wxID_ANY, _("Speed:"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticText104->Wrap( -1 );
- m_staticText104->SetFont( wxFont( 10, 70, 90, 90, false, wxEmptyString ) );
-
- sSizerSpeed->Add( m_staticText104, 0, wxALIGN_BOTTOM, 5 );
-
- m_staticTextSpeed = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticTextSpeed->Wrap( -1 );
- m_staticTextSpeed->SetFont( wxFont( 9, 74, 90, 92, false, wxT("Arial") ) );
-
- sSizerSpeed->Add( m_staticTextSpeed, 0, wxLEFT|wxALIGN_BOTTOM, 5 );
-
- bSizer42->Add( sSizerSpeed, 0, wxALIGN_CENTER_VERTICAL, 5 );
-
-
- bSizer42->Add( 10, 0, 0, wxALIGN_CENTER_VERTICAL, 5 );
-
- sSizerTimeRemaining = new wxBoxSizer( wxHORIZONTAL );
-
- m_staticTextTimeRemFixed = new wxStaticText( this, wxID_ANY, _("Time remaining:"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticTextTimeRemFixed->Wrap( -1 );
- m_staticTextTimeRemFixed->SetFont( wxFont( 10, 70, 90, 90, false, wxEmptyString ) );
-
- sSizerTimeRemaining->Add( m_staticTextTimeRemFixed, 0, wxALIGN_BOTTOM, 5 );
-
- m_staticTextRemTime = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticTextRemTime->Wrap( -1 );
- m_staticTextRemTime->SetFont( wxFont( 9, 74, 90, 92, false, wxT("Arial") ) );
-
- sSizerTimeRemaining->Add( m_staticTextRemTime, 0, wxLEFT|wxALIGN_BOTTOM, 5 );
-
- bSizer42->Add( sSizerTimeRemaining, 0, wxALIGN_CENTER_VERTICAL, 5 );
-
-
- bSizer42->Add( 0, 0, 1, wxEXPAND, 5 );
-
- sSizerTimeElapsed = new wxBoxSizer( wxHORIZONTAL );
-
- wxStaticText* m_staticText37;
- m_staticText37 = new wxStaticText( this, wxID_ANY, _("Time elapsed:"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticText37->Wrap( -1 );
- m_staticText37->SetFont( wxFont( 10, 70, 90, 90, false, wxEmptyString ) );
-
- sSizerTimeElapsed->Add( m_staticText37, 0, wxALIGN_BOTTOM, 5 );
-
- m_staticTextTimeElapsed = new wxStaticText( this, wxID_ANY, _("dummy"), wxDefaultPosition, wxDefaultSize, 0 );
- m_staticTextTimeElapsed->Wrap( -1 );
- m_staticTextTimeElapsed->SetFont( wxFont( 9, 74, 90, 92, false, wxT("Arial") ) );
-
- sSizerTimeElapsed->Add( m_staticTextTimeElapsed, 0, wxLEFT|wxALIGN_BOTTOM, 5 );
-
- bSizer42->Add( sSizerTimeElapsed, 0, wxALIGN_CENTER_VERTICAL, 5 );
-
- bSizer40->Add( bSizer42, 0, wxALIGN_CENTER_HORIZONTAL|wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
-
-
- bSizer40->Add( 0, 0, 1, wxEXPAND, 5 );
-
- this->SetSizer( bSizer40 );
- this->Layout();
- bSizer40->Fit( this );
-}
-
-CompareStatusGenerated::~CompareStatusGenerated()
-{
-}
-
SyncCfgDlgGenerated::SyncCfgDlgGenerated( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : wxDialog( parent, id, title, pos, size, style )
{
this->SetSizeHints( wxDefaultSize, wxDefaultSize );
@@ -1663,7 +1663,7 @@ SyncCfgDlgGenerated::SyncCfgDlgGenerated( wxWindow* parent, wxWindowID id, const
fgSizer1->Add( m_buttonAutomatic, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
- m_staticText81 = new wxStaticText( this, wxID_ANY, _("Identify and propagate changes on both sides using a database. Deletions and conflicts are detected automatically."), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticText81 = new wxStaticText( this, wxID_ANY, _("Identify and propagate changes on both sides using a database. Deletions, renaming and conflicts are detected automatically."), wxDefaultPosition, wxDefaultSize, 0 );
m_staticText81->Wrap( 400 );
fgSizer1->Add( m_staticText81, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
@@ -2282,12 +2282,12 @@ SyncStatusDlgGenerated::SyncStatusDlgGenerated( wxWindow* parent, wxWindowID id,
bSizerFinalStat = new wxBoxSizer( wxVERTICAL );
m_listbookResult = new wxListbook( m_panelBackground, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLB_TOP );
-#ifndef __WXGTK__ // Small icon style not supported in GTK
- wxListView* m_listbookResultListView = m_listbookResult->GetListView();
- long m_listbookResultFlags = m_listbookResultListView->GetWindowStyleFlag();
- m_listbookResultFlags = ( m_listbookResultFlags & ~wxLC_ICON ) | wxLC_SMALL_ICON;
- m_listbookResultListView->SetWindowStyleFlag( m_listbookResultFlags );
-#endif
+ wxSize m_listbookResultImageSize = wxSize( 180,1 );
+ int m_listbookResultIndex = 0;
+ wxImageList* m_listbookResultImages = new wxImageList( m_listbookResultImageSize.GetWidth(), m_listbookResultImageSize.GetHeight() );
+ m_listbookResult->AssignImageList( m_listbookResultImages );
+ wxBitmap m_listbookResultBitmap;
+ wxImage m_listbookResultImage;
bSizerFinalStat->Add( m_listbookResult, 1, wxEXPAND, 5 );
@@ -2351,14 +2351,6 @@ SyncStatusDlgGenerated::~SyncStatusDlgGenerated()
}
-MyPanel5::MyPanel5( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style ) : wxPanel( parent, id, pos, size, style )
-{
-}
-
-MyPanel5::~MyPanel5()
-{
-}
-
LogControlGenerated::LogControlGenerated( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style ) : wxPanel( parent, id, pos, size, style )
{
wxBoxSizer* bSizer153;
@@ -3420,30 +3412,29 @@ GlobalSettingsDlgGenerated::GlobalSettingsDlgGenerated( wxWindow* parent, wxWind
m_checkBoxTransCopy = new wxCheckBox( this, wxID_ANY, _("Transactional file copy"), wxDefaultPosition, wxDefaultSize, 0 );
sbSizer23->Add( m_checkBoxTransCopy, 0, wxEXPAND|wxALL, 5 );
- m_textCtrl22 = new wxTextCtrl( this, wxID_ANY, _("Write to a temporary file (*.ffs_tmp) first then rename it. This guarantees a consistent state even in case of fatal error."), wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE|wxTE_NO_VSCROLL|wxTE_READONLY|wxNO_BORDER );
- m_textCtrl22->SetForegroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_GRAYTEXT ) );
- m_textCtrl22->SetBackgroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_BTNFACE ) );
- m_textCtrl22->SetMinSize( wxSize( 400,-1 ) );
+ m_staticText82 = new wxStaticText( this, wxID_ANY, _("Write to a temporary file (*.ffs_tmp) first then rename it. This guarantees a consistent state even in case of fatal error."), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticText82->Wrap( 400 );
+ m_staticText82->SetForegroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_GRAYTEXT ) );
- sbSizer23->Add( m_textCtrl22, 0, wxLEFT|wxEXPAND, 20 );
+ sbSizer23->Add( m_staticText82, 0, wxLEFT, 20 );
m_checkBoxCopyLocked = new wxCheckBox( this, wxID_ANY, _("Copy locked files"), wxDefaultPosition, wxDefaultSize, 0 );
sbSizer23->Add( m_checkBoxCopyLocked, 0, wxALL|wxEXPAND, 5 );
- m_textCtrlCopyLocked = new wxTextCtrl( this, wxID_ANY, _("Copy shared or locked files using Volume Shadow Copy Service (Requires Administrator rights)"), wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE|wxTE_NO_VSCROLL|wxTE_READONLY|wxNO_BORDER );
- m_textCtrlCopyLocked->SetForegroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_GRAYTEXT ) );
- m_textCtrlCopyLocked->SetBackgroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_BTNFACE ) );
+ m_staticTextCopyLocked = new wxStaticText( this, wxID_ANY, _("Copy shared or locked files using Volume Shadow Copy Service (Requires Administrator rights)"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticTextCopyLocked->Wrap( 400 );
+ m_staticTextCopyLocked->SetForegroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_GRAYTEXT ) );
- sbSizer23->Add( m_textCtrlCopyLocked, 0, wxLEFT|wxEXPAND, 20 );
+ sbSizer23->Add( m_staticTextCopyLocked, 0, wxLEFT|wxEXPAND, 20 );
m_checkBoxCopyPermissions = new wxCheckBox( this, wxID_ANY, _("Copy file access permissions"), wxDefaultPosition, wxDefaultSize, 0 );
sbSizer23->Add( m_checkBoxCopyPermissions, 0, wxALL|wxEXPAND, 5 );
- m_textCtrl2211 = new wxTextCtrl( this, wxID_ANY, _("Transfer file and directory permissions (Requires Administrator rights)"), wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE|wxTE_NO_VSCROLL|wxTE_READONLY|wxNO_BORDER );
- m_textCtrl2211->SetForegroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_GRAYTEXT ) );
- m_textCtrl2211->SetBackgroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_BTNFACE ) );
+ m_staticText8211 = new wxStaticText( this, wxID_ANY, _("Transfer file and directory permissions (Requires Administrator rights)"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_staticText8211->Wrap( 400 );
+ m_staticText8211->SetForegroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_GRAYTEXT ) );
- sbSizer23->Add( m_textCtrl2211, 0, wxLEFT|wxEXPAND, 20 );
+ sbSizer23->Add( m_staticText8211, 0, wxLEFT|wxEXPAND, 20 );
bSizer95->Add( sbSizer23, 0, wxALIGN_CENTER_HORIZONTAL|wxRIGHT|wxLEFT|wxEXPAND, 5 );
diff --git a/ui/gui_generated.h b/ui/gui_generated.h
index de1dc89b..8fc345a2 100644
--- a/ui/gui_generated.h
+++ b/ui/gui_generated.h
@@ -46,14 +46,15 @@ namespace zen { class Graph2D; }
#include <wx/textctrl.h>
#include <wx/statline.h>
#include <wx/frame.h>
+#include <wx/gauge.h>
#include <wx/choice.h>
#include <wx/spinctrl.h>
#include <wx/listbook.h>
#include <wx/listctrl.h>
#include <wx/dialog.h>
-#include <wx/gauge.h>
#include <wx/radiobut.h>
#include <wx/animate.h>
+#include <wx/imaglist.h>
#include <wx/hyperlink.h>
#include <wx/checklst.h>
#include <wx/calctrl.h>
@@ -263,6 +264,43 @@ public:
};
///////////////////////////////////////////////////////////////////////////////
+/// Class CompareStatusGenerated
+///////////////////////////////////////////////////////////////////////////////
+class CompareStatusGenerated : public wxPanel
+{
+private:
+
+protected:
+ wxStaticText* m_staticText30;
+ wxTextCtrl* m_textCtrlStatus;
+ wxGauge* m_gauge2;
+ wxBoxSizer* bSizer42;
+ wxBoxSizer* bSizerFilesFound;
+ wxStaticText* m_staticText321;
+ wxStaticText* m_staticTextScanned;
+ wxBoxSizer* bSizerFilesRemaining;
+ wxStaticText* m_staticText46;
+ wxStaticText* m_staticTextFilesRemaining;
+ wxStaticText* m_staticText117;
+ wxStaticText* m_staticTextDataRemaining;
+ wxStaticText* m_staticText118;
+ wxBoxSizer* sSizerSpeed;
+ wxStaticText* m_staticText104;
+ wxStaticText* m_staticTextSpeed;
+ wxBoxSizer* sSizerTimeRemaining;
+ wxStaticText* m_staticTextTimeRemFixed;
+ wxStaticText* m_staticTextRemTime;
+ wxBoxSizer* sSizerTimeElapsed;
+ wxStaticText* m_staticTextTimeElapsed;
+
+public:
+
+ CompareStatusGenerated( wxWindow* parent, wxWindowID id = wxID_ANY, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxRAISED_BORDER|wxTAB_TRAVERSAL );
+ ~CompareStatusGenerated();
+
+};
+
+///////////////////////////////////////////////////////////////////////////////
/// Class BatchDlgGenerated
///////////////////////////////////////////////////////////////////////////////
class BatchDlgGenerated : public wxDialog
@@ -365,43 +403,6 @@ public:
};
///////////////////////////////////////////////////////////////////////////////
-/// Class CompareStatusGenerated
-///////////////////////////////////////////////////////////////////////////////
-class CompareStatusGenerated : public wxPanel
-{
-private:
-
-protected:
- wxStaticText* m_staticText30;
- wxTextCtrl* m_textCtrlStatus;
- wxGauge* m_gauge2;
- wxBoxSizer* bSizer42;
- wxBoxSizer* bSizerFilesFound;
- wxStaticText* m_staticText321;
- wxStaticText* m_staticTextScanned;
- wxBoxSizer* bSizerFilesRemaining;
- wxStaticText* m_staticText46;
- wxStaticText* m_staticTextFilesRemaining;
- wxStaticText* m_staticText117;
- wxStaticText* m_staticTextDataRemaining;
- wxStaticText* m_staticText118;
- wxBoxSizer* sSizerSpeed;
- wxStaticText* m_staticText104;
- wxStaticText* m_staticTextSpeed;
- wxBoxSizer* sSizerTimeRemaining;
- wxStaticText* m_staticTextTimeRemFixed;
- wxStaticText* m_staticTextRemTime;
- wxBoxSizer* sSizerTimeElapsed;
- wxStaticText* m_staticTextTimeElapsed;
-
-public:
-
- CompareStatusGenerated( wxWindow* parent, wxWindowID id = wxID_ANY, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxRAISED_BORDER|wxTAB_TRAVERSAL );
- ~CompareStatusGenerated();
-
-};
-
-///////////////////////////////////////////////////////////////////////////////
/// Class SyncCfgDlgGenerated
///////////////////////////////////////////////////////////////////////////////
class SyncCfgDlgGenerated : public wxDialog
@@ -586,22 +587,6 @@ public:
};
///////////////////////////////////////////////////////////////////////////////
-/// Class MyPanel5
-///////////////////////////////////////////////////////////////////////////////
-class MyPanel5 : public wxPanel
-{
-private:
-
-protected:
-
-public:
-
- MyPanel5( wxWindow* parent, wxWindowID id = wxID_ANY, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 500,300 ), long style = wxTAB_TRAVERSAL );
- ~MyPanel5();
-
-};
-
-///////////////////////////////////////////////////////////////////////////////
/// Class LogControlGenerated
///////////////////////////////////////////////////////////////////////////////
class LogControlGenerated : public wxPanel
@@ -904,11 +889,11 @@ protected:
wxPanel* m_panel8;
wxStaticText* m_staticText56;
wxCheckBox* m_checkBoxTransCopy;
- wxTextCtrl* m_textCtrl22;
+ wxStaticText* m_staticText82;
wxCheckBox* m_checkBoxCopyLocked;
- wxTextCtrl* m_textCtrlCopyLocked;
+ wxStaticText* m_staticTextCopyLocked;
wxCheckBox* m_checkBoxCopyPermissions;
- wxTextCtrl* m_textCtrl2211;
+ wxStaticText* m_staticText8211;
wxStaticText* m_staticText100;
zen::BitmapButton* m_buttonResetDialogs;
wxGrid* m_gridCustomCommand;
diff --git a/ui/gui_status_handler.cpp b/ui/gui_status_handler.cpp
index b353e918..6809b362 100644
--- a/ui/gui_status_handler.cpp
+++ b/ui/gui_status_handler.cpp
@@ -114,21 +114,21 @@ void CompareStatusHandler::updateProcessedData(int objectsProcessed, zen::Int64
}
-void CompareStatusHandler::reportStatus(const wxString& text)
+void CompareStatusHandler::reportStatus(const std::wstring& text)
{
mainDlg.compareStatus->setStatusText_NoUpdate(text);
requestUiRefresh(); //throw AbortThisProcess
}
-void CompareStatusHandler::reportInfo(const wxString& text)
+void CompareStatusHandler::reportInfo(const std::wstring& text)
{
mainDlg.compareStatus->setStatusText_NoUpdate(text);
requestUiRefresh(); //throw AbortThisProcess
}
-ProcessCallback::Response CompareStatusHandler::reportError(const wxString& message)
+ProcessCallback::Response CompareStatusHandler::reportError(const std::wstring& message)
{
if (ignoreErrors)
return ProcessCallback::IGNORE_ERROR;
@@ -155,7 +155,7 @@ ProcessCallback::Response CompareStatusHandler::reportError(const wxString& mess
}
-void CompareStatusHandler::reportFatalError(const wxString& errorMessage)
+void CompareStatusHandler::reportFatalError(const std::wstring& errorMessage)
{
forceUiRefresh();
@@ -165,7 +165,7 @@ void CompareStatusHandler::reportFatalError(const wxString& errorMessage)
}
-void CompareStatusHandler::reportWarning(const wxString& warningMessage, bool& warningActive)
+void CompareStatusHandler::reportWarning(const std::wstring& warningMessage, bool& warningActive)
{
if (!warningActive || ignoreErrors) //if errors are ignored, then warnings should also
return;
@@ -266,14 +266,14 @@ void SyncStatusHandler::updateProcessedData(int objectsProcessed, zen::Int64 dat
}
-void SyncStatusHandler::reportStatus(const wxString& text)
+void SyncStatusHandler::reportStatus(const std::wstring& text)
{
syncStatusFrame.setStatusText_NoUpdate(text); //throw ()
requestUiRefresh(); //throw AbortThisProccess
}
-void SyncStatusHandler::reportInfo(const wxString& text)
+void SyncStatusHandler::reportInfo(const std::wstring& text)
{
errorLog.logMsg(text, TYPE_INFO);
@@ -282,7 +282,7 @@ void SyncStatusHandler::reportInfo(const wxString& text)
}
-ProcessCallback::Response SyncStatusHandler::reportError(const wxString& errorMessage)
+ProcessCallback::Response SyncStatusHandler::reportError(const std::wstring& errorMessage)
{
switch (handleError_)
{
@@ -320,13 +320,13 @@ ProcessCallback::Response SyncStatusHandler::reportError(const wxString& errorMe
}
-void SyncStatusHandler::reportFatalError(const wxString& errorMessage)
+void SyncStatusHandler::reportFatalError(const std::wstring& errorMessage)
{
errorLog.logMsg(errorMessage, TYPE_FATAL_ERROR);
}
-void SyncStatusHandler::reportWarning(const wxString& warningMessage, bool& warningActive)
+void SyncStatusHandler::reportWarning(const std::wstring& warningMessage, bool& warningActive)
{
errorLog.logMsg(warningMessage, TYPE_WARNING);
diff --git a/ui/gui_status_handler.h b/ui/gui_status_handler.h
index 28429d68..997e511f 100644
--- a/ui/gui_status_handler.h
+++ b/ui/gui_status_handler.h
@@ -29,13 +29,13 @@ public:
virtual void initNewProcess(int objectsTotal, zen::Int64 dataTotal, Process processID);
virtual void updateProcessedData(int objectsProcessed, zen::Int64 dataProcessed);
- virtual void reportStatus(const wxString& text);
- virtual void reportInfo(const wxString& text);
+ virtual void reportStatus(const std::wstring& text);
+ virtual void reportInfo(const std::wstring& text);
virtual void forceUiRefresh();
- virtual Response reportError(const wxString& text);
- virtual void reportFatalError(const wxString& errorMessage);
- virtual void reportWarning(const wxString& warningMessage, bool& warningActive);
+ virtual Response reportError(const std::wstring& text);
+ virtual void reportFatalError(const std::wstring& errorMessage);
+ virtual void reportWarning(const std::wstring& warningMessage, bool& warningActive);
private:
void OnKeyPressed(wxKeyEvent& event);
@@ -56,13 +56,13 @@ public:
virtual void initNewProcess(int objectsTotal, zen::Int64 dataTotal, Process processID);
virtual void updateProcessedData(int objectsProcessed, zen::Int64 dataProcessed);
- virtual void reportStatus(const wxString& text);
- virtual void reportInfo(const wxString& text);
+ virtual void reportStatus(const std::wstring& text);
+ virtual void reportInfo(const std::wstring& text);
virtual void forceUiRefresh();
- virtual Response reportError(const wxString& text);
- virtual void reportFatalError(const wxString& errorMessage);
- virtual void reportWarning(const wxString& warningMessage, bool& warningActive);
+ virtual Response reportError(const std::wstring& text);
+ virtual void reportFatalError(const std::wstring& errorMessage);
+ virtual void reportWarning(const std::wstring& warningMessage, bool& warningActive);
private:
virtual void abortThisProcess();
diff --git a/ui/main_dlg.cpp b/ui/main_dlg.cpp
index e1227509..97c3625c 100644
--- a/ui/main_dlg.cpp
+++ b/ui/main_dlg.cpp
@@ -662,8 +662,8 @@ void MainDialog::init(const xmlAccess::XmlGuiConfig guiCfg,
if (dirFmtLeft.empty() && dirFmtRight.empty()) //only skip check if both sides are empty!
return;
- dirEx.push_back(zen::async2<bool>([=]() { return !dirFmtLeft .empty() && zen::dirExists(dirFmtLeft); }));
- dirEx.push_back(zen::async2<bool>([=]() { return !dirFmtRight.empty() && zen::dirExists(dirFmtRight); }));
+ dirEx.push_back(zen::async2<bool>([=] { return !dirFmtLeft .empty() && zen::dirExists(dirFmtLeft); }));
+ dirEx.push_back(zen::async2<bool>([=] { return !dirFmtRight.empty() && zen::dirExists(dirFmtRight); }));
};
addDirCheck(currMainCfg.firstPair);
std::for_each(currMainCfg.additionalPairs.begin(), currMainCfg.additionalPairs.end(), addDirCheck);
@@ -972,7 +972,7 @@ public:
mainDlg->enableAllElements();
}
- virtual Response reportError(const wxString& errorMessage)
+ virtual Response reportError(const std::wstring& errorMessage)
{
if (abortRequested)
throw AbortDeleteProcess();
@@ -1122,17 +1122,6 @@ wxString extractLastValidDir(const FileSystemObject& fsObj)
return toWx(fullname);
}
-bool tryReplace(const wxString& phrase, const wxString& replacement, wxString& command) //return false on error
-{
- if (command.find(phrase) != wxString::npos)
- {
- if (replacement.empty())
- return false;
- replace(command, phrase, replacement);
- }
- return true;
-}
-
void MainDialog::openExternalApplication(size_t rowNumber, bool leftSide, const wxString& commandline)
{
@@ -1163,10 +1152,22 @@ void MainDialog::openExternalApplication(size_t rowNumber, bool leftSide, const
}
wxString command = commandline;
- if (tryReplace(L"%nameCo", nameCo, command) && //attention: replace %nameCo, %dirCo BEFORE %name, %dir to handle dependency
- tryReplace(L"%dirCo", dirCo, command) &&
- tryReplace(L"%name", name, command) &&
- tryReplace(L"%dir", dir, command))
+
+ auto tryReplace = [&](const wxString& phrase, const wxString& replacement) -> bool
+ {
+ if (command.find(phrase) != wxString::npos)
+ {
+ if (replacement.empty())
+ return false;
+ replace(command, phrase, replacement);
+ }
+ return true;
+ };
+
+ if (tryReplace(L"%nameCo", nameCo) && //attention: replace %nameCo, %dirCo BEFORE %name, %dir to handle dependency
+ tryReplace(L"%dirCo", dirCo ) &&
+ tryReplace(L"%name", name ) &&
+ tryReplace(L"%dir", dir ))
zen::shellExecute(command);
else //fallback
{
@@ -1246,9 +1247,6 @@ void MainDialog::disableAllElements(bool enableAbort)
if (m_buttonAbort->IsShownOnScreen()) m_buttonAbort->SetFocus();
m_buttonCompare->Disable();
m_buttonCompare->Hide();
- m_bpButtonCmpConfig ->Disable();
- m_bpButtonSyncConfig->Disable();
- m_buttonStartSync ->Disable();
m_panelTopButtons->Layout();
}
else
@@ -1261,7 +1259,7 @@ void MainDialog::enableAllElements()
EnableCloseButton(true);
m_panelViewFilter ->Enable();
- m_bpButtonCmpConfig ->Enable();
+ m_bpButtonCmpConfig ->Enable(); //wxGTK bug: this line seems to move main dialog to top!!!!!!!
m_panelFilter ->Enable();
m_panelConfig ->Enable();
m_bpButtonSyncConfig ->Enable();
@@ -1277,9 +1275,6 @@ void MainDialog::enableAllElements()
m_buttonAbort->Hide();
m_buttonCompare->Enable();
m_buttonCompare->Show();
- m_bpButtonCmpConfig ->Enable();
- m_bpButtonSyncConfig->Enable();
- m_buttonStartSync ->Enable();
m_panelTopButtons->Layout();
m_panelTopButtons->Enable();
@@ -3428,7 +3423,7 @@ void MainDialog::updateStatistics()
//update preview of bytes to be transferred:
const SyncStatistics st(gridDataView->getDataTentative());
const wxString toCreate = zen::toStringSep(st.getCreate());
- const wxString toUpdate = zen::toStringSep(st.getOverwrite());
+ const wxString toUpdate = zen::toStringSep(st.getUpdate());
const wxString toDelete = zen::toStringSep(st.getDelete());
const wxString data = zen::filesizeToShortString(st.getDataToProcess());
@@ -3977,7 +3972,7 @@ void MainDialog::applySyncConfig()
warningSyncDatabase_(warningSyncDatabase),
parent_(parent) {}
- virtual void reportWarning(const wxString& text)
+ virtual void reportWarning(const std::wstring& text)
{
if (warningSyncDatabase_)
{
@@ -4268,25 +4263,25 @@ void MainDialog::OnMenuExportFileList(wxCommandEvent& event)
exportString += copyStringTo<zxString>(_("Legend")) + wxT('\n');
if (syncPreview->previewIsEnabled())
{
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(SO_CREATE_NEW_LEFT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_CREATE_NEW_LEFT)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(SO_CREATE_NEW_RIGHT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_CREATE_NEW_RIGHT)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(SO_DELETE_LEFT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_DELETE_LEFT)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(SO_DELETE_RIGHT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_DELETE_RIGHT)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(SO_OVERWRITE_LEFT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_OVERWRITE_LEFT)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(SO_OVERWRITE_RIGHT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_OVERWRITE_RIGHT)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(SO_DO_NOTHING)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_DO_NOTHING)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(SO_EQUAL)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_EQUAL)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(SO_UNRESOLVED_CONFLICT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_UNRESOLVED_CONFLICT)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getSyncOpDescription(SO_EQUAL)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_EQUAL)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getSyncOpDescription(SO_CREATE_NEW_LEFT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_CREATE_NEW_LEFT)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getSyncOpDescription(SO_CREATE_NEW_RIGHT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_CREATE_NEW_RIGHT)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getSyncOpDescription(SO_OVERWRITE_LEFT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_OVERWRITE_LEFT)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getSyncOpDescription(SO_OVERWRITE_RIGHT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_OVERWRITE_RIGHT)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getSyncOpDescription(SO_DELETE_LEFT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_DELETE_LEFT)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getSyncOpDescription(SO_DELETE_RIGHT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_DELETE_RIGHT)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getSyncOpDescription(SO_DO_NOTHING)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_DO_NOTHING)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getSyncOpDescription(SO_UNRESOLVED_CONFLICT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(SO_UNRESOLVED_CONFLICT)) + wxT('\n');
}
else
{
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(FILE_LEFT_SIDE_ONLY)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_LEFT_SIDE_ONLY)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(FILE_RIGHT_SIDE_ONLY)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_RIGHT_SIDE_ONLY)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(FILE_LEFT_NEWER)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_LEFT_NEWER)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(FILE_RIGHT_NEWER)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_RIGHT_NEWER)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(FILE_DIFFERENT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_DIFFERENT)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(FILE_EQUAL)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_EQUAL)) + wxT('\n');
- exportString += wxT("\"") + copyStringTo<zxString>(getDescription(FILE_CONFLICT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_CONFLICT)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getCategoryDescription(FILE_EQUAL)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_EQUAL)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getCategoryDescription(FILE_DIFFERENT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_DIFFERENT)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getCategoryDescription(FILE_LEFT_SIDE_ONLY)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_LEFT_SIDE_ONLY)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getCategoryDescription(FILE_RIGHT_SIDE_ONLY)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_RIGHT_SIDE_ONLY)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getCategoryDescription(FILE_LEFT_NEWER)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_LEFT_NEWER)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getCategoryDescription(FILE_RIGHT_NEWER)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_RIGHT_NEWER)) + wxT('\n');
+ exportString += wxT("\"") + copyStringTo<zxString>(getCategoryDescription(FILE_CONFLICT)) + wxT("\";") + copyStringTo<zxString>(getSymbol(FILE_CONFLICT)) + wxT('\n');
}
exportString += wxT('\n');
diff --git a/ui/progress_indicator.cpp b/ui/progress_indicator.cpp
index 25b9d6e8..092cb182 100644
--- a/ui/progress_indicator.cpp
+++ b/ui/progress_indicator.cpp
@@ -6,24 +6,23 @@
#include "progress_indicator.h"
#include <memory>
-#include "gui_generated.h"
+#include <zen/basic_math.h>
+#include <wx/imaglist.h>
#include <wx/stopwatch.h>
-#include "../lib/resources.h"
-#include <wx+/string_conv.h>
-#include <wx+/format_unit.h>
-#include "../lib/statistics.h"
#include <wx/wupdlock.h>
-#include <zen/basic_math.h>
-#include "tray_icon.h"
-#include <memory>
#include <wx+/mouse_move_dlg.h>
-#include "../lib/error_log.h"
#include <wx+/toggle_button.h>
-#include "taskbar.h"
+#include <wx+/string_conv.h>
+#include <wx+/format_unit.h>
#include <wx+/image_tools.h>
#include <wx+/graph.h>
#include <wx+/no_flicker.h>
-#include <zen/basic_math.h>
+#include "gui_generated.h"
+#include "../lib/resources.h"
+#include "../lib/error_log.h"
+#include "../lib/statistics.h"
+#include "tray_icon.h"
+#include "taskbar.h"
using namespace zen;
@@ -289,7 +288,7 @@ void CompareStatus::CompareStatusImpl::updateStatusPanelNow()
showProgressExternally(toStringSep(scannedObjects) + wxT(" - ") + _("Scanning..."));
break;
case COMPARING_CONTENT:
- showProgressExternally(percentageToShortString(fraction) + wxT(" - ") + _("Comparing content..."), fraction);
+ showProgressExternally(fractionToShortString(fraction) + wxT(" - ") + _("Comparing content..."), fraction);
break;
}
@@ -393,13 +392,15 @@ public:
m_bpButtonErrors ->setActive(true);
m_bpButtonWarnings->setActive(true);
- m_bpButtonInfo ->setActive(false);
+ m_bpButtonInfo ->setActive(errorCount + warningCount == 0);
m_bpButtonErrors ->Show(errorCount != 0);
m_bpButtonWarnings->Show(warningCount != 0);
m_bpButtonInfo ->Show(infoCount != 0);
updateLogText();
+
+ m_textCtrlInfo->Connect(wxEVT_KEY_DOWN, wxKeyEventHandler(LogControl::onKeyEvent), NULL, this);
}
virtual void OnErrors(wxCommandEvent& event)
@@ -421,6 +422,20 @@ public:
}
private:
+ void onKeyEvent(wxKeyEvent& event)
+ {
+ const int keyCode = event.GetKeyCode();
+
+ if (event.ControlDown())
+ switch (keyCode)
+ {
+ case 'A': //CTRL + A
+ m_textCtrlInfo->SetSelection(-1, -1); //select all
+ return;
+ }
+ event.Skip();
+ }
+
void updateLogText()
{
int includedTypes = 0;
@@ -509,9 +524,12 @@ struct LabelFormatterBytes : public LabelFormatter
{
virtual double getOptimalBlockSize(double bytesProposed) const
{
+ bytesProposed *= 2; //make blocks twice the default size
+
+ if (bytesProposed <= 1024 * 1024) //set 1 MB min size: reduce initial rapid changes in y-label
+ return 1024 * 1024;
+
//round to next number which is a convenient to read block size
- if (bytesProposed <= 0)
- return 0;
const double k = std::floor(std::log(bytesProposed) / std::log(2.0));
const double e = std::pow(2.0, k);
@@ -530,8 +548,11 @@ struct LabelFormatterTimeElapsed : public LabelFormatter
{
virtual double getOptimalBlockSize(double secProposed) const
{
- if (secProposed <= 5)
- return 5; //minimum block size
+ if (secProposed <= 10)
+ return 10; //minimum block size
+
+ if (secProposed <= 20) //avoid flicker between 10<->15<->20 sec blocks
+ return bestFit(secProposed, 10, 20);
//for seconds and minutes: nice numbers are 1, 5, 10, 15, 20, 30
auto calcBlock = [](double val) -> double
@@ -803,10 +824,7 @@ SyncStatus::SyncStatusImpl::~SyncStatusImpl()
if (mainDialog)
{
mainDialog->enableAllElements();
-
- //restore title text
- mainDialog->SetTitle(titelTextBackup);
-
+ mainDialog->SetTitle(titelTextBackup); //restore title text
mainDialog->Raise();
mainDialog->SetFocus();
}
@@ -977,13 +995,13 @@ void SyncStatus::SyncStatusImpl::updateStatusDialogNow(bool allowYield)
showProgressExternally(wxString() + toStringSep(scannedObjects) + wxT(" - ") + _("Scanning...") + postFix);
break;
case SyncStatus::COMPARING_CONTENT:
- showProgressExternally(wxString() + percentageToShortString(fraction) + wxT(" - ") + _("Comparing content...") + postFix, fraction);
+ showProgressExternally(wxString() + fractionToShortString(fraction) + wxT(" - ") + _("Comparing content...") + postFix, fraction);
break;
case SyncStatus::SYNCHRONIZING:
- showProgressExternally(wxString() + percentageToShortString(fraction) + wxT(" - ") + _("Synchronizing...") + postFix, fraction);
+ showProgressExternally(wxString() + fractionToShortString(fraction) + wxT(" - ") + _("Synchronizing...") + postFix, fraction);
break;
case SyncStatus::PAUSE:
- showProgressExternally(wxString() + percentageToShortString(fraction) + wxT(" - ") + _("Paused") + postFix, fraction);
+ showProgressExternally(wxString() + fractionToShortString(fraction) + wxT(" - ") + _("Paused") + postFix, fraction);
break;
case SyncStatus::ABORTED:
showProgressExternally(_("Aborted") + postFix, fraction);
@@ -1219,10 +1237,17 @@ void SyncStatus::SyncStatusImpl::processHasFinished(SyncStatus::SyncStatusID id,
m_staticTextSpeed->SetLabel(timeElapMs <= 0 ? L"-" : zen::filesizeToShortString(zen::to<UInt64>(currentData * 1000 / timeElapMs)) + _("/sec"));
//fill result listbox:
+
+ //workaround wxListBox bug on Windows XP: labels are drawn on top of each other
+ assert(m_listbookResult->GetImageList()); //make sure listbook keeps *any* image list
+ //due to some crazy reasons that aren't worth debugging, this needs to be done directly in wxFormBuilder,
+ //the following call is *not* sufficient: m_listbookResult->AssignImageList(new wxImageList(0, 0));
+ //note: alternative solutions involving wxLC_LIST, wxLC_REPORT and SetWindowStyleFlag() do not work portably! wxListBook using wxLC_ICON is obviously a class invariant!
+
//1. re-arrange graph into results listbook
bSizerTop->Detach(m_panelProgress);
m_panelProgress->Reparent(m_listbookResult);
- m_listbookResult->AddPage(m_panelProgress, _("Statistics"), true);
+ m_listbookResult->AddPage(m_panelProgress, _("Statistics"), true); //AddPage() takes ownership!
//2. log file
LogControl* logControl = new LogControl(m_listbookResult, log);
diff --git a/ui/small_dlgs.cpp b/ui/small_dlgs.cpp
index 779bc427..cf323279 100644
--- a/ui/small_dlgs.cpp
+++ b/ui/small_dlgs.cpp
@@ -607,13 +607,13 @@ SyncPreviewDlg::SyncPreviewDlg(wxWindow* parent,
m_staticTextVariant->SetLabel(variantName);
m_textCtrlData->SetValue(zen::filesizeToShortString(statistics.getDataToProcess()));
- m_textCtrlCreateL->SetValue(toStringSep(statistics.getCreate <LEFT_SIDE>()));
- m_textCtrlUpdateL->SetValue(toStringSep(statistics.getOverwrite<LEFT_SIDE>()));
- m_textCtrlDeleteL->SetValue(toStringSep(statistics.getDelete <LEFT_SIDE>()));
+ m_textCtrlCreateL->SetValue(toStringSep(statistics.getCreate<LEFT_SIDE>()));
+ m_textCtrlUpdateL->SetValue(toStringSep(statistics.getUpdate<LEFT_SIDE>()));
+ m_textCtrlDeleteL->SetValue(toStringSep(statistics.getDelete<LEFT_SIDE>()));
- m_textCtrlCreateR->SetValue(toStringSep(statistics.getCreate <RIGHT_SIDE>()));
- m_textCtrlUpdateR->SetValue(toStringSep(statistics.getOverwrite<RIGHT_SIDE>()));
- m_textCtrlDeleteR->SetValue(toStringSep(statistics.getDelete <RIGHT_SIDE>()));
+ m_textCtrlCreateR->SetValue(toStringSep(statistics.getCreate<RIGHT_SIDE>()));
+ m_textCtrlUpdateR->SetValue(toStringSep(statistics.getUpdate<RIGHT_SIDE>()));
+ m_textCtrlDeleteR->SetValue(toStringSep(statistics.getDelete<RIGHT_SIDE>()));
m_checkBoxDontShowAgain->SetValue(dontShowAgain);
@@ -694,7 +694,7 @@ CompareCfgDialog::CompareCfgDialog(wxWindow* parent,
#endif
enumDescrHandleSyml.
- add(SYMLINK_IGNORE, _("Ignore")).
+ add(SYMLINK_IGNORE, _("Exclude")).
add(SYMLINK_USE_DIRECTLY, _("Direct")).
add(SYMLINK_FOLLOW_LINK, _("Follow"));
@@ -818,7 +818,7 @@ GlobalSettingsDlg::GlobalSettingsDlg(wxWindow* parent, xmlAccess::XmlGlobalSetti
m_checkBoxCopyPermissions->SetLabel(_("Copy NTFS permissions"));
#else
m_checkBoxCopyLocked->Hide();
- m_textCtrlCopyLocked->Hide();
+ m_staticTextCopyLocked->Hide();
#endif
set(globalSettings.gui.externelApplications);
diff --git a/ui/sync_cfg.cpp b/ui/sync_cfg.cpp
index d19520be..26ea5b2e 100644
--- a/ui/sync_cfg.cpp
+++ b/ui/sync_cfg.cpp
@@ -5,6 +5,7 @@
// **************************************************************************
#include "sync_cfg.h"
+#include <memory>
#include "../lib/resources.h"
#include "../lib/dir_name.h"
#include <wx/wupdlock.h>
@@ -12,10 +13,10 @@
#include <wx+/string_conv.h>
#include <wx+/dir_picker.h>
#include "gui_generated.h"
-#include <memory>
#include <wx+/choice_enum.h>
#include "../lib/dir_name.h"
#include <wx+/image_tools.h>
+#include "../file_hierarchy.h"
using namespace zen;
using namespace xmlAccess;
@@ -97,15 +98,15 @@ void updateConfigIcons(const DirectionConfig& directionCfg,
{
case SYNC_DIR_RIGHT:
buttonLeftOnly->SetBitmapLabel(GlobalResources::getImage(wxT("createRight")));
- buttonLeftOnly->SetToolTip(getDescription(SO_CREATE_NEW_RIGHT));
+ buttonLeftOnly->SetToolTip(getSyncOpDescription(SO_CREATE_NEW_RIGHT));
break;
case SYNC_DIR_LEFT:
buttonLeftOnly->SetBitmapLabel(GlobalResources::getImage(wxT("deleteLeft")));
- buttonLeftOnly->SetToolTip(getDescription(SO_DELETE_LEFT));
+ buttonLeftOnly->SetToolTip(getSyncOpDescription(SO_DELETE_LEFT));
break;
case SYNC_DIR_NONE:
buttonLeftOnly->SetBitmapLabel(GlobalResources::getImage(wxT("none")));
- buttonLeftOnly->SetToolTip(getDescription(SO_DO_NOTHING));
+ buttonLeftOnly->SetToolTip(getSyncOpDescription(SO_DO_NOTHING));
break;
}
@@ -113,15 +114,15 @@ void updateConfigIcons(const DirectionConfig& directionCfg,
{
case SYNC_DIR_RIGHT:
buttonRightOnly->SetBitmapLabel(GlobalResources::getImage(wxT("deleteRight")));
- buttonRightOnly->SetToolTip(getDescription(SO_DELETE_RIGHT));
+ buttonRightOnly->SetToolTip(getSyncOpDescription(SO_DELETE_RIGHT));
break;
case SYNC_DIR_LEFT:
buttonRightOnly->SetBitmapLabel(GlobalResources::getImage(wxT("createLeft")));
- buttonRightOnly->SetToolTip(getDescription(SO_CREATE_NEW_LEFT));
+ buttonRightOnly->SetToolTip(getSyncOpDescription(SO_CREATE_NEW_LEFT));
break;
case SYNC_DIR_NONE:
buttonRightOnly->SetBitmapLabel(GlobalResources::getImage(wxT("none")));
- buttonRightOnly->SetToolTip(getDescription(SO_DO_NOTHING));
+ buttonRightOnly->SetToolTip(getSyncOpDescription(SO_DO_NOTHING));
break;
}
@@ -129,15 +130,15 @@ void updateConfigIcons(const DirectionConfig& directionCfg,
{
case SYNC_DIR_RIGHT:
buttonLeftNewer->SetBitmapLabel(GlobalResources::getImage(wxT("updateRight")));
- buttonLeftNewer->SetToolTip(getDescription(SO_OVERWRITE_RIGHT));
+ buttonLeftNewer->SetToolTip(getSyncOpDescription(SO_OVERWRITE_RIGHT));
break;
case SYNC_DIR_LEFT:
buttonLeftNewer->SetBitmapLabel(GlobalResources::getImage(wxT("updateLeft")));
- buttonLeftNewer->SetToolTip(getDescription(SO_OVERWRITE_LEFT));
+ buttonLeftNewer->SetToolTip(getSyncOpDescription(SO_OVERWRITE_LEFT));
break;
case SYNC_DIR_NONE:
buttonLeftNewer->SetBitmapLabel(GlobalResources::getImage(wxT("none")));
- buttonLeftNewer->SetToolTip(getDescription(SO_DO_NOTHING));
+ buttonLeftNewer->SetToolTip(getSyncOpDescription(SO_DO_NOTHING));
break;
}
@@ -145,15 +146,15 @@ void updateConfigIcons(const DirectionConfig& directionCfg,
{
case SYNC_DIR_RIGHT:
buttonRightNewer->SetBitmapLabel(GlobalResources::getImage(wxT("updateRight")));
- buttonRightNewer->SetToolTip(getDescription(SO_OVERWRITE_RIGHT));
+ buttonRightNewer->SetToolTip(getSyncOpDescription(SO_OVERWRITE_RIGHT));
break;
case SYNC_DIR_LEFT:
buttonRightNewer->SetBitmapLabel(GlobalResources::getImage(wxT("updateLeft")));
- buttonRightNewer->SetToolTip(getDescription(SO_OVERWRITE_LEFT));
+ buttonRightNewer->SetToolTip(getSyncOpDescription(SO_OVERWRITE_LEFT));
break;
case SYNC_DIR_NONE:
buttonRightNewer->SetBitmapLabel(GlobalResources::getImage(wxT("none")));
- buttonRightNewer->SetToolTip(getDescription(SO_DO_NOTHING));
+ buttonRightNewer->SetToolTip(getSyncOpDescription(SO_DO_NOTHING));
break;
}
@@ -161,15 +162,15 @@ void updateConfigIcons(const DirectionConfig& directionCfg,
{
case SYNC_DIR_RIGHT:
buttonDifferent->SetBitmapLabel(GlobalResources::getImage(wxT("updateRight")));
- buttonDifferent->SetToolTip(getDescription(SO_OVERWRITE_RIGHT));
+ buttonDifferent->SetToolTip(getSyncOpDescription(SO_OVERWRITE_RIGHT));
break;
case SYNC_DIR_LEFT:
buttonDifferent->SetBitmapLabel(GlobalResources::getImage(wxT("updateLeft")));
- buttonDifferent->SetToolTip(getDescription(SO_OVERWRITE_LEFT));
+ buttonDifferent->SetToolTip(getSyncOpDescription(SO_OVERWRITE_LEFT));
break;
case SYNC_DIR_NONE:
buttonDifferent->SetBitmapLabel(GlobalResources::getImage(wxT("none")));
- buttonDifferent->SetToolTip(getDescription(SO_DO_NOTHING));
+ buttonDifferent->SetToolTip(getSyncOpDescription(SO_DO_NOTHING));
break;
}
@@ -177,11 +178,11 @@ void updateConfigIcons(const DirectionConfig& directionCfg,
{
case SYNC_DIR_RIGHT:
buttonConflict->SetBitmapLabel(GlobalResources::getImage(wxT("updateRight")));
- buttonConflict->SetToolTip(getDescription(SO_OVERWRITE_RIGHT));
+ buttonConflict->SetToolTip(getSyncOpDescription(SO_OVERWRITE_RIGHT));
break;
case SYNC_DIR_LEFT:
buttonConflict->SetBitmapLabel(GlobalResources::getImage(wxT("updateLeft")));
- buttonConflict->SetToolTip(getDescription(SO_OVERWRITE_LEFT));
+ buttonConflict->SetToolTip(getSyncOpDescription(SO_OVERWRITE_LEFT));
break;
case SYNC_DIR_NONE:
buttonConflict->SetBitmapLabel(GlobalResources::getImage(wxT("conflict")));
@@ -219,7 +220,7 @@ SyncCfgDialog::SyncCfgDialog(wxWindow* window,
//a proper set-method may be in order some time...
setEnumVal(enumDelhandDescr, *m_choiceHandleDeletion, syncCfg.handleDeletion);
- customDelFolder.setName(syncCfg.customDeletionDirectory);
+ customDelFolder.setName(toWx(syncCfg.customDeletionDirectory));
updateGui();
//error handling
@@ -330,7 +331,7 @@ void SyncCfgDialog::OnApply(wxCommandEvent& event)
//write configuration to main dialog
syncCfgOut.directionCfg = currentDirectionCfg;
syncCfgOut.handleDeletion = getEnumVal(enumDelhandDescr, *m_choiceHandleDeletion);
- syncCfgOut.customDeletionDirectory = customDelFolder.getName();
+ syncCfgOut.customDeletionDirectory = toZ(customDelFolder.getName());
if (refHandleError)
*refHandleError = getEnumVal(enumErrhandDescr, *m_choiceHandleError);
diff --git a/ui/wx_form_build_hide_warnings.h b/ui/wx_form_build_hide_warnings.h
index 277fa0e7..5988aa12 100644
--- a/ui/wx_form_build_hide_warnings.h
+++ b/ui/wx_form_build_hide_warnings.h
@@ -7,10 +7,14 @@
#ifndef WX_FORM_BUILD_230948324234234
#define WX_FORM_BUILD_230948324234234
-//hide compiler warnings in generated code
+//pamper over wxFormBuilder "sub-optimal" code
#ifdef __GNUC__
#pragma GCC diagnostic ignored "-Wunused-but-set-variable"
+#pragma GCC diagnostic ignored "-Wunused-variable"
+
+#elif defined _MSC_VER
+#pragma warning(disable: 4189)
#endif
#endif //WX_FORM_BUILD_230948324234234
bgstack15