coverity#982483 Dereference after null check

Change-Id: I6098e597cb00fccff4cf4611a8ac82badf1bdf02
This commit is contained in:
Caolán McNamara
2014-11-16 20:14:37 +00:00
parent d7df2dbc65
commit 8877a2fbf5

View File

@@ -4064,21 +4064,24 @@ void SwEditWin::MouseMove(const MouseEvent& _rMEvt)
bool bIsSelectionGfx = rSh.GetSelectionType() & nsSelectionType::SEL_GRF;
bool bisResize = eSdrMoveHdl != HDL_MOVE;
if ( rMEvt.IsShift() )
if (pSdrView)
{
pSdrView->SetAngleSnapEnabled(!bIsSelectionGfx);
if (bisResize)
pSdrView->SetOrtho(!bIsSelectionGfx);
if (rMEvt.IsShift())
{
pSdrView->SetAngleSnapEnabled(!bIsSelectionGfx);
if (bisResize)
pSdrView->SetOrtho(!bIsSelectionGfx);
else
pSdrView->SetOrtho(true);
}
else
pSdrView->SetOrtho(true);
}
else
{
pSdrView->SetAngleSnapEnabled(bIsSelectionGfx);
if (bisResize)
pSdrView->SetOrtho(bIsSelectionGfx);
else
pSdrView->SetOrtho(false);
{
pSdrView->SetAngleSnapEnabled(bIsSelectionGfx);
if (bisResize)
pSdrView->SetOrtho(bIsSelectionGfx);
else
pSdrView->SetOrtho(false);
}
}
rSh.Drag( &aDocPt, rMEvt.IsShift() );