RemoteTransfer.h 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. //---------------------------------------------------------------------------
  2. #ifndef RemoteTransferH
  3. #define RemoteTransferH
  4. //---------------------------------------------------------------------------
  5. #include <Classes.hpp>
  6. #include <Controls.hpp>
  7. #include <StdCtrls.hpp>
  8. #include <Forms.hpp>
  9. #include "HistoryComboBox.hpp"
  10. #include <Vcl.ExtCtrls.hpp>
  11. //---------------------------------------------------------------------------
  12. class TRemoteTransferDialog : public TForm
  13. {
  14. __published:
  15. TGroupBox *Group;
  16. TLabel *SessionLabel;
  17. TLabel *Label3;
  18. TComboBox *SessionCombo;
  19. THistoryComboBox *DirectoryEdit;
  20. TButton *OkButton;
  21. TButton *CancelButton;
  22. TButton *HelpButton;
  23. TCheckBox *NotDirectCopyCheck;
  24. TImage *Image;
  25. void __fastcall ControlChange(TObject *Sender);
  26. void __fastcall FormShow(TObject *Sender);
  27. void __fastcall HelpButtonClick(TObject *Sender);
  28. void __fastcall SessionComboChange(TObject *Sender);
  29. void __fastcall FormCloseQuery(TObject *Sender, bool &CanClose);
  30. void __fastcall NotDirectCopyCheckClick(TObject *Sender);
  31. public:
  32. __fastcall TRemoteTransferDialog(TComponent * Owner);
  33. void __fastcall Init(
  34. bool Multi, TStrings * Sessions, TStrings * Directories, TDirectRemoteCopy AllowDirectCopy,
  35. void * CurrentSession, TDirectoryExistsEvent OnDirectoryExists, bool TargetConfirmed);
  36. bool __fastcall Execute(void *& Session, UnicodeString & Target,
  37. UnicodeString & FileMask, bool & DirectCopy);
  38. protected:
  39. void __fastcall UpdateControls();
  40. UnicodeString GetTarget();
  41. UnicodeString GetFileMask();
  42. bool __fastcall IsCurrentSessionSelected();
  43. void * GetSelectedSession();
  44. void __fastcall UpdateNotDirectCopyCheck();
  45. private:
  46. TStrings * FDirectories;
  47. void * FCurrentSession;
  48. bool FDirectCopy;
  49. bool FMulti;
  50. TDirectRemoteCopy FAllowDirectCopy;
  51. TDirectoryExistsEvent FOnDirectoryExists;
  52. bool FTargetConfirmed;
  53. UnicodeString FOriginalTarget;
  54. INTERFACE_HOOK
  55. };
  56. //---------------------------------------------------------------------------
  57. #endif