summaryrefslogtreecommitdiff
path: root/sd/source/ui/view/FormShellManager.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-09-18 15:10:41 +0200
committerNoel Grandin <noelgrandin@gmail.com>2015-09-20 06:37:36 +0000
commit99bfc363a6f6779d0be2284f85a9131254bce1f9 (patch)
tree3da30adea892bae0f5e76031d8561e114c2da8d9 /sd/source/ui/view/FormShellManager.cxx
parente3c3b7fde3c017bd7d25f04fabf9b4528e37fb49 (diff)
convert Link<> to typed
Change-Id: I10b050dc4aae45e646761a82520caa96969bc511 Reviewed-on: https://gerrit.libreoffice.org/18700 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'sd/source/ui/view/FormShellManager.cxx')
-rw-r--r--sd/source/ui/view/FormShellManager.cxx57
1 files changed, 26 insertions, 31 deletions
diff --git a/sd/source/ui/view/FormShellManager.cxx b/sd/source/ui/view/FormShellManager.cxx
index 02ffc9f91ece..44ecdfec1417 100644
--- a/sd/source/ui/view/FormShellManager.cxx
+++ b/sd/source/ui/view/FormShellManager.cxx
@@ -223,45 +223,40 @@ IMPL_LINK_TYPED(FormShellManager, ConfigurationUpdateHandler, sd::tools::EventMu
}
}
-IMPL_LINK(FormShellManager, WindowEventHandler, VclWindowEvent*, pEvent)
+IMPL_LINK_TYPED(FormShellManager, WindowEventHandler, VclWindowEvent&, rEvent, void)
{
- if (pEvent != NULL)
+ switch (rEvent.GetId())
{
- switch (pEvent->GetId())
+ case VCLEVENT_WINDOW_GETFOCUS:
{
- case VCLEVENT_WINDOW_GETFOCUS:
+ // The window of the center pane got the focus. Therefore
+ // the form shell is moved to the bottom of the object bar
+ // stack.
+ ViewShell* pShell = mrBase.GetMainViewShell().get();
+ if (pShell!=NULL && mbFormShellAboveViewShell)
{
- // The window of the center pane got the focus. Therefore
- // the form shell is moved to the bottom of the object bar
- // stack.
- ViewShell* pShell = mrBase.GetMainViewShell().get();
- if (pShell!=NULL && mbFormShellAboveViewShell)
- {
- mbFormShellAboveViewShell = false;
- ViewShellManager::UpdateLock aLock (mrBase.GetViewShellManager());
- mrBase.GetViewShellManager()->SetFormShell(
- pShell,
- mpFormShell,
- mbFormShellAboveViewShell);
- }
+ mbFormShellAboveViewShell = false;
+ ViewShellManager::UpdateLock aLock (mrBase.GetViewShellManager());
+ mrBase.GetViewShellManager()->SetFormShell(
+ pShell,
+ mpFormShell,
+ mbFormShellAboveViewShell);
}
+ }
+ break;
+
+ case VCLEVENT_WINDOW_LOSEFOCUS:
+ // We follow the sloppy focus policy. Losing the focus is
+ // ignored. We wait for the focus to be placed either in
+ // the window or the form shell. The later, however, is
+ // notified over the FormControlActivated handler, not this
+ // one.
break;
- case VCLEVENT_WINDOW_LOSEFOCUS:
- // We follow the sloppy focus policy. Losing the focus is
- // ignored. We wait for the focus to be placed either in
- // the window or the form shell. The later, however, is
- // notified over the FormControlActivated handler, not this
- // one.
- break;
-
- case VCLEVENT_OBJECT_DYING:
- mpMainViewShellWindow = NULL;
- break;
- }
+ case VCLEVENT_OBJECT_DYING:
+ mpMainViewShellWindow = NULL;
+ break;
}
-
- return 0;
}
void FormShellManager::Notify(SfxBroadcaster&, const SfxHint& rHint)