|
-
August 12th, 2011, 05:24 AM
#1
ListView Mouse Disable
I am trying to figure out how do I disable mouse input in a ListView(SysListView32) control using Win32API not MFC.
One way around is to Disable the window by EnableWindow(FALSE) but this approach sets the color of it gray and I need to set the background color to White.
How can I achieve this. Any ideas ?
◄◄ hypheni ►►
-
August 12th, 2011, 06:44 AM
#2
Re: ListView Mouse Disable
Euhm,
I'm not sure but why not handle all clicks on the HWND yourself? If not all are sended, you could try to send the SetCapture() API.
Hope it helps.
-
August 12th, 2011, 06:59 AM
#3
Re: ListView Mouse Disable
Actually Im implementing the thing in NSIS installer where I cant handle this Callbacks.
Im posting here just for API method so that I can implement that in NSIS way.
My simple question is How do I disable mouse click to any window ?.
◄◄ hypheni ►►
-
August 14th, 2011, 07:13 PM
#4
Re: ListView Mouse Disable
 Originally Posted by hypheni
Actually Im implementing the thing in NSIS installer where I cant handle this Callbacks.
Im posting here just for API method so that I can implement that in NSIS way.
My simple question is How do I disable mouse click to any window ?.
The gray color is set by default. you can set its style as owner-draw to change its color.
For your simple question, that needs you to handle mouse clicks on "any windows" you want to control.
-
August 14th, 2011, 08:33 PM
#5
Re: ListView Mouse Disable
 Originally Posted by hypheni
My simple question is How do I disable mouse click to any window ?.
As mentioned, just handle all the mouse messages and do nothing with them.
-
August 15th, 2011, 02:28 AM
#6
Re: ListView Mouse Disable
 Originally Posted by Arjay
As mentioned, just handle all the mouse messages and do nothing with them.
What do you mean by "do nothing with them" ?
-
August 15th, 2011, 07:12 AM
#7
Re: ListView Mouse Disable
 Originally Posted by PumpoBee
What do you mean by "do nothing with them" ?
Don't call the base class message handler for messages you want to discard.
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
|