![]() |
Baloon-Hint im TrayIcon
Hey,
Also ich versuche gerade mit einem Hint komponenten ein Baloon-Hint auf ein Tray-Icon zu machen bzw. anzeigen zu lassen. Also in etwa so wie da: ![]() Also so ruft man den hint normalerweise auf:
Delphi-Quellcode:
Also self ist so zu sagen das "handle". Ich könnte da jetzt auch Button1 oder so rein machen.
Hint.ShowTextHintBalloon(bmtInfo, 'How is the test?',
'WHOA! Am i looking frightnng for you? :)', 300, 10, 10, self, TALHintBalloonArrowPosition(1)); So nun will ich das aber auf mein TrayIcon klatschen, nur bekomm das nicht hin. Der Hint will ein TControl als handle. Hier zeig ich euch mal wie ich das TrayIcon erstell:
Delphi-Quellcode:
Nun wenn ich aber WM_ICONTRAY oder TrayIconData als TControl-handle beim Hint component benütze geht es natürlich nicht.
...
WM_ICONTRAY = WM_USER + 1; // bei mir global TrayIconData: TNotifyIconData; // auch global procedure TForm1.FormCreate(...) begin with TrayIconData do begin cbSize := SizeOf(TrayIconData); Wnd := Handle; uID := 0; uFlags := NIF_MESSAGE + NIF_ICON + NIF_TIP; uCallbackMessage := WM_ICONTRAY; hIcon := Application.Icon.Handle; StrPCopy(szTip, Application.Title); ShowWindow( Application.Handle, SW_HIDE ); SetWindowLong( Application.Handle, GWL_EXSTYLE, GetWindowLong(Application.Handle, GWL_EXSTYLE) or WS_EX_TOOLWINDOW and not WS_EX_APPWINDOW); ShowWindow( Application.Handle, SW_SHOW ); end; Shell_NotifyIcon(NIM_ADD, @TrayIconData); ... end; Irgend ne idee wie ich das machen könnte? |
Re: Baloon-Hint im TrayIcon
Ich weiß zwar keine Lösung für dein Problem, aber ich kann dir nur die Komponente CoolTrayIcon empfehlen (kostenlos). Damit ist es ganz einfach, Balloontips, Hints etc. darzustellen. Ein
![]() Mfg |
Re: Baloon-Hint im TrayIcon
Zitat:
Wenn ich ein Programm mit TrayIcon erstelle, verwende ich nur CoolTrayIcon. Damit klappt alles zu meiner Zufriedenheit. |
Alle Zeitangaben in WEZ +1. Es ist jetzt 11:15 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz