|
|
发表于 2011-4-16 10:32:48
|
显示全部楼层
本帖最后由 xzxnovice 于 2011-4-16 10:38 编辑
- #include <PNGbackgroundUDF.au3>
- #include <ButtonConstants.au3>
- #include <EditConstants.au3>
- $PNG_GUI = CreateTransparentGUI("PNG图片显示(透明)", "Background1.png", $WS_POPUP)
- $Button1 = GUICtrlCreateButton("最小化窗口", ($PNG_GUI[2] - 115) / 2, $PNG_GUI[3] - 60, 115, 25, 0)
- $Button2 = GUICtrlCreateButton("隐藏窗口", ($PNG_GUI[2] - 115) / 2, $PNG_GUI[3] - 25 , 115, 25, 0)
- #EndRegion ### END Koda GUI section ###
- While 1
- $nMsg = GUIGetMsg()
- Switch $nMsg
- Case $GUI_EVENT_CLOSE
- Exit
-
- Case $Button1
- _WinAPI_ShowWindow($PNG_GUI[0],@SW_MINIMIZE)
- ;~ _WinAPI_ShowWindow($PNG_GUI[1],@SW_MINIMIZE);最小化窗口
- Case $Button2
- _WinAPI_ShowWindow($PNG_GUI[0],@SW_HIDE)
- _WinAPI_ShowWindow($PNG_GUI[1],@SW_HIDE) ;隐藏窗口
- EndSwitch
- WEnd
复制代码 上面其实是两个窗口,要一齐处理 |
|