Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 12/23/2024 in all areas

  1. Here my take on it : #include <WinAPISys.au3> #include <GDIPlus.au3> #include <GuiConstants.au3> Opt("MustDeclareVars", True) Global $hGUI, $hGUI2, $hGUI3 Example() Func Example() _GDIPlus_Startup() $hGUI = GUICreateEx("main.png", 100, 100) $hGUI2 = GUICreateEx("item.png", 150, 400, $hGUI) $hGUI3 = GUICreateEx("item.png", 400, 400, $hGUI) GUIRegisterMsg($WM_NCHITTEST, WM_NCHITTEST) GUIRegisterMsg($WM_MOUSELEAVE, WM_MOUSELEAVE) While True Switch GUIGetMsg() Case $GUI_EVENT_CLOSE ExitLoop EndSwitch WEnd _GDIPlus_Shutdown() EndFunc ;==>Example Func GUICreateEx($sImage, $iPosX = -1, $iPosY = -1, $hParent = 0) Local $hImage = _GDIPlus_ImageLoadFromFile($sImage) Local $hWnd = GUICreate("", -1, -1, $iPosX, $iPosY, $WS_POPUP, BitOR($WS_EX_LAYERED, $hParent ? $WS_EX_MDICHILD : 0), $hParent) Local $hBitmap = _GDIPlus_BitmapCreateHBITMAPFromBitmap($hImage) _WinAPI_UpdateLayeredWindowEx($hWnd, -1, -1, $hBitmap) _WinAPI_DeleteObject($hBitmap) _GDIPlus_ImageDispose($hImage) GUISetState() Return $hWnd EndFunc ;==>GUICreateEx Func WM_NCHITTEST($hWnd, $iMsg, $wParam, $lParam) Switch $hWnd Case $hGUI Return $HTCAPTION Case $hGUI2 ConsoleWrite("hovering GUI2" & @CRLF) Case $hGUI3 ConsoleWrite("hovering GUI3" & @CRLF) EndSwitch _WinAPI_TrackMouseEvent($hWnd, $TME_LEAVE) EndFunc ;==>WM_NCHITTEST Func WM_MOUSELEAVE($hWnd, $msg, $wParam, $lParam) ConsoleWrite("leaving " & $hWnd & @CRLF) Return $GUI_RUNDEFMSG EndFunc ;==>WM_MOUSELEAVE Func GUIUpdate($sImage, $hWnd) Local $hImage = _GDIPlus_ImageLoadFromFile($sImage) Local $hBitmap = _GDIPlus_BitmapCreateHBITMAPFromBitmap($hImage) _WinAPI_UpdateLayeredWindowEx($hWnd, -1, -1, $hBitmap) _WinAPI_DeleteObject($hBitmap) _GDIPlus_ImageDispose($hImage) EndFunc ;==>GUIUpdate
    4 points
  2. You can use the GUIUpdate function (included in the script above) to change picture on hover and reset it back to normal on leave...
    1 point
  3. We have changed the login to require your Email address and disabled the option to use your member name to make the hacking of accounts harder, as that was happening regularly lately. We can assist in case you don't remember the Email address used at signup. Just use the "Contact us" link at the bottom of the page.
    1 point
  4. water

    UTC/GMT to local time

    Just a quick shot: The _DATE UDF (part of standard AutoIt) has some functions to convert UTC to local time and vice versa.
    1 point
  5. Jon

    Random DoS Attacks

    Hi, some random DoS attacks ongoing at the mo. Server is auto banning, but maybe some outages. Thanks, Jos, for letting me know,
    0 points
×
×
  • Create New...