summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
Diffstat (limited to 'sd')
-rw-r--r--sd/source/ui/view/frmview.cxx20
1 files changed, 16 insertions, 4 deletions
diff --git a/sd/source/ui/view/frmview.cxx b/sd/source/ui/view/frmview.cxx
index 470866dffd38..8f48aeca2f1f 100644
--- a/sd/source/ui/view/frmview.cxx
+++ b/sd/source/ui/view/frmview.cxx
@@ -874,19 +874,31 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
}
else if ( pValue->Name == sUNO_View_GridSnapWidthXNumerator )
{
- pValue->Value >>= aSnapGridWidthXNum;
+ sal_Int32 nValue = 0;
+ pValue->Value >>= nValue;
+ if (nValue != 0) // 0 is allowed, but it doesn't make any sense...
+ aSnapGridWidthXNum = nValue;
}
else if ( pValue->Name == sUNO_View_GridSnapWidthXDenominator )
{
- pValue->Value >>= aSnapGridWidthXDom;
+ sal_Int32 nValue = 0;
+ pValue->Value >>= nValue;
+ if (nValue != 0)
+ aSnapGridWidthXDom = nValue;
}
else if ( pValue->Name == sUNO_View_GridSnapWidthYNumerator )
{
- pValue->Value >>= aSnapGridWidthYNum;
+ sal_Int32 nValue = 0;
+ pValue->Value >>= nValue;
+ if (nValue != 0) // 0 is allowed, but it doesn't make any sense...
+ aSnapGridWidthYNum = nValue;
}
else if ( pValue->Name == sUNO_View_GridSnapWidthYDenominator )
{
- pValue->Value >>= aSnapGridWidthYDom;
+ sal_Int32 nValue = 0;
+ pValue->Value >>= nValue;
+ if (nValue != 0)
+ aSnapGridWidthYDom = nValue;
}
else if (!bImpress && pValue->Name == sUNO_View_VisibleLayers )
{