sw/source/ui/fldui/javaedit.cxx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-)
New commits: commit 9980636a5c3a499c299a8b6f4b93965f18bb4311 Author: Caolán McNamara <caol...@redhat.com> Date: Wed Feb 4 17:11:14 2015 +0000 Resolves: tdf#68137 crash in traversing script fields use the same guards as the SwFldEditDlg does (cherry picked from commit 38a65f76bc944ea730ebac7640dc135248ec3da0) Conflicts: sw/source/ui/fldui/javaedit.cxx Change-Id: I7d135cf969d9925cec57a90ef0fba8fe40f664eb Reviewed-on: https://gerrit.libreoffice.org/14324 Tested-by: Michael Stahl <mst...@redhat.com> Reviewed-by: Michael Stahl <mst...@redhat.com> diff --git a/sw/source/ui/fldui/javaedit.cxx b/sw/source/ui/fldui/javaedit.cxx index 6841271..4d70536 100644 --- a/sw/source/ui/fldui/javaedit.cxx +++ b/sw/source/ui/fldui/javaedit.cxx @@ -77,8 +77,8 @@ SwJavaEditDialog::SwJavaEditDialog(Window* pParent, SwWrtShell* pWrtSh) : aFont.SetWeight( WEIGHT_LIGHT ); m_pEditED->SetFont( aFont ); - pMgr = new SwFldMgr; - pFld = (SwScriptField*)pMgr->GetCurFld(); + pMgr = new SwFldMgr(pSh); + pFld = static_cast<SwScriptField*>(pMgr->GetCurFld()); bNew = !(pFld && pFld->GetTyp()->Which() == RES_SCRIPTFLD); @@ -92,6 +92,7 @@ SwJavaEditDialog::SwJavaEditDialog(Window* pParent, SwWrtShell* pWrtSh) : SwJavaEditDialog::~SwJavaEditDialog() { + pSh->EnterStdMode(); delete pMgr; delete pFileDlg; Application::SetDefDialogParent( pOldDefDlgParent ); @@ -99,6 +100,8 @@ SwJavaEditDialog::~SwJavaEditDialog() IMPL_LINK_NOARG_INLINE_START(SwJavaEditDialog, PrevHdl) { + pSh->EnterStdMode(); + SetFld(); pMgr->GoPrev(); pFld = (SwScriptField*)pMgr->GetCurFld(); @@ -111,6 +114,8 @@ IMPL_LINK_NOARG_INLINE_END(SwJavaEditDialog, PrevHdl) IMPL_LINK_NOARG_INLINE_START(SwJavaEditDialog, NextHdl) { + pSh->EnterStdMode(); + SetFld(); pMgr->GoNext(); pFld = (SwScriptField*)pMgr->GetCurFld();
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits