SynchronizeProgress.h 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. //---------------------------------------------------------------------------
  2. #ifndef SynchronizeProgressH
  3. #define SynchronizeProgressH
  4. //---------------------------------------------------------------------------
  5. #include <Classes.hpp>
  6. #include <Controls.hpp>
  7. #include <StdCtrls.hpp>
  8. #include <Forms.hpp>
  9. #include "PathLabel.hpp"
  10. #include <ExtCtrls.hpp>
  11. //---------------------------------------------------------------------------
  12. class TSynchronizeProgressForm : public TForm
  13. {
  14. __published:
  15. TLabel *Label1;
  16. TLabel *Label2;
  17. TPathLabel *RemoteDirectoryLabel;
  18. TPathLabel *LocalDirectoryLabel;
  19. TLabel *StartTimeLabel;
  20. TLabel *Label4;
  21. TLabel *Label3;
  22. TLabel *TimeElapsedLabel;
  23. TButton *CancelButton;
  24. TTimer *UpdateTimer;
  25. TButton *MinimizeButton;
  26. void __fastcall CancelButtonClick(TObject *Sender);
  27. void __fastcall UpdateTimerTimer(TObject *Sender);
  28. void __fastcall MinimizeButtonClick(TObject *Sender);
  29. public:
  30. __fastcall TSynchronizeProgressForm(TComponent * Owner, bool AllowMinimize,
  31. bool CompareOnly);
  32. virtual __fastcall ~TSynchronizeProgressForm();
  33. void __fastcall Start();
  34. void __fastcall SetData(const UnicodeString LocalDirectory,
  35. const UnicodeString RemoteDirectory, bool & Continue);
  36. __property bool Started = { read = FStarted };
  37. private:
  38. TDateTime FStartTime;
  39. TDateTime FElapsed;
  40. bool FStarted;
  41. bool FCanceled;
  42. void * FShowAsModalStorage;
  43. bool FMinimizedByMe;
  44. bool FCompareOnly;
  45. void __fastcall UpdateControls();
  46. void __fastcall GlobalMinimize(TObject * Sender);
  47. };
  48. //---------------------------------------------------------------------------
  49. #endif