Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Cannot make window visible by activation
#2
Probably it is "cloaked". Or finds another cloaked window with same name.

Macro Macro2526
Code:
Copy      Help
int w=win("Start menu" "ImmersiveLauncher")
act w
int active(win=w) visible(IsWindowVisible(w)) cloaked(IsWindowCloaked(w))
out "active=%i visible=%i cloaked=%i" active visible cloaked
if cloaked
,cloaked=0
,if(DwmSetWindowAttribute(w 13 &cloaked 4)) out _s.dllerror ;;Try to uncloak. Error: Access is denied..
,

If you don't have IsWindowCloaked:

Function IsWindowCloaked
Code:
Copy      Help
function# hwnd

;Returns nonzero if the window is cloaked.
;Returns flags: 0 not cloaked, 1 cloaked by its application, 2 cloaked by Windows, 4 parent window is cloaked.

;REMARKS
;On Windows 8 and later, a window may be cloaked. Then it is invisible, although functions IsWindowVisible and hid say it is visible.
;On Windows 8, cloaked are inactive Windows store app windows. Also some inactive system windows, such as Start screen and Search.
;On Windows 10, cloaked are windows on inactive desktops. Also some system windows.

;Added in: QM 2.4.3.


if(_winver>=0x602 and !DwmGetWindowAttribute(hwnd 14 &_i 4)) ret _i


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)