confutatis Posted September 16, 2005 Posted September 16, 2005 (edited) Hello to all, Now that I was able to resolve my problem of minimizing my AutoIT menu to the tray, a smaller problem has popped up. I've included a piece of the code here: Select case $opt[0]="" ContinueLoop case $opt[0]=$GUI_EVENT_CLOSE exitloop case $opt[0]=$GUI_EVENT_MINIMIZE GUISetState(@SW_HIDE) Opt("TrayIconHide",0) while 1 $trayMsg=TrayGetMsg() If $trayMsg = $tlist_2 Then exitloop 2 EndIf If $trayMsg = $tlist_1 Then GuiSetState(@SW_SHOW) Opt("TrayIconHide", 1) exitloop EndIf WEnd The var $tlist_1 is a tray menu item which restores the window. The item selection pops up when the user right-clicks on the tray icon. But when the item is selected, instead of maximizing the window, the window minimizes to the standard task bar. Curiously, I set the default to this item (traySetItemState) and with a double-click to the tray icon, the window does maximize properly. I've tried changing the GuiSetState to basically every @SW_ macro to no avail. What am I missing here? Thanks for the help in advance, David Edited September 16, 2005 by confutatis
Developers Jos Posted September 16, 2005 Developers Posted September 16, 2005 Hello to all,What am I missing here? What about using these both: GUISetState(@SW_SHOW) GUISetState(@SW_RESTORE) SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
confutatis Posted September 16, 2005 Author Posted September 16, 2005 What about using these both: GUISetState(@SW_SHOW) GUISetState(@SW_RESTORE)That did it...Thanks for the help!David
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now