wxTreeCtrl question

BlitzMax Forums/Brucey's Modules/wxTreeCtrl question

Pete Rigz(Posted 2009) [#1]
2 questions I suppose, is the wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK event implemented and is it Windows only, I'm assuming yes as that's what it says in the wxWidgets docs. I want to implement checkboxes on tree controls and it mentions this method in the book I have, but it makes no mention in there about being windows only...

I guess you wouldn't have bothered implementing it if it's Windows only which is fair enough, I probably won't use it if that's the case. Thanks!


Brucey(Posted 2009) [#2]
Well, it's in the list of events for the event handler (in wxtreectrl.bmx), so I guess if the framework raises the event then it will be called by wxMax.

If other platforms don't raise the event, well, I suppose you'd have to work out something else on those platforms, but it all compiles on the three platforms.


Pete Rigz(Posted 2009) [#3]
Yeh I tried it, but nothing was being raised (Sorry, I should have mentioned that!)

Quick sample here:




Brucey(Posted 2009) [#4]
According to the source (of wxWidgets), this event is raised when you release the left mouse button (click) on a part of an item with a TVHT_ONITEMSTATEICON flag (which is determined by a hit-test).

No idea what a state item is though.

And it is indeed Win32 only.


Pete Rigz(Posted 2009) [#5]
ahh ok, cheers :)