[Fxruby-users] canFocus?
Status: Inactive
Brought to you by:
lyle
From: oleg d. <be...@be...> - 2003-08-30 18:42:51
|
Hello, Well, I'm creating my own widget and it apart from anything else must respond to the keyboard. As far as I could understand, in this case the widget should tell the top window it can receive focus, by redefining the canFocus virtual method. That's OK in C++, but when I'm trying to define it in my Ruby code, it (as well as canFocus?, but they are just the same, as seen from aliases.rb) is never called. So the focus is never gained and SEL_KEYPRESS messages don't come. To solve this problem I put the setFocus() call to the SEL_ENTER handler and it works, but now accelerator keys (defined in the top window menu) don't. Either this or that, but I want both of them :-) -- be9 |