Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why are some items greyed out in Spy++'s Windows view?

To modify a window of another program, I need to find a specific SysTreeView32 in it using EnumChildWindows API call.

When I inspect the window using Spy++, there are a number of SysTreeView32's in it but all are greyed out except one, which is the one I'm looking for.

The following picture is an example of grey items:

Why are some items grey?

Why are the shown items gray and what API call does Spy++ use to know whether it should grey out an item or not?

like image 576
Hossein Avatar asked Aug 04 '11 04:08

Hossein


1 Answers

Those are just non-visible windows - ie HWNDs that don't have the WS_VISIBLE style bit set. They are often worker windows - windows that just exist to process various messages in the background - or in some cases are UI that's yet to become visible. For example, a window that lets you hide or show a toolbar may just hide it by making it invisible rather than destroying it and recreating it later.

In your specific case, the WorkerW could be a placeholder for some other piece of UI that's not needed right now, while the msctl_statusbar32 looks like it's a hidden status bar.

like image 182
BrendanMcK Avatar answered Sep 20 '22 08:09

BrendanMcK