From 75c07011b7c4d06acd7b45dabdcd60ab9d80f385 Mon Sep 17 00:00:00 2001 From: Daniel Wilhelm Date: Fri, 18 Apr 2014 17:29:28 +0200 Subject: 5.23 --- ui/gui_status_handler.h | 86 ------------------------------------------------- 1 file changed, 86 deletions(-) delete mode 100644 ui/gui_status_handler.h (limited to 'ui/gui_status_handler.h') diff --git a/ui/gui_status_handler.h b/ui/gui_status_handler.h deleted file mode 100644 index fbbf827f..00000000 --- a/ui/gui_status_handler.h +++ /dev/null @@ -1,86 +0,0 @@ -// ************************************************************************** -// * This file is part of the FreeFileSync project. It is distributed under * -// * GNU General Public License: http://www.gnu.org/licenses/gpl.html * -// * Copyright (C) Zenju (zenju AT gmx DOT de) - All Rights Reserved * -// ************************************************************************** - -#ifndef GUISTATUSHANDLER_H_INCLUDED -#define GUISTATUSHANDLER_H_INCLUDED - -#include -#include -#include -#include "progress_indicator.h" -#include "../lib/status_handler.h" -#include "../lib/process_xml.h" -#include "main_dlg.h" - - -//Exception class used to abort the "compare" and "sync" process -class GuiAbortProcess {}; - -//classes handling sync and compare error as well as status information - -//CompareStatusHandler(CompareProgressDialog) will internally process Window messages! disable GUI controls to avoid unexpected callbacks! -class CompareStatusHandler : private wxEvtHandler, public zen::StatusHandler //throw GuiAbortProcess -{ -public: - CompareStatusHandler(MainDialog& dlg); - ~CompareStatusHandler(); - - virtual void initNewPhase(int objectsTotal, zen::Int64 dataTotal, Phase phaseID); - virtual void forceUiRefresh(); - - virtual Response reportError(const std::wstring& text, size_t retryNumber); - virtual void reportFatalError(const std::wstring& errorMessage); - virtual void reportWarning(const std::wstring& warningMessage, bool& warningActive); - -private: - void OnKeyPressed(wxKeyEvent& event); - void OnAbortCompare(wxCommandEvent& event); //handle abort button click - virtual void abortThisProcess(); //throw GuiAbortProcess - - MainDialog& mainDlg; - bool ignoreErrors; -}; - - -//SyncStatusHandler(SyncProgressDialog) will internally process Window messages! disable GUI controls to avoid unexpected callbacks! -class SyncStatusHandler : public zen::StatusHandler -{ -public: - SyncStatusHandler(wxFrame* parentDlg, - size_t lastSyncsLogFileSizeMax, - xmlAccess::OnGuiError handleError, - size_t automaticRetryCount, - size_t automaticRetryDelay, - const std::wstring& jobName, - const std::wstring& execWhenFinished, - std::vector& execFinishedHistory); - ~SyncStatusHandler(); - - virtual void initNewPhase (int objectsTotal, zen::Int64 dataTotal, Phase phaseID); - virtual void updateProcessedData(int objectsDelta, zen::Int64 dataDelta); - virtual void reportInfo(const std::wstring& text); - virtual void forceUiRefresh(); - - virtual Response reportError(const std::wstring& text, size_t retryNumber); - virtual void reportFatalError(const std::wstring& errorMessage); - virtual void reportWarning(const std::wstring& warningMessage, bool& warningActive); - -private: - virtual void abortThisProcess(); //throw GuiAbortProcess - void onProgressDialogTerminate(); - - SyncProgressDialog* progressDlg; //managed to have shorter lifetime than this handler! - const size_t lastSyncsLogFileSizeMax_; - xmlAccess::OnGuiError handleError_; - zen::ErrorLog errorLog; - const size_t automaticRetryCount_; - const size_t automaticRetryDelay_; - const std::wstring jobName_; - wxStopWatch totalTime; -}; - - -#endif // GUISTATUSHANDLER_H_INCLUDED -- cgit