summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sw/source/uibase/docvw/edtwin.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/sw/source/uibase/docvw/edtwin.cxx b/sw/source/uibase/docvw/edtwin.cxx
index 9ad8275b7b1b..bb0e735ec66f 100644
--- a/sw/source/uibase/docvw/edtwin.cxx
+++ b/sw/source/uibase/docvw/edtwin.cxx
@@ -5346,15 +5346,15 @@ void SwEditWin::LoseFocus()
void SwEditWin::Command( const CommandEvent& rCEvt )
{
- SwWrtShell &rSh = m_rView.GetWrtShell();
-
- if ( !m_rView.GetViewFrame() )
+ if (!m_rView.GetViewFrame() || isDisposed())
{
// If ViewFrame dies shortly, no popup anymore!
Window::Command(rCEvt);
return;
}
+ SwWrtShell &rSh = m_rView.GetWrtShell();
+
// The command event is send to the window after a possible context
// menu from an inplace client has been closed. Now we have the chance
// to deactivate the inplace client without any problem regarding parent