summaryrefslogtreecommitdiff
path: root/reportdesign
diff options
context:
space:
mode:
authorOcke Janssen <oj@openoffice.org>2011-03-04 07:53:39 +0100
committerOcke Janssen <oj@openoffice.org>2011-03-04 07:53:39 +0100
commit1f1794f5d112fa931852f8cc8bc09bf01d2c3d95 (patch)
treefa6f6b518d8d9b9247a1932e4d7999b687801455 /reportdesign
parentdee1ea70160df84946cf9040281de42945faf65a (diff)
parent9a2ce2d264be1ee44ac8406b39e821f7752d6947 (diff)
Automated merge with file:///d:\tools\master\ooo
Diffstat (limited to 'reportdesign')
-rw-r--r--reportdesign/source/ui/report/ReportSection.cxx16
-rw-r--r--reportdesign/source/ui/report/dlgedfunc.cxx8
2 files changed, 14 insertions, 10 deletions
diff --git a/reportdesign/source/ui/report/ReportSection.cxx b/reportdesign/source/ui/report/ReportSection.cxx
index 632efedd579c..ce73fd270670 100644
--- a/reportdesign/source/ui/report/ReportSection.cxx
+++ b/reportdesign/source/ui/report/ReportSection.cxx
@@ -544,22 +544,22 @@ void OReportSection::_propertyChanged(const beans::PropertyChangeEvent& _rEvent)
else
{
uno::Reference<report::XReportDefinition> xReportDefinition = m_xSection->getReportDefinition();
+ const sal_Int32 nLeftMargin = getStyleProperty<sal_Int32>(xReportDefinition,PROPERTY_LEFTMARGIN);
+ const sal_Int32 nRightMargin = getStyleProperty<sal_Int32>(xReportDefinition,PROPERTY_RIGHTMARGIN);
+ const sal_Int32 nPaperWidth = getStyleProperty<awt::Size>(xReportDefinition,PROPERTY_PAPERSIZE).Width;
+
if ( _rEvent.PropertyName == PROPERTY_LEFTMARGIN )
{
- const sal_Int32 nLeftMargin = getStyleProperty<sal_Int32>(xReportDefinition,PROPERTY_LEFTMARGIN);
m_pPage->SetLftBorder(nLeftMargin);
}
else if ( _rEvent.PropertyName == PROPERTY_RIGHTMARGIN )
{
- const sal_Int32 nRightMargin = getStyleProperty<sal_Int32>(xReportDefinition,PROPERTY_RIGHTMARGIN);
m_pPage->SetRgtBorder(nRightMargin);
}
try
{
- const sal_Int32 nLeftMargin = getStyleProperty<sal_Int32>(xReportDefinition,PROPERTY_LEFTMARGIN);
- const sal_Int32 nRightMargin = getStyleProperty<sal_Int32>(xReportDefinition,PROPERTY_RIGHTMARGIN);
- const sal_Int32 nPaperWidth = getStyleProperty<awt::Size>(xReportDefinition,PROPERTY_PAPERSIZE).Width;
+ sal_Int32 nRightBorder = nPaperWidth - nRightMargin;
const sal_Int32 nCount = m_xSection->getCount();
for (sal_Int32 i = 0; i < nCount; ++i)
{
@@ -578,9 +578,9 @@ void OReportSection::_propertyChanged(const beans::PropertyChangeEvent& _rEvent)
aPos.X = nLeftMargin;
bChanged = true;
}
- if ( (aPos.X + aSize.Width) > (nPaperWidth - nRightMargin) )
+ if ( (aPos.X + aSize.Width) > nRightBorder )
{
- aPos.X = nPaperWidth - nRightMargin - aSize.Width;
+ aPos.X = nRightBorder - aSize.Width;
if ( aPos.X < nLeftMargin )
{
aSize.Width += aPos.X - nLeftMargin;
@@ -603,6 +603,8 @@ void OReportSection::_propertyChanged(const beans::PropertyChangeEvent& _rEvent)
aRet.setWidth(aRet.getWidth() + 1);
if ( m_xSection.is() && (static_cast<sal_uInt32>(aRet.getHeight() + aRet.Top()) > m_xSection->getHeight()) )
m_xSection->setHeight(aRet.getHeight() + aRet.Top());
+
+ pObject->RecalcBoundRect();
}
pBase->StartListening();
}
diff --git a/reportdesign/source/ui/report/dlgedfunc.cxx b/reportdesign/source/ui/report/dlgedfunc.cxx
index b17b68bdba4b..e4b317c1a5f4 100644
--- a/reportdesign/source/ui/report/dlgedfunc.cxx
+++ b/reportdesign/source/ui/report/dlgedfunc.cxx
@@ -451,6 +451,7 @@ void DlgEdFunc::activateOle(SdrObject* _pObj)
void DlgEdFunc::deactivateOle(bool _bSelect)
{
OLEObjCache& rObjCache = GetSdrGlobalData().GetOLEObjCache();
+ OReportController& rController = m_pParent->getSectionWindow()->getViewsWindow()->getView()->getReportView()->getController();
const sal_uLong nCount = rObjCache.Count();
for(sal_uLong i = 0 ; i< nCount;++i)
{
@@ -464,7 +465,6 @@ void DlgEdFunc::deactivateOle(bool _bSelect)
m_bUiActive = false;
if ( m_bShowPropertyBrowser )
{
- OReportController& rController = m_pParent->getSectionWindow()->getViewsWindow()->getView()->getReportView()->getController();
rController.executeChecked(SID_SHOW_PROPERTYBROWSER,uno::Sequence< beans::PropertyValue >());
}
@@ -639,15 +639,17 @@ bool DlgEdFunc::isRectangleHit(const MouseEvent& rMEvt)
if (pObjOverlapped && !m_bSelectionMode)
{
colorizeOverlappedObject(pObjOverlapped);
+ }
}
}
}
}
- }
- else if ( aVEvt.pObj && !m_bSelectionMode)
+ else if ( aVEvt.pObj && (aVEvt.pObj->GetObjIdentifier() != OBJ_CUSTOMSHAPE) && !m_bSelectionMode)
{
colorizeOverlappedObject(aVEvt.pObj);
}
+ else
+ bIsSetPoint = false;
return bIsSetPoint;
}
// -----------------------------------------------------------------------------