{$cleq}
declare h1&,h2&,ptr#
dim ptr#,8
window 100,100 - 0,0
h1&:=createdialog(%hwnd,"",10,10,200,200) schattn
h2&:=createdialog(%hwnd,"",0,0,200,200) bült
external("user32","SetWindowLongA",h1&, -20, @Or(external("user32","GetWindowLongA",h1&,-20),$80000));
external("user32","SetWindowLongA",h2&, -20, @Or(external("user32","GetWindowLongA",h2&,-20),$80000));
external("user32","SetLayeredWindowAttributes",h1&, 0, 150, $2);
external("user32","SetLayeredWindowAttributes",h2&, 0, 222, $2)
external("user32","SetWindowRgn",h1&, external("gdi32","CreateRectRgn",10,50,190,190), 1)
external("user32","SetWindowRgn",h2&, external("gdi32","CreateRectRgn",10,50,190,190), 1)
external("user32","SetParent",%hwnd,getDesktopHdl())
external("user32","SetParent",h1&,getDesktopHdl())
external("user32","SetParent",h2&,getDesktopHdl())
showwindow(%hwnd,0)
startpaint h1&;cls 0;endpaint
startpaint h2&;cls rgb(255,255,255);endpaint
while 1
external("user32","GetCursorPos",ptr#)
external("user32","SetWindowPos",h1&,0,long(ptr#,0)+10,long(ptr#,4)+10,190,190,( 1 | 4 | 8 | 16 ))
external("user32","SetWindowPos",h2&,0,long(ptr#,0) ,long(ptr#,4) ,190,190,( 1 | 4 | 8 | 16 ))
sleep 10
wend
end
Proc GetDesktopHdl
Return If(External("user32","FindWindowExA",External("user32","FindWindowExA",External("user32","FindWindowExA",0,0,"progman",0),0,"SHELLDLL_DefView",0),0,"Internet Explorer_Server",0)>0,External("user32","FindWindowExA",External("user32","FindWindowExA",External("user32","FindWindowExA",0,0,"progman",0),0,"SHELLDLL_DefView",0),0,"Internet Explorer_Server",0),External("user32","FindWindowExA",External("user32","FindWindowExA",External("user32","FindWindowExA",0,0,"progman",0),0,"SHELLDLL_DefView",0),0,"SysListView32",0))
Endproc
Kleine Desktopspielerei von mir.