summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2016-07-04 15:31:29 +0100
committerCaolán McNamara <caolanm@redhat.com>2016-07-05 09:25:13 +0000
commit2bda972c0f40a0d69749504f51e3c16d7488d011 (patch)
treecbe35c567ada89a3fde3706836137a743062d702
parentda2aad871bfccd28b47d8ddf47dd6b5b1f834220 (diff)
Resolves: tdf#100761 after insert note, focus cannot return to inputbar
suspected regression from. commit 11d605cc5a0c221d2423b6e63f502db660d085d2 Date: Mon Feb 1 18:39:51 2016 +0200 tdf#84843 Stop using PseudoSlots for drawing slots Change-Id: I64aba363f7562c6b16ae1d679968149fea1ba763 Reviewed-on: https://gerrit.libreoffice.org/26909 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com> (cherry picked from commit 80509950d35cebaede89fcb52c446a1fd3e45ba3) Reviewed-on: https://gerrit.libreoffice.org/26936 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--sc/source/ui/view/tabview5.cxx3
-rw-r--r--sc/source/ui/view/tabvwsh4.cxx2
-rw-r--r--sc/source/ui/view/viewfun6.cxx6
3 files changed, 5 insertions, 6 deletions
diff --git a/sc/source/ui/view/tabview5.cxx b/sc/source/ui/view/tabview5.cxx
index 6e5e3bf27caa..a06afbc84a34 100644
--- a/sc/source/ui/view/tabview5.cxx
+++ b/sc/source/ui/view/tabview5.cxx
@@ -353,8 +353,7 @@ void ScTabView::DrawDeselectAll()
if (pDrawView)
{
ScTabViewShell* pViewSh = aViewData.GetViewShell();
- if ( pDrawActual &&
- ( pViewSh->IsDrawTextShell() || pDrawActual->GetSlotID() == SID_DRAW_NOTEEDIT ) )
+ if (pDrawActual && pViewSh->IsDrawTextShell())
{
// end text edit (as if escape pressed, in FuDraw)
aViewData.GetDispatcher().Execute( pDrawActual->GetSlotID(),
diff --git a/sc/source/ui/view/tabvwsh4.cxx b/sc/source/ui/view/tabvwsh4.cxx
index d1430303fb14..2d8825b2dec0 100644
--- a/sc/source/ui/view/tabvwsh4.cxx
+++ b/sc/source/ui/view/tabvwsh4.cxx
@@ -282,7 +282,7 @@ bool ScTabViewShell::PrepareClose(bool bUI)
// draw text edit mode must be closed
FuPoor* pPoor = GetDrawFuncPtr();
- if ( pPoor && ( IsDrawTextShell() || pPoor->GetSlotID() == SID_DRAW_NOTEEDIT ) )
+ if (pPoor && IsDrawTextShell())
{
// "clean" end of text edit, including note handling, subshells and draw func switching,
// as in FuDraw and ScTabView::DrawDeselectAll
diff --git a/sc/source/ui/view/viewfun6.cxx b/sc/source/ui/view/viewfun6.cxx
index 37e2cfa550ce..d7848f5b99ad 100644
--- a/sc/source/ui/view/viewfun6.cxx
+++ b/sc/source/ui/view/viewfun6.cxx
@@ -503,11 +503,11 @@ void ScViewFunc::EditNote()
// activate object (as in FuSelection::TestComment)
GetViewData().GetDispatcher().Execute( SID_DRAW_NOTEEDIT, SfxCallMode::SYNCHRON | SfxCallMode::RECORD );
// now get the created FuText and set into EditMode
- FuPoor* pPoor = GetDrawFuncPtr();
- if ( pPoor && (pPoor->GetSlotID() == SID_DRAW_NOTEEDIT) ) // has no RTTI
+ FuText* pFuText = dynamic_cast<FuText*>(GetDrawFuncPtr());
+ if (pFuText)
{
ScrollToObject( pCaption ); // make object fully visible
- static_cast< FuText* >( pPoor )->SetInEditMode( pCaption );
+ pFuText->SetInEditMode( pCaption );
}
}
}