Copy.h 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. //---------------------------------------------------------------------------
  2. #ifndef CopyH
  3. #define CopyH
  4. //---------------------------------------------------------------------------
  5. #include <Classes.hpp>
  6. #include <Controls.hpp>
  7. #include <StdCtrls.hpp>
  8. #include <Forms.hpp>
  9. #include <Mask.hpp>
  10. #include <MoreButton.hpp>
  11. #include <ExtCtrls.hpp>
  12. #include <HistoryComboBox.hpp>
  13. #include "Rights.h"
  14. #include "CopyParams.h"
  15. //---------------------------------------------------------------------------
  16. class TCopyDialog : public TForm
  17. {
  18. __published:
  19. TLabel *DirectoryLabel;
  20. THistoryComboBox *LocalDirectoryEdit;
  21. THistoryComboBox *RemoteDirectoryEdit;
  22. TMoreButton *MoreButton;
  23. TButton *CopyButton;
  24. TButton *CancelButton;
  25. TPanel *MorePanel;
  26. TCheckBox *SaveSettingsCheck;
  27. TCopyParamsFrame *CopyParamsFrame;
  28. TButton *LocalDirectoryBrowseButton;
  29. void __fastcall FormShow(TObject *Sender);
  30. void __fastcall FormCloseQuery(TObject *Sender, bool &CanClose);
  31. void __fastcall LocalDirectoryBrowseButtonClick(TObject *Sender);
  32. private:
  33. bool FToRemote;
  34. bool FDragDrop;
  35. TStrings * FFileList;
  36. bool FMove;
  37. AnsiString FFileMask;
  38. bool FAllowDirectory;
  39. bool __fastcall GetAllowTransferMode();
  40. AnsiString __fastcall GetDirectory();
  41. void __fastcall SetToRemote(bool value);
  42. THistoryComboBox * __fastcall GetDirectoryEdit();
  43. void __fastcall SetParams(TCopyParamType value);
  44. TCopyParamType __fastcall GetParams();
  45. void __fastcall SetAllowTransferMode(Boolean value);
  46. void __fastcall SetDirectory(AnsiString value);
  47. void __fastcall SetDragDrop(Boolean value);
  48. void __fastcall SetFileList(TStrings * value);
  49. void __fastcall SetMove(bool value);
  50. void __fastcall SetFileMask(const AnsiString value);
  51. AnsiString __fastcall GetFileMask();
  52. void __fastcall SetAllowDirectory(bool value);
  53. public:
  54. bool __fastcall Execute();
  55. __fastcall TCopyDialog(TComponent* Owner);
  56. __property bool AllowTransferMode = { read = GetAllowTransferMode, write = SetAllowTransferMode };
  57. __property bool ToRemote = { read = FToRemote, write = SetToRemote };
  58. __property AnsiString Directory = { read = GetDirectory, write = SetDirectory };
  59. __property THistoryComboBox * DirectoryEdit = { read = GetDirectoryEdit };
  60. __property bool DragDrop = { read = FDragDrop, write = SetDragDrop };
  61. __property TStrings * FileList = { read = FFileList, write = SetFileList };
  62. __property TCopyParamType Params = { read = GetParams, write = SetParams };
  63. __property bool Move = { read = FMove, write = SetMove };
  64. __property bool AllowDirectory = { read = FAllowDirectory, write = SetAllowDirectory };
  65. protected:
  66. void __fastcall UpdateControls();
  67. };
  68. //---------------------------------------------------------------------------
  69. #endif