summaryrefslogtreecommitdiff
path: root/vcl/source/window/dlgctrl.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'vcl/source/window/dlgctrl.cxx')
-rw-r--r--vcl/source/window/dlgctrl.cxx11
1 files changed, 11 insertions, 0 deletions
diff --git a/vcl/source/window/dlgctrl.cxx b/vcl/source/window/dlgctrl.cxx
index d6e73910805d..4394513ef4eb 100644
--- a/vcl/source/window/dlgctrl.cxx
+++ b/vcl/source/window/dlgctrl.cxx
@@ -506,10 +506,21 @@ vcl::Window* ImplFindAccelWindow( vcl::Window* pParent, sal_uInt16& rIndex, sal_
namespace vcl {
+void Window::SetMnemonicActivateHdl(const Link<vcl::Window&, bool>& rLink)
+{
+ if (mpWindowImpl) // may be called after dispose
+ {
+ mpWindowImpl->maMnemonicActivateHdl = rLink;
+ }
+}
+
void Window::ImplControlFocus( GetFocusFlags nFlags )
{
if ( nFlags & GetFocusFlags::Mnemonic )
{
+ if (mpWindowImpl->maMnemonicActivateHdl.Call(*this))
+ return;
+
if ( GetType() == WindowType::RADIOBUTTON )
{
if ( !static_cast<RadioButton*>(this)->IsChecked() )