开发者

wxpython, what to bind an application wide mouse event to

hey.. i have a panel (lets call it mainpanel) with a couple of p开发者_JAVA技巧anels in it and other widgets. i need to know what to bind the wx.EVT_LEFT_DOWN to in order for it to fire an event for clicks anywhere in mainpanel and its children. e.g. if i click on a textctrl in mainpanel i want it to pick that up aswell. binding to mainpanel doesnt work. please help i really need to find a solution to this its making me mad! p.s. binding everychild to the wx.EVT_LEFT_DOWN is not an option i have hundreds of children i really dont want to go that route


Text controls eat mouse clicks so you may just want to catch the focus event for them. I think the rest should work though.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜