diff options
author | Philipp Lohmann <Philipp.Lohmann@Sun.COM> | 2009-10-29 14:22:34 +0100 |
---|---|---|
committer | Philipp Lohmann <Philipp.Lohmann@Sun.COM> | 2009-10-29 14:22:34 +0100 |
commit | 19b01b2cbe8df5c53a65b967c5da9e1eb1ff86ae (patch) | |
tree | dbec49aa29eba76c9be1b9676f708bd37b2c1420 /vcl/source/control | |
parent | 80ccdb417dd3eeb6f70d8c39eb6448185adec94c (diff) |
#i106400# DisclosureButton should react on +/- keys
Diffstat (limited to 'vcl/source/control')
-rw-r--r-- | vcl/source/control/button.cxx | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx index 71af9b3142c9..08992c903040 100644 --- a/vcl/source/control/button.cxx +++ b/vcl/source/control/button.cxx @@ -4457,3 +4457,22 @@ void DisclosureButton::ImplDrawCheckBoxState() DrawImage( aOff, *pImg, nStyle ); } } + +// ----------------------------------------------------------------------- + +void DisclosureButton::KeyInput( const KeyEvent& rKEvt ) +{ + KeyCode aKeyCode = rKEvt.GetKeyCode(); + + if( !aKeyCode.GetModifier() && + ( ( aKeyCode.GetCode() == KEY_ADD ) || + ( aKeyCode.GetCode() == KEY_SUBTRACT ) ) + ) + { + Check( aKeyCode.GetCode() == KEY_ADD ); + } + else + Button::KeyInput( rKEvt ); +} + + |