Adding a right-click context menu entry to Window Titlebar

S

SupportAV

I want to add an entry to the context menu of every window's titlebar.
I don't think the menu is technically a context menu, but more like a
shell menu.

The closest I've come is some vague C++ code, but it was supposedly
unreliable in all cases.

I need to be able to create a hook in such a way so that any window
automatically has a custom menu entry in the right-click title bar
menu.

If anyone knows of a working example, or better yet a reference guide
illustrating the example and explaining what the limitations and
pitfalls are, I'd be very greatful. I'd especially like to know how a
progam that is launched from such a menu would run in terms of
security.
 
R

rowe_newsgroups

I want to add an entry to the context menu of every window's titlebar.
I don't think the menu is technically a context menu, but more like a
shell menu.

The closest I've come is some vague C++ code, but it was supposedly
unreliable in all cases.

I need to be able to create a hook in such a way so that any window
automatically has a custom menu entry in the right-click title bar
menu.

If anyone knows of a working example, or better yet a reference guide
illustrating the example and explaining what the limitations and
pitfalls are, I'd be very greatful. I'd especially like to know how a
progam that is launched from such a menu would run in terms of
security.

Why exactly do you want to change this? It seems very dangerous to me
to change the default behavior of the Window's interface. It will only
lead to overlooked features or confused users (both are very bad
things).

Thanks,

Seth Rowe [MVP]
 
S

SupportAV

I'd like to be able to create a custom kill utility so that you could
right-click on the window and you'd have "Kill Process" in the context
menu of any given window.
 
S

SupportAV

I want to be able to create a custom "Kill Processes" menu on any
given window.
 
R

rowe_newsgroups

I'd like to be able to create a custom kill utility so that you could
right-click on the window and you'd have "Kill Process" in the context
menu of any given window.

I have seen .NET code for adding buttons to the title bar, but I
haven't seen any that replace the context menu. I don't have the link
to the article for the custom button, or even the article's name, but
I do know I saw it on codeproject.com a couple months back. Good luck
searching!

Thanks,

Seth Rowe [MVP]
 
S

SupportAV

Thanks. I think I'm going to take a different tactic. I'll run an app
in the system tray that will let you pass the mouse pointer over a
window and offer to kill the associated process. Sysinternals used the
technique on one of their programs so at least there are working
examples.

Less elegant, but adding an entry to every shell window's title
context bar menu seems like it will take an act of god.

Although there are various shell enhancements that let you "pin"
windows, etc. which under the hood must use a similar technique....
just their purpose is a little different.

If anyone can add something, I'd still appreciate it.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top