|
-
May 28th, 1999, 02:08 PM
#1
How do I subclass the desktop?
I'm having difficultry trying to subclass the desktop. I've tried the following:
subClass.SubclassWindow(GetDesktopWindow()->m_hWnd);
subClass is a class that I've derived from CWnd to capture messages. Any help is appreciated.
-
May 28th, 1999, 04:00 PM
#2
Re: How do I subclass the desktop?
If you use Spy, you will see that the desktop is actually the a List Control("Program Manager"->SHELLDLL_DefView->SysListView32). You may want to subclass that one instead.
-Safai
-
May 29th, 1999, 02:27 AM
#3
Re: How do I subclass the desktop?
Hello,
You mean I can subclass any window, even one that doesn't belongs to my application ? How to do this if I have handle (HWND) to this window ?
Regards,
Andris
-
June 13th, 1999, 09:57 PM
#4
Re: How do I subclass the desktop?
This will not work since under WIN32, you cannot subclass windows belonging to other processess (SetWindowLong(...), used for actually performing the Subclassing will return zero when it detects that you are trying to subclass a window in another process). You must either use a Shell NameSpace extension or use system wide hook to get the shell to insert (inject) you (your dll) in shell's address space. then you can subclass the desktop.
Hope this helps.
Vali
-
June 15th, 1999, 01:15 PM
#5
Re: How do I subclass the desktop?
I'm about 6 months into using Visual C++. Do you have, or do you know the location of an example of using Shell Namespaces? I've heard of namespaces, but have yet to use one. I appreciate the input.
-
June 16th, 1999, 03:56 PM
#6
Re: How do I subclass the desktop?
One of the best books on the market for NameSpace / Shell extensions is:
Visual C++ Windows Shell Programming
By
Dan Esposito
Wrox Books
-
February 12th, 2002, 09:18 AM
#7
Re: How do I subclass the desktop?
Please suggest me how to inject my system wide hook into shell dll.
Gupta.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|