C2C Posted April 23, 2008 Share Posted April 23, 2008 ----------------------------------90% of teens today would die if Myspace,Bebo + FaceBook had a system failure and was completely destroyed. If you are one of the 10% that would be laughing, copy and paste this to your signature.----------------------------------Code to win, 'till you die, 'till the compiler dies from your linesCode to win, take it all, just keep coding till you fallDay by day, codin' all the way, I'm not cavin' inLet another App begin, code to win Link to comment Share on other sites More sharing options...
Zedna Posted April 24, 2008 Share Posted April 24, 2008 Look here Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
C2C Posted April 24, 2008 Author Share Posted April 24, 2008 Already using the ModernMenu.au3 but i cant seem to find the func that actually does the side image thing or its not even there hmmmm ----------------------------------90% of teens today would die if Myspace,Bebo + FaceBook had a system failure and was completely destroyed. If you are one of the 10% that would be laughing, copy and paste this to your signature.----------------------------------Code to win, 'till you die, 'till the compiler dies from your linesCode to win, take it all, just keep coding till you fallDay by day, codin' all the way, I'm not cavin' inLet another App begin, code to win Link to comment Share on other sites More sharing options...
GEOSoft Posted April 24, 2008 Share Posted April 24, 2008 If you are talking about the sidebar on the menu, I have not seen any functions that would create that. George Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.*** The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number. Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else. "Old age and treachery will always overcome youth and skill!" Link to comment Share on other sites More sharing options...
C2C Posted April 24, 2008 Author Share Posted April 24, 2008 The sidebar sort of im refering to that blue image on the right saying daemon tools pro ----------------------------------90% of teens today would die if Myspace,Bebo + FaceBook had a system failure and was completely destroyed. If you are one of the 10% that would be laughing, copy and paste this to your signature.----------------------------------Code to win, 'till you die, 'till the compiler dies from your linesCode to win, take it all, just keep coding till you fallDay by day, codin' all the way, I'm not cavin' inLet another App begin, code to win Link to comment Share on other sites More sharing options...
Zedna Posted April 24, 2008 Share Posted April 24, 2008 The sidebar sort of im refering to that blue image on the right saying daemon tools proOn the left :-) Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
C2C Posted April 24, 2008 Author Share Posted April 24, 2008 Yeah my other right ----------------------------------90% of teens today would die if Myspace,Bebo + FaceBook had a system failure and was completely destroyed. If you are one of the 10% that would be laughing, copy and paste this to your signature.----------------------------------Code to win, 'till you die, 'till the compiler dies from your linesCode to win, take it all, just keep coding till you fallDay by day, codin' all the way, I'm not cavin' inLet another App begin, code to win Link to comment Share on other sites More sharing options...
C2C Posted April 26, 2008 Author Share Posted April 26, 2008 (edited) BUMPzor Edited April 26, 2008 by C2C ----------------------------------90% of teens today would die if Myspace,Bebo + FaceBook had a system failure and was completely destroyed. If you are one of the 10% that would be laughing, copy and paste this to your signature.----------------------------------Code to win, 'till you die, 'till the compiler dies from your linesCode to win, take it all, just keep coding till you fallDay by day, codin' all the way, I'm not cavin' inLet another App begin, code to win Link to comment Share on other sites More sharing options...
GEOSoft Posted April 26, 2008 Share Posted April 26, 2008 BUMPzorBumping this topic won't help. The question has been asked before and I'm sure it was never resolved. George Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.*** The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number. Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else. "Old age and treachery will always overcome youth and skill!" Link to comment Share on other sites More sharing options...
martin Posted April 26, 2008 Share Posted April 26, 2008 Bumping this topic won't help. The question has been asked before and I'm sure it was never resolved.If you're not looking for perfection then I'm your man! (Or, according to some posts in these forums, I'm your woman!) Here is an approach that might be worth playing with. It has a number of disadvantages as it is shown; it only works on the menu for another script or application; it will add the picture to every tray menu except the one for the script itself unless you can find some way to identify the right one. Also, if you click on the image then the menu will be removed again, but perhaps that is acceptable. If you can find out how to get the handle to the scripts own tray menu, and intercept the popped up state notification, if there is such a thing, then you could apply it to the scripts own tray menu and improve it a lot. expandcollapse popup#include <Constants.au3> $hg = GUICreate("",20,150,0,@DesktopHeight,$WS_POPUP,$WS_EX_TOPMOST) ;$pic = GUICtrlCreatePic(..;put your picture here GUISetBkColor(0,$hg);just so it's clearly seen with no picture GUISetState() GUISetState() Opt("TrayAutoPause", 0); Script will not be paused when clicking the tray icon. $zal = TrayCreateItem("Firewall: OFF") $zalon = False TrayCreateItem("") $zipbk = TrayCreateItem("Backup: pending") $zipisrun = True; TrayCreateItem("") $showlog = TrayCreateItem("view log") $togo = '24H' $SetToGo = '' ConsoleWrite($zal & ', ' & Hex(ControlGetHandle($hG,'',$zal)) & @CRLF) $tmfound = False TraySetState() While 1 Sleep(90) If WinExists("[class:#32768]") And Not $tmfound Then $wp = WinGetPos("[class:#32768]") If $wp[1] + $wp[3] > @DesktopHeight - 20 Then $tmfound = True ConsoleWrite($wp[0] & ', ' & $wp[1] & ', ' & $wp[2] & ', ' & $wp[3] & ', ' & $tmfound & @CRLF) WinMove($hg,"",$wp[0] - 20,$wp[1],20,$wp[3]) EndIf EndIf If Not WinExists("[class:#32768]") And $tmfound Then $tmfound = False WinMove($hg,"",0,@DesktopHeight) EndIf WEnd Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. Link to comment Share on other sites More sharing options...
C2C Posted April 26, 2008 Author Share Posted April 26, 2008 You my friend a man or a woman are a genius Youve made my day This has little to no program functioning value but im a sucker for eye candy so this means the world for me THAAAANKS :D ----------------------------------90% of teens today would die if Myspace,Bebo + FaceBook had a system failure and was completely destroyed. If you are one of the 10% that would be laughing, copy and paste this to your signature.----------------------------------Code to win, 'till you die, 'till the compiler dies from your linesCode to win, take it all, just keep coding till you fallDay by day, codin' all the way, I'm not cavin' inLet another App begin, code to win Link to comment Share on other sites More sharing options...
martin Posted April 26, 2008 Share Posted April 26, 2008 You my friend a man or a woman are a genius Youve made my day This has little to no program functioning value but im a sucker for eye candy so this means the world for me THAAAANKS :D Glad you liked that. One small improvement I thought of that you can make the effect apply to the script as well by using a timer. This example only works with beta, but the same thing can be done in the production version using dllcallback.au3. expandcollapse popup#include <Constants.au3> #include <timers.au3> #include <windowsconstants.au3> Opt("OnExitFunc","_Leaving") $hg = GUICreate("", 20, 150, 0, @DesktopHeight, $WS_POPUP, $WS_EX_TOPMOST) $pic = GUICtrlCreatePic("something.bmp", 0, 0, 20, 150);..;put your picture here GUISetBkColor(0, $hg);just so it's clearly seen with no picture GUISetState() Opt("TrayAutoPause", 0); Script will not be paused when clicking the tray icon. $zal = TrayCreateItem("Firewall: OFF") $zalon = False TrayCreateItem("") $zipbk = TrayCreateItem("Backup: pending") $zipisrun = True; TrayCreateItem("") $showlog = TrayCreateItem("view log") $togo = '24H' $SetToGo = '' ConsoleWrite($zal & ', ' & Hex(ControlGetHandle($hg, '', $zal)) & @CRLF) $tmfound = False TraySetState() _Timer_SetTimer($hg, 500, "checktm") While 1 Sleep(90) WEnd Func checktm($hWnd, $Msg, $iIDTimer, $dwTime) If WinExists("[class:#32768]") And Not $tmfound Then $wp = WinGetPos("[class:#32768]") If $wp[1] + $wp[3] > @DesktopHeight - 20 Then $tmfound = True ConsoleWrite($wp[0] & ', ' & $wp[1] & ', ' & $wp[2] & ', ' & $wp[3] & ', ' & $tmfound & @CRLF) WinMove($hg, "", $wp[0] - 20, $wp[1], 20, $wp[3]) EndIf EndIf If Not WinExists("[class:#32768]") And $tmfound Then $tmfound = False WinMove($hg, "", 0, @DesktopHeight) EndIf EndFunc ;==>checktm Func _Leaving() _Timer_KillAllTimers($hG) EndFunc I still don't know how to identify the correct tray menu though. Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. Link to comment Share on other sites More sharing options...
C2C Posted April 26, 2008 Author Share Posted April 26, 2008 I think i have an idea. PM'd you ----------------------------------90% of teens today would die if Myspace,Bebo + FaceBook had a system failure and was completely destroyed. If you are one of the 10% that would be laughing, copy and paste this to your signature.----------------------------------Code to win, 'till you die, 'till the compiler dies from your linesCode to win, take it all, just keep coding till you fallDay by day, codin' all the way, I'm not cavin' inLet another App begin, code to win Link to comment Share on other sites More sharing options...
martin Posted April 27, 2008 Share Posted April 27, 2008 (edited) I think i have an idea. PM'd youFollowing your suggestion about using Tray events I've got this to work to a certain stage. It's done in a bit of a rush, and needs some work, but it's 1.30 am here so I'm off to bed. Anyway, it is supposed to only add the licture to the tray menu for the script. There must be a better way and maybe someone will tell us. expandcollapse popup#include <Constants.au3> #include <GUIConstantsEx.au3> #include <timers.au3> #include <windowsconstants.au3> Opt("OnExitFunc", "_Leaving") Opt("mustDeclareVars", 1) #Region options Global $usebutton = 4;1=leftdown,2=leftup, 3= rightdown,4=rightup Global $DoSlideOut = False;image slides out to right Global $MouseOutCloses = True;id mouse moves away from tray menu the menu closes Global $PicWid = 32, $PicHt = 150;the picture size to show at the left of the tray menu Global $GuiBG = 0;the colour of the background outside the picture if the picture isn't as high as the menu Global $TrayPic = "something.bmp";the picture to show #EndRegion options Global $ty = 0 Global $hGui, $Pic, $zal, $sliding, $zipbk, $showlog, $wp, $TrayMenuFound Global $UseButtonA, $UseButtonB $hGui = GUICreate("", $PicWid, 150, 0, @DesktopHeight, $WS_POPUP, $WS_EX_TOPMOST) $Pic = GUICtrlCreatePic($TrayPic, 0, 0, $PicWid, $PicHt);..;put your picture here GUICtrlSetResizing(-1, $GUI_DOCKALL) GUISetBkColor($guiBG, $hGui);just so it's clearly seen with no picture GUISetState() Opt("TrayAutoPause", 0); Script will not be paused when clicking the tray icon. Opt("TrayOnEventMode", 1) $sliding = -1 $zal = TrayCreateItem("zFirewall: OFF") TrayCreateItem("") $zipbk = TrayCreateItem("zBackup: pending") TrayCreateItem("") $showlog = TrayCreateItem("zview log") $TrayMenuFound = False $UseButtonA = -6 - $usebutton Switch $usebutton Case 1 $UseButtonA = 1 $UseButtonB = -8 Case 2 $UseButtonA = 2 $UseButtonB = -7 Case 3 $UseButtonA = 8 $UseButtonB = -10 Case 4 $UseButtonA = 16 $UseButtonB = -9 EndSwitch TraySetOnEvent($UseButtonB, "_MouseLeftUpOnTrayIcon") TraySetState() TraySetClick($UseButtonA) _Timer_SetTimer($hGui, 100, "_CheckTrayMenus") While 1 Sleep(40) WEnd Func _MouseLeftUpOnTrayIcon() $ty = TimerInit() EndFunc ;==>_MouseLeftUpOnTrayIcon Func _CheckTrayMenus($hWnd, $Msg, $iIDTimer, $dwTime) Local $mp, $debug1 = 0, $debug2 = 0, $gp Local $TimeSinceMouseOver = TimerDiff($ty) If $TimeSinceMouseOver > 1000 And Not $TrayMenuFound Then WinMove($hGui, "", 0, @DesktopHeight) $debug1 = 1 Return EndIf If $TrayMenuFound And WinExists("[class:#32768]") Then $wp = WinGetPos("[class:#32768]") If $sliding > -1 And $DoSlideOut Then If $sliding < $PicWid Then $sliding += 2 If $sliding > $PicWid Then $sliding = $PicWid WinMove($hGui, "", $wp[0] - $sliding, $wp[1], $PicWid, $wp[3]) EndIf EndIf $mp = MouseGetPos() $gp = WinGetPos($hGui) If $wp[0] > $gp[0] + $gp[2] Then $TrayMenuFound = False If $MouseOutCloses Then If Not _MouseOverMenu($mp, $wp) Then $TrayMenuFound = False $TrayMenuFound = False MouseMove($wp[0] - 1, $wp[1] + 10, 0) MouseClick("left") Sleep(50) MouseMove($mp[0], $mp[1], 0) EndIf EndIf EndIf If WinExists("[class:#32768]") And Not $TrayMenuFound Then $wp = WinGetPos("[class:#32768]") If $wp[1] + $wp[3] > @DesktopHeight - 20 Then $TrayMenuFound = True If $DoSlideOut Then $sliding = 0 Else $sliding = $PicWid EndIf WinMove($hGui, "", $wp[0] - $sliding, $wp[1], $PicWid, $wp[3]) EndIf EndIf If Not WinExists("[class:#32768]") And $TrayMenuFound Then $TrayMenuFound = False $sliding = -1 WinMove($hGui, "", 0, @DesktopHeight) EndIf EndFunc ;==>_CheckTrayMenus Func _Leaving() _Timer_KillAllTimers($hGui) EndFunc ;==>_Leaving Func _MouseOverMenu($aM, $aw) If $aM[0] < $aw[0] - $PicWid Or $aM[0] > $aw[0] + $aw[2] Then Return False If $aM[1] < $aw[1] Or $aM[1] > $aw[1] + $aw[3] Then Return False Return True EndFunc ;==>_MouseOverMenu EDIT: 28th April 2008. Improved and allowed for mouse button left or right, up or down to be used to bring up the tray menu, and fixed some problems. Allow to set whether or not mouse moving away from menu closes the menu. Edited April 28, 2008 by martin Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. Link to comment Share on other sites More sharing options...
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