Hi Bala,
You can use something like this:
# self is a subclassed wxTreeCtrl
def OnMouseLButtonUp(self,event):
target = self.HitTest(event.GetPosition()) # HitTest return a tuple (wxTreeItemId, wxTREE_HITTEST_x flag )
if target[1] == wxTREE_HITTEST_ONITEMICON: # check the documentation for wxTreeCtrl::HitTest to see all availables flags
doCheckUncheckStuff()
Hope this helps,
/vh
Ronald Jaramillo
···
On Mar 31, 2004, at 2:34 PM, bala wrote:
Hi,
iam having a checkbox image(checked image and UnCheckedImage) in a TreeControl,I want to check or uncheck only if i click the checkbox image.
Right now, if i click anywhere in the row, the chceckbox get checked or unchecked...
what i have to do.......If you give me the solution...I will be very thankfull to you
Regards
Bala