WinInterface.h 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492
  1. //---------------------------------------------------------------------------
  2. #ifndef WinInterfaceH
  3. #define WinInterfaceH
  4. //---------------------------------------------------------------------------
  5. #include <Classes.hpp>
  6. #include <Buttons.hpp>
  7. #include <Interface.h>
  8. #include <GUIConfiguration.h>
  9. #include <SynchronizeController.h>
  10. #ifdef LOCALINTERFACE
  11. #include <LocalInterface.h>
  12. #endif
  13. #define SITE_ICON 1
  14. #define SITE_FOLDER_ICON 2
  15. #define WORKSPACE_ICON 3
  16. class TStoredSessionList;
  17. class TConfiguration;
  18. class TTerminal;
  19. const int mpNeverAskAgainCheck = 0x01;
  20. const int mpAllowContinueOnError = 0x02;
  21. #define UPLOAD_IF_ANY_SWITCH L"UploadIfAny"
  22. #define UPLOAD_SWITCH L"Upload"
  23. #define JUMPLIST_SWITCH L"JumpList"
  24. #define DESKTOP_SWITCH L"Desktop"
  25. #define SEND_TO_HOOK_SWITCH L"SendToHook"
  26. struct TMessageParams
  27. {
  28. TMessageParams(unsigned int AParams = 0);
  29. TMessageParams(const TQueryParams * AParams);
  30. const TQueryButtonAlias * Aliases;
  31. unsigned int AliasesCount;
  32. unsigned int Params;
  33. unsigned int Timer;
  34. TQueryParamsTimerEvent TimerEvent;
  35. UnicodeString TimerMessage;
  36. unsigned int TimerAnswers;
  37. TQueryType TimerQueryType;
  38. unsigned int Timeout;
  39. unsigned int TimeoutAnswer;
  40. UnicodeString NeverAskAgainTitle;
  41. unsigned int NeverAskAgainAnswer;
  42. bool NeverAskAgainCheckedInitially;
  43. bool AllowHelp;
  44. UnicodeString ImageName;
  45. private:
  46. inline void Reset();
  47. };
  48. class TCustomScpExplorerForm;
  49. TCustomScpExplorerForm * __fastcall CreateScpExplorer();
  50. void __fastcall ConfigureInterface();
  51. void __fastcall DoProductLicense();
  52. extern const UnicodeString AppName;
  53. void __fastcall SetOnForeground(bool OnForeground);
  54. void __fastcall FlashOnBackground();
  55. void __fastcall ShowExtendedExceptionEx(TTerminal * Terminal, Exception * E);
  56. void __fastcall FormHelp(TForm * Form);
  57. void __fastcall SearchHelp(const UnicodeString & Message);
  58. void __fastcall MessageWithNoHelp(const UnicodeString & Message);
  59. UnicodeString __fastcall GetToolbarsLayoutStr(const TComponent * OwnerComponent);
  60. void __fastcall LoadToolbarsLayoutStr(TComponent * OwnerComponent, UnicodeString LayoutStr);
  61. namespace Tb2item { class TTBCustomItem; }
  62. void __fastcall AddMenuSeparator(Tb2item::TTBCustomItem * Menu);
  63. void __fastcall AddMenuLabel(Tb2item::TTBCustomItem * Menu, const UnicodeString & Label);
  64. // windows\WinHelp.cpp
  65. void __fastcall InitializeWinHelp();
  66. void __fastcall FinalizeWinHelp();
  67. // windows\WinInterface.cpp
  68. unsigned int __fastcall MessageDialog(const UnicodeString Msg, TQueryType Type,
  69. unsigned int Answers, UnicodeString HelpKeyword = HELP_NONE, const TMessageParams * Params = NULL);
  70. unsigned int __fastcall MessageDialog(int Ident, TQueryType Type,
  71. unsigned int Answers, UnicodeString HelpKeyword = HELP_NONE, const TMessageParams * Params = NULL);
  72. unsigned int __fastcall SimpleErrorDialog(const UnicodeString Msg, const UnicodeString MoreMessages = L"");
  73. unsigned int __fastcall MoreMessageDialog(const UnicodeString Message,
  74. TStrings * MoreMessages, TQueryType Type, unsigned int Answers,
  75. UnicodeString HelpKeyword, const TMessageParams * Params = NULL);
  76. unsigned int __fastcall ExceptionMessageDialog(Exception * E, TQueryType Type,
  77. const UnicodeString MessageFormat = L"", unsigned int Answers = qaOK,
  78. UnicodeString HelpKeyword = HELP_NONE, const TMessageParams * Params = NULL);
  79. unsigned int __fastcall FatalExceptionMessageDialog(Exception * E, TQueryType Type,
  80. int SessionReopenTimeout, const UnicodeString MessageFormat = L"", unsigned int Answers = qaOK,
  81. UnicodeString HelpKeyword = HELP_NONE, const TMessageParams * Params = NULL);
  82. // forms\Custom.cpp
  83. TSessionData * __fastcall DoSaveSession(TSessionData * SessionData,
  84. TSessionData * OriginalSession, bool ForceDialog,
  85. TStrings * AdditionalFolders);
  86. void __fastcall SessionNameValidate(const UnicodeString & Text,
  87. const UnicodeString & OriginalName);
  88. bool __fastcall DoSaveWorkspaceDialog(UnicodeString & WorkspaceName,
  89. bool * SavePasswords, bool NotRecommendedSavingPasswords,
  90. bool & CreateShortcut, bool & EnableAutoSave);
  91. class TShortCuts;
  92. bool __fastcall DoShortCutDialog(TShortCut & ShortCut,
  93. const TShortCuts & ShortCuts, UnicodeString HelpKeyword);
  94. // windows\UserInterface.cpp
  95. bool __fastcall DoMasterPasswordDialog();
  96. bool __fastcall DoChangeMasterPasswordDialog(UnicodeString & NewPassword);
  97. // windows\WinMain.cpp
  98. int __fastcall Execute();
  99. void __fastcall GetLoginData(UnicodeString SessionName, TOptions * Options,
  100. TObjectList * DataList, UnicodeString & DownloadFile, bool & Url);
  101. // forms\InputDlg.cpp
  102. struct TInputDialogData
  103. {
  104. TEdit * Edit;
  105. };
  106. typedef void __fastcall (__closure *TInputDialogInitialize)
  107. (TObject * Sender, TInputDialogData * Data);
  108. bool __fastcall InputDialog(const UnicodeString ACaption,
  109. const UnicodeString APrompt, UnicodeString & Value, UnicodeString HelpKeyword = HELP_NONE,
  110. TStrings * History = NULL, bool PathInput = false,
  111. TInputDialogInitialize OnInitialize = NULL);
  112. // forms\About.cpp
  113. struct TRegistration
  114. {
  115. bool Registered;
  116. UnicodeString Subject;
  117. int Licenses;
  118. UnicodeString ProductId;
  119. bool NeverExpires;
  120. TDateTime Expiration;
  121. bool EduLicense;
  122. TNotifyEvent OnRegistrationLink;
  123. };
  124. void __fastcall DoAboutDialog(TConfiguration * Configuration,
  125. bool AllowLicense, TRegistration * Registration);
  126. void __fastcall DoAboutDialog(TConfiguration *Configuration);
  127. // forms\Cleanup.cpp
  128. bool __fastcall DoCleanupDialog(TStoredSessionList *SessionList,
  129. TConfiguration *Configuration);
  130. // forms\Console.cpp
  131. void __fastcall DoConsoleDialog(TTerminal * Terminal,
  132. const UnicodeString Command = L"", const TStrings * Log = NULL);
  133. // forms\Copy.cpp
  134. const coTemp = 0x001;
  135. const coDisableQueue = 0x002;
  136. const coDisableDirectory = 0x008; // not used anymore
  137. const coDoNotShowAgain = 0x020;
  138. const coDisableSaveSettings = 0x040; // not used anymore
  139. const coDoNotUsePresets = 0x080;
  140. const coAllowRemoteTransfer = 0x100;
  141. const coNoQueue = 0x200;
  142. const coNoQueueIndividually = 0x400;
  143. const cooDoNotShowAgain = 0x01;
  144. const cooRemoteTransfer = 0x02;
  145. const cooSaveSettings = 0x04;
  146. bool __fastcall DoCopyDialog(bool ToRemote,
  147. bool Move, TStrings * FileList, UnicodeString & TargetDirectory,
  148. TGUICopyParamType * Params, int Options, int CopyParamAttrs,
  149. int * OutputOptions);
  150. // forms\CreateDirectory.cpp
  151. bool __fastcall DoCreateDirectoryDialog(UnicodeString & Directory,
  152. TRemoteProperties * Properties, bool & SaveSettings);
  153. // forms\ImportSessions.cpp
  154. bool __fastcall DoImportSessionsDialog();
  155. // forms\License.cpp
  156. enum TLicense { lcNoLicense = -1, lcWinScp, lcExpat, lcZlib };
  157. void __fastcall DoLicenseDialog(TLicense License);
  158. // forms\Login.cpp
  159. // these flags are used in navigation tree of login dialog, change with care
  160. const loLocalDirectory = 0x01;
  161. const loExternalTools = 0x04;
  162. const loColor = 0x80;
  163. const loNone = 0x00;
  164. const loAddSession = (loLocalDirectory | loColor);
  165. const loStartup = (loLocalDirectory | loExternalTools | loColor);
  166. bool __fastcall DoLoginDialog(TStoredSessionList * SessionList,
  167. TList * DataList, int Options);
  168. // forms\SiteAdvanced.cpp
  169. bool __fastcall DoSiteAdvancedDialog(TSessionData * SessionData, int Options);
  170. // forms\OpenDirectory.cpp
  171. enum TOpenDirectoryMode { odBrowse, odAddBookmark };
  172. bool __fastcall DoOpenDirectoryDialog(TOpenDirectoryMode Mode, TOperationSide Side,
  173. UnicodeString & Directory, TStrings * Directories, TTerminal * Terminal,
  174. bool AllowSwitch);
  175. // forms\LocatinoProfiles.cpp
  176. bool __fastcall LocationProfilesDialog(TOpenDirectoryMode Mode,
  177. TOperationSide Side, UnicodeString & LocalDirectory, UnicodeString & RemoteDirectory,
  178. TStrings * LocalDirectories, TStrings * RemoteDirectories, TTerminal * Terminal);
  179. // forms\Preferences.cpp
  180. enum TPreferencesMode { pmDefault, pmEditor, pmCustomCommands,
  181. pmQueue, pmLogging, pmUpdates, pmPresets, pmEditors };
  182. class TCopyParamRuleData;
  183. struct TPreferencesDialogData
  184. {
  185. TCopyParamRuleData * CopyParamRuleData;
  186. };
  187. bool __fastcall DoPreferencesDialog(TPreferencesMode APreferencesMode,
  188. TPreferencesDialogData * DialogData = NULL);
  189. // forms\CustomCommand.cpp
  190. class TCustomCommandList;
  191. class TCustomCommandType;
  192. class TShortCuts;
  193. enum TCustomCommandsMode { ccmAdd, ccmEdit, ccmAdHoc };
  194. const ccoDisableRemote = 0x01;
  195. typedef void __fastcall (__closure *TCustomCommandValidate)
  196. (const TCustomCommandType & Command);
  197. bool __fastcall DoCustomCommandDialog(TCustomCommandType & Command,
  198. const TCustomCommandList * CustomCommandList,
  199. TCustomCommandsMode Mode, int Options, TCustomCommandValidate OnValidate,
  200. const TShortCuts * ShortCuts);
  201. // forms\CopyParamPreset.cpp
  202. class TCopyParamList;
  203. enum TCopyParamPresetMode { cpmAdd, cpmEdit, cpmDuplicate };
  204. bool __fastcall DoCopyParamPresetDialog(TCopyParamList * CopyParamList,
  205. int & Index, TCopyParamPresetMode Mode, TCopyParamRuleData * CurrentRuleData,
  206. const TCopyParamType & DefaultCopyParams);
  207. // forms\CopyParamCsutom.cpp
  208. bool __fastcall DoCopyParamCustomDialog(TCopyParamType & CopyParam,
  209. int CopyParamAttrs);
  210. // forms\Properties.cpp
  211. class TRemoteProperties;
  212. class TRemoteTokenList;
  213. struct TCalculateSizeStats;
  214. const cpMode = 0x01;
  215. const cpOwner = 0x02;
  216. const cpGroup = 0x04;
  217. typedef void __fastcall (__closure *TCalculateSizeEvent)
  218. (TStrings * FileList, __int64 & Size, TCalculateSizeStats & Stats,
  219. bool & Close);
  220. typedef void __fastcall (__closure *TCalculatedChecksumCallbackEvent)(
  221. const UnicodeString & FileName, const UnicodeString & Alg, const UnicodeString & Hash);
  222. typedef void __fastcall (__closure *TCalculateChecksumEvent)
  223. (const UnicodeString & Alg, TStrings * FileList,
  224. TCalculatedChecksumCallbackEvent OnCalculatedChecksum, bool & Close);
  225. bool __fastcall DoPropertiesDialog(TStrings * FileList,
  226. const UnicodeString Directory, const TRemoteTokenList * GroupList,
  227. const TRemoteTokenList * UserList, TRemoteProperties * Properties,
  228. int AllowedChanges, bool UserGroupByID, TCalculateSizeEvent OnCalculateSize,
  229. TCalculateChecksumEvent OnCalculateChecksum);
  230. bool __fastcall DoRemoteMoveDialog(UnicodeString & Target, UnicodeString & FileMask);
  231. enum TDirectRemoteCopy { drcDisallow, drcAllow, drcConfirmCommandSession };
  232. bool __fastcall DoRemoteCopyDialog(TStrings * Sessions, TStrings * Directories,
  233. TDirectRemoteCopy AllowDirectCopy, void *& Session, UnicodeString & Target, UnicodeString & FileMask,
  234. bool & DirectCopy);
  235. // forms\SelectMask.cpp
  236. #ifdef CustomdirviewHPP
  237. bool __fastcall DoSelectMaskDialog(TCustomDirView * Parent, bool Select,
  238. TFileFilter * Filter, TConfiguration * Configuration);
  239. bool __fastcall DoFilterMaskDialog(TCustomDirView * Parent,
  240. TFileFilter * Filter);
  241. #endif
  242. // forms\EditMask.cpp
  243. bool __fastcall DoEditMaskDialog(TFileMasks & Mask);
  244. const spDelete = 0x01;
  245. const spNoConfirmation = 0x02;
  246. const spExistingOnly = 0x04;
  247. const spPreviewChanges = 0x40; // not used by core
  248. const spTimestamp = 0x100;
  249. const spNotByTime = 0x200;
  250. const spBySize = 0x400;
  251. const spSelectedOnly = 0x800;
  252. const spMirror = 0x1000;
  253. // forms\Synchronize.cpp
  254. const soDoNotUsePresets = 0x01;
  255. const soNoMinimize = 0x02;
  256. const soAllowSelectedOnly = 0x04;
  257. typedef void __fastcall (__closure *TGetSynchronizeOptionsEvent)
  258. (int Params, TSynchronizeOptions & Options);
  259. bool __fastcall DoSynchronizeDialog(TSynchronizeParamType & Params,
  260. const TCopyParamType * CopyParams, TSynchronizeStartStopEvent OnStartStop,
  261. bool & SaveSettings, int Options, int CopyParamAttrs,
  262. TGetSynchronizeOptionsEvent OnGetOptions, bool Start);
  263. // forms\FullSynchronize.cpp
  264. struct TUsableCopyParamAttrs;
  265. enum TSynchronizeMode { smRemote, smLocal, smBoth };
  266. const fsoDisableTimestamp = 0x01;
  267. const fsoDoNotUsePresets = 0x02;
  268. const fsoAllowSelectedOnly = 0x04;
  269. bool __fastcall DoFullSynchronizeDialog(TSynchronizeMode & Mode, int & Params,
  270. UnicodeString & LocalDirectory, UnicodeString & RemoteDirectory,
  271. TCopyParamType * CopyParams, bool & SaveSettings, bool & SaveMode,
  272. int Options, const TUsableCopyParamAttrs & CopyParamAttrs);
  273. // forms\SynchronizeChecklist.cpp
  274. class TSynchronizeChecklist;
  275. typedef void __fastcall (__closure *TCustomCommandMenuEvent)
  276. (TObject * Sender, TRect Rect, TStrings * LocalFileList, TStrings * RemoteFileList);
  277. bool __fastcall DoSynchronizeChecklistDialog(TSynchronizeChecklist * Checklist,
  278. TSynchronizeMode Mode, int Params,
  279. const UnicodeString LocalDirectory, const UnicodeString RemoteDirectory,
  280. TCustomCommandMenuEvent OnCustomCommandMenu);
  281. // forms\Editor.cpp
  282. typedef void __fastcall (__closure *TFileClosedEvent)
  283. (TObject * Sender, bool Forced);
  284. TForm * __fastcall ShowEditorForm(const UnicodeString FileName, TCustomForm * ParentForm,
  285. TNotifyEvent OnFileChanged, TNotifyEvent OnFileReload, TFileClosedEvent OnClose,
  286. const UnicodeString Caption = L"");
  287. void __fastcall ReconfigureEditorForm(TForm * Form);
  288. bool __fastcall DoSymlinkDialog(UnicodeString & FileName, UnicodeString & PointTo,
  289. TOperationSide Side, bool & SymbolicLink, bool Edit, bool AllowSymbolic);
  290. // forms\FileSystemInfo.cpp
  291. struct TSpaceAvailable;
  292. struct TFileSystemInfo;
  293. struct TSessionInfo;
  294. typedef void __fastcall (__closure *TGetSpaceAvailable)
  295. (const UnicodeString Path, TSpaceAvailable & ASpaceAvailable, bool & Close);
  296. void __fastcall DoFileSystemInfoDialog(
  297. const TSessionInfo & SessionInfo, const TFileSystemInfo & FileSystemInfo,
  298. UnicodeString SpaceAvailablePath, TGetSpaceAvailable OnGetSpaceAvailable);
  299. // forms\MessageDlg.cpp
  300. void __fastcall AnswerNameAndCaption(
  301. unsigned int Answer, UnicodeString & Name, UnicodeString & Caption);
  302. TForm * __fastcall CreateMoreMessageDialog(const UnicodeString & Msg,
  303. TStrings * MoreMessages, TMsgDlgType DlgType, unsigned int Answers,
  304. const TQueryButtonAlias * Aliases, unsigned int AliasesCount,
  305. unsigned int TimeoutAnswer, TButton ** TimeoutButton,
  306. const UnicodeString & ImageName, const UnicodeString & NeverAskAgainCaption);
  307. // windows\Console.cpp
  308. int __fastcall Console(bool Help);
  309. // forms\EditorPreferences.cpp
  310. enum TEditorPreferencesMode { epmAdd, epmEdit, epmAdHoc };
  311. class TEditorData;
  312. bool __fastcall DoEditorPreferencesDialog(TEditorData * Editor,
  313. bool & Remember, TEditorPreferencesMode Mode, bool MayRemote);
  314. // forms\Find.cpp
  315. typedef void __fastcall (__closure *TFindEvent)
  316. (UnicodeString Directory, const TFileMasks & FileMask,
  317. TFileFoundEvent OnFileFound, TFindingFileEvent OnFindingFile);
  318. bool __fastcall DoFileFindDialog(UnicodeString Directory,
  319. TFindEvent OnFind, UnicodeString & Path);
  320. void __fastcall CopyParamListButton(TButton * Button);
  321. const int cplNone = 0x00;
  322. const int cplCustomize = 0x01;
  323. const int cplCustomizeDefault = 0x02;
  324. const int cplSaveSettings = 0x04;
  325. void __fastcall CopyParamListPopup(TRect R, TPopupMenu * Menu,
  326. const TCopyParamType & Param, UnicodeString Preset, TNotifyEvent OnClick,
  327. int Options, int CopyParamAttrs, bool SaveSettings = false);
  328. bool __fastcall CopyParamListPopupClick(TObject * Sender,
  329. TCopyParamType & Param, UnicodeString & Preset, int CopyParamAttrs,
  330. bool * SaveSettings = NULL);
  331. void __fastcall MenuPopup(TPopupMenu * Menu, TRect Rect, TComponent * PopupComponent);
  332. void __fastcall MenuPopup(TPopupMenu * Menu, TButton * Button);
  333. void __fastcall MenuPopup(TObject * Sender, const TPoint & MousePos, bool & Handled);
  334. void __fastcall MenuButton(TButton * Button);
  335. TRect __fastcall CalculatePopupRect(TButton * Button);
  336. TRect __fastcall CalculatePopupRect(TControl * Control, TPoint MousePos);
  337. typedef void __fastcall (__closure *TColorChangeEvent)
  338. (TColor Color);
  339. TPopupMenu * __fastcall CreateSessionColorPopupMenu(TColor Color,
  340. TColorChangeEvent OnColorChange);
  341. void __fastcall CreateSessionColorMenu(TComponent * AOwner, TColor Color,
  342. TColorChangeEvent OnColorChange);
  343. void __fastcall FixButtonImage(TButton * Button);
  344. void __fastcall CenterButtonImage(TButton * Button);
  345. void __fastcall UncenterButtonImage(TButton * Button);
  346. void __fastcall UpgradeSpeedButton(TSpeedButton * Button);
  347. void __fastcall SetGlobalMinimizeHandler(TCustomForm * Form, TNotifyEvent OnMinimize);
  348. void __fastcall ClearGlobalMinimizeHandler(TNotifyEvent OnMinimize);
  349. void __fastcall CallGlobalMinimizeHandler(TObject * Sender);
  350. bool __fastcall IsApplicationMinimized();
  351. void __fastcall WinInitialize();
  352. void __fastcall ShowNotification(TTerminal * Terminal, const UnicodeString & Str,
  353. TQueryType Type);
  354. void __fastcall InitializeShortCutCombo(TComboBox * ComboBox,
  355. const TShortCuts & ShortCuts);
  356. void __fastcall SetShortCutCombo(TComboBox * ComboBox, TShortCut Value);
  357. TShortCut __fastcall GetShortCutCombo(TComboBox * ComboBox);
  358. bool __fastcall IsCustomShortCut(TShortCut ShortCut);
  359. //---------------------------------------------------------------------------
  360. #define HIDDEN_WINDOW_NAME L"WinSCPHiddenWindow2"
  361. //---------------------------------------------------------------------------
  362. struct TCopyDataMessage
  363. {
  364. enum { CommandCanCommandLine, CommandCommandLine };
  365. static const unsigned int Version1 = 1;
  366. unsigned int Version;
  367. unsigned int Command;
  368. union
  369. {
  370. wchar_t CommandLine[10240];
  371. };
  372. };
  373. //---------------------------------------------------------------------------
  374. class TWinInteractiveCustomCommand : public TInteractiveCustomCommand
  375. {
  376. public:
  377. TWinInteractiveCustomCommand(TCustomCommand * ChildCustomCommand,
  378. const UnicodeString CustomCommandName);
  379. protected:
  380. virtual void __fastcall Prompt(const UnicodeString & Prompt,
  381. UnicodeString & Value);
  382. virtual void __fastcall Execute(const UnicodeString & Command,
  383. UnicodeString & Value);
  384. private:
  385. UnicodeString FCustomCommandName;
  386. };
  387. //---------------------------------------------------------------------------
  388. struct TNotifyIconData5;
  389. //---------------------------------------------------------------------------
  390. class TTrayIcon
  391. {
  392. public:
  393. __fastcall TTrayIcon(unsigned int Id);
  394. __fastcall ~TTrayIcon();
  395. void __fastcall PopupBalloon(UnicodeString Title, const UnicodeString & Str,
  396. TQueryType QueryType, unsigned int Timeout, TNotifyEvent OnBalloonClick,
  397. TObject * BalloonUserData);
  398. void __fastcall CancelBalloon();
  399. __property bool Visible = { read = FVisible, write = SetVisible };
  400. __property TNotifyEvent OnClick = { read = FOnClick, write = FOnClick };
  401. __property UnicodeString Hint = { read = GetHint, write = SetHint };
  402. protected:
  403. void __fastcall Update();
  404. bool __fastcall Notify(unsigned int Message);
  405. private:
  406. bool FVisible;
  407. TNotifyIconData5 * FTrayIcon;
  408. TNotifyEvent FOnClick;
  409. TNotifyEvent FOnBalloonClick;
  410. TObject * FBalloonUserData;
  411. UINT FTaskbarCreatedMsg;
  412. void __fastcall WndProc(TMessage & Message);
  413. void __fastcall SetVisible(bool value);
  414. UnicodeString __fastcall GetHint();
  415. void __fastcall SetHint(UnicodeString value);
  416. void __fastcall BalloonCancelled();
  417. };
  418. //---------------------------------------------------------------------------
  419. #endif // WinInterfaceH