; Modify By : GoravG ; Author : komalo ; AutoIt v3.3.10.0 ; DllCall Modify By : GoravG Func _processgetname($i_pid) If NOT ProcessExists($i_pid) Then SetError(1) Return "" EndIf Local $a_processes = ProcessList() If NOT @error Then For $i = 1 To $a_processes[0][0] If $a_processes[$i][1] = $i_pid Then Return $a_processes[$i][0] Next EndIf SetError(1) Return "" EndFunc Func _winapi_check($sfunction, $ferror, $verror, $ftranslate = False) If $ferror Then If $ftranslate Then $verror = _winapi_getlasterrormessage() _winapi_showerror($sfunction & ": " & $verror) EndIf EndFunc Func _winapi_formatmessage($iflags, $psource, $imessageid, $ilanguageid, $pbuffer, $isize, $varguments) Local $aresult $aresult = DllCall("Kernel32.dll", "int64", "FormatMessageA", "int64", $iflags, "hwnd", $psource, "int64", $imessageid, "int64", $ilanguageid, "ptr", $pbuffer, "int64", $isize, "ptr", $varguments) Return $aresult[0] EndFunc Func _winapi_getlasterror() Local $aresult $aresult = DllCall("Kernel32.dll", "int64", "GetLastError") Return $aresult[0] EndFunc Func _winapi_getlasterrormessage() Local $ttext $ttext = DllStructCreate("char Text[4096]") _winapi_formatmessage(4096, 0, _winapi_getlasterror(), 0, DllStructGetPtr($ttext), 4096, 0) Return DllStructGetData($ttext, "Text") EndFunc Func _winapi_msgbox($iflags, $stitle, $stext) BlockInput(0) MsgBox($iflags, $stitle, $stext & " ") EndFunc Func _winapi_registerwindowmessage($smessage) Local $aresult $aresult = DllCall("User32.dll", "int64", "RegisterWindowMessage", "str", $smessage) _winapi_check("_WinAPI_RegisterWindowMessage", ($aresult[0] = 0), 0, True) Return $aresult[0] EndFunc Func _winapi_showerror($stext, $fexit = True) _winapi_msgbox(266256, "Error", $stext) If $fexit Then Exit EndFunc Func _winapi_setlayeredwindowattributes($hwnd, $itranscolor, $itransgui = 255, $iflags = 3, $bcolorref = False) If $iflags = Default OR $iflags = "" OR $iflags < 0 Then $iflags = 3 If NOT $bcolorref Then $itranscolor = Int(BinaryMid($itranscolor, 3, 1) & BinaryMid($itranscolor, 2, 1) & BinaryMid($itranscolor, 1, 1)) EndIf Local $aresult = DllCall("user32.dll", "bool", "SetLayeredWindowAttributes", "hwnd", $hwnd, "INT64", $itranscolor, "byte", $itransgui, "dword", $iflags) If @error Then Return SetError(@error, @extended, False) Return $aresult[0] EndFunc ;------------------My Script Start(By GoravG)-------------------------------------------- $MGui = GUICreate("Transparent Tool", 240, 130, -1, -1, -1, 524288) GUISetBkColor(11259375) GUICtrlCreateLabel("Enter Name Example: cmd.exe", 18, 5, 200, 36) GUICtrlCreateLabel("By GoravG", 90, 108, 138, 36) _winapi_setlayeredwindowattributes($MGui, 11259375, 255) $Button0 = GUICtrlCreateButton("Trans", 18, 70, 100, 30) $Button1 = GUICtrlCreateButton("Normal", 124, 70, 100, 30) $Input = GUICtrlCreateInput("", 14, 29, 210, 30) GUICtrlSetFont(-1, 10, 400, 0, "MS Sans Serif") $MGui1 = GUICreate("", 700, 400, -1, -1, -1) GUISetState(@SW_SHOW, $MGui) While 1 Switch GUIGetMsg() Case -3 Exit Case $Button0 GUIRegisterMsg(_winapi_registerwindowmessage("SHELLHOOK"), "HookProc") shellhookwindow($MGui1, 1) clearmemory() Case $Button1 GUIRegisterMsg(_winapi_registerwindowmessage("SHELLHOOK"), "HookProc") shellhookwindow($MGui1, 0) clearmemory() EndSwitch WEnd ;---------------------My Script End(By GoravG)------------------------------------------------- Func hookproc($hwnd, $msg, $wparam, $lparam) Switch $wparam Case 1 If _processgetname(WinGetProcess($lparam)) = GUICtrlRead($Input) Then ; Modify by GoravG "GUICtrlRead($Input)" enableblurbehind($lparam) clearmemory() EndIf Case 4 clearmemory() EndSwitch EndFunc Func shellhookwindow($hwnd, $bflag) Local $sfunc = "DeregisterShellHookWindow" If $bflag Then $sfunc = "RegisterShellHookWindow" Local $aret = DllCall("user32.dll", "int64", $sfunc, "hwnd", $hwnd) Return $aret[0] EndFunc Func enableblurbehind($hwnd) Const $dwm_bb_enable = 1 $struct = DllStructCreate("dword;int;ptr;int") DllStructSetData($struct, 1, $dwm_bb_enable) DllStructSetData($struct, 2, "1") DllStructSetData($struct, 4, "1") DllCall("dwmapi.dll", "int64", "DwmEnableBlurBehindWindow", "hwnd", $hwnd, "ptr", DllStructGetPtr($struct)) EndFunc Func clearmemory() Local $ai_return = DllCall("psapi.dll", "int64", "EmptyWorkingSet", "long", -1) Return $ai_return[0] EndFunc