Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Widgets - General questions or Mixed problems » TrayIcon Windows Shutdown solution
TrayIcon Windows Shutdown solution [message #45124] Mon, 07 September 2015 13:35 Go to previous message
Typhoor is currently offline  Typhoor
Messages: 14
Registered: October 2012
Location: Erlangen, Germany
Promising Member
Hi there,

I had problems with TrayIcon programs under Windows during Shutdown when I did not have a TopWindow.

Solution was to add WM_QUERYENDSESSION listerner to TaryIcons derived class WindowProc.

I had two solution either to subclass (a) or add to TrayIcon::WindowProc (b)

LRESULT TrayIconDerived::WindowProc( UINT message, WPARAM wParam, LPARAM lParam ) {
	if ( message == WM_QUERYENDSESSION ) {
		ShutDown();
		return true;
	}
	return TrayIcon::WindowProc(message, wParam, lParam);
}


For both I needed to change repository code:
Could we either
a) have the TrayIcon::WindowProc make "protected" in header for subclassing or
b) add the handler to the TrayIcon::WindowProc itself?

Thanx for a thought!
Ralph
 
Read Message
Read Message
Read Message icon7.gif
Previous Topic: Bugs ColumnList
Next Topic: Parent continues before child is painted
Goto Forum:
  


Current Time: Sun Apr 28 14:34:57 CEST 2024

Total time taken to generate the page: 0.04197 seconds