Kaydet (Commit) f88b9503 authored tarafından Julien Nabet's avatar Julien Nabet

Revert tdf#120782, tdf#120728, tdf#120152, tdf#120151

The first fixes were wrong and only brought some regression

Change-Id: I5e47393b454ca9dc73d87ac4277fa48a3d8bf38d
Reviewed-on: https://gerrit.libreoffice.org/62530
Tested-by: Jenkins
Reviewed-by: 's avatarJulien Nabet <serval2412@yahoo.fr>
üst db7f8a8e
...@@ -95,8 +95,6 @@ public: ...@@ -95,8 +95,6 @@ public:
sal_uInt16 _nControlObjectID, sal_uInt16 _nControlObjectID,
SdrInventor _nInventor, SdrInventor _nInventor,
sal_uInt16 _nLabelObjectID, sal_uInt16 _nLabelObjectID,
SdrPage* _pLabelPage,
SdrPage* _pControlPage,
// tdf#118963 Need a SdrModel for SdrObject creation. To make the // tdf#118963 Need a SdrModel for SdrObject creation. To make the
// demand clear, hand over a SdrMldel& // demand clear, hand over a SdrMldel&
......
...@@ -3147,8 +3147,6 @@ void OReportController::createControl(const Sequence< PropertyValue >& _aArgs,co ...@@ -3147,8 +3147,6 @@ void OReportController::createControl(const Sequence< PropertyValue >& _aArgs,co
_nObjectId, _nObjectId,
SdrInventor::ReportDesign, SdrInventor::ReportDesign,
OBJ_DLG_FIXEDTEXT, OBJ_DLG_FIXEDTEXT,
pSectionWindow->getReportSection().getPage(),
pSectionWindow->getReportSection().getPage(),
// tdf#118963 Need a SdrModel for SdrObject creation. Dereferencing // tdf#118963 Need a SdrModel for SdrObject creation. Dereferencing
// m_aReportModel seems pretty safe, it's done in other places, initialized // m_aReportModel seems pretty safe, it's done in other places, initialized
...@@ -3456,8 +3454,6 @@ void OReportController::addPairControls(const Sequence< PropertyValue >& aArgs) ...@@ -3456,8 +3454,6 @@ void OReportController::addPairControls(const Sequence< PropertyValue >& aArgs)
nOBJID, nOBJID,
SdrInventor::ReportDesign, SdrInventor::ReportDesign,
OBJ_DLG_FIXEDTEXT, OBJ_DLG_FIXEDTEXT,
pSectionWindow[1]->getReportSection().getPage(),
pSectionWindow[0]->getReportSection().getPage(),
// tdf#118963 Need a SdrModel for SdrObject creation. Dereferencing // tdf#118963 Need a SdrModel for SdrObject creation. Dereferencing
// m_aReportModel seems pretty safe, it's done in other places, initialized // m_aReportModel seems pretty safe, it's done in other places, initialized
......
...@@ -353,7 +353,6 @@ void OReportSection::Copy(uno::Sequence< beans::NamedValue >& _rAllreadyCopiedOb ...@@ -353,7 +353,6 @@ void OReportSection::Copy(uno::Sequence< beans::NamedValue >& _rAllreadyCopiedOb
try try
{ {
SdrObject* pNewObj(pSdrObject->CloneSdrObject(pSdrObject->getSdrModelFromSdrObject())); SdrObject* pNewObj(pSdrObject->CloneSdrObject(pSdrObject->getSdrModelFromSdrObject()));
m_pPage->NbcInsertObject(pNewObj);
aCopies.emplace_back(pNewObj->getUnoShape(),uno::UNO_QUERY); aCopies.emplace_back(pNewObj->getUnoShape(),uno::UNO_QUERY);
if ( _bEraseAnddNoClone ) if ( _bEraseAnddNoClone )
{ {
......
...@@ -565,7 +565,7 @@ FmFormObj* FmFormView::getMarkedGrid() const ...@@ -565,7 +565,7 @@ FmFormObj* FmFormView::getMarkedGrid() const
void FmFormView::createControlLabelPair( OutputDevice const * _pOutDev, sal_Int32 _nXOffsetMM, sal_Int32 _nYOffsetMM, void FmFormView::createControlLabelPair( OutputDevice const * _pOutDev, sal_Int32 _nXOffsetMM, sal_Int32 _nYOffsetMM,
const Reference< XPropertySet >& _rxField, const Reference< XNumberFormats >& _rxNumberFormats, const Reference< XPropertySet >& _rxField, const Reference< XNumberFormats >& _rxNumberFormats,
sal_uInt16 _nControlObjectID, SdrInventor _nInventor, sal_uInt16 _nLabelObjectID, sal_uInt16 _nControlObjectID, SdrInventor _nInventor, sal_uInt16 _nLabelObjectID,
SdrPage* _pLabelPage, SdrPage* _pControlPage, SdrModel& _rModel, SdrModel& _rModel,
std::unique_ptr<SdrUnoObj, SdrObjectFreeOp>& _rpLabel, std::unique_ptr<SdrUnoObj, SdrObjectFreeOp>& _rpLabel,
std::unique_ptr<SdrUnoObj, SdrObjectFreeOp>& _rpControl ) std::unique_ptr<SdrUnoObj, SdrObjectFreeOp>& _rpControl )
{ {
...@@ -573,7 +573,7 @@ void FmFormView::createControlLabelPair( OutputDevice const * _pOutDev, sal_Int3 ...@@ -573,7 +573,7 @@ void FmFormView::createControlLabelPair( OutputDevice const * _pOutDev, sal_Int3
*_pOutDev, _nXOffsetMM, _nYOffsetMM, *_pOutDev, _nXOffsetMM, _nYOffsetMM,
_rxField, _rxNumberFormats, _rxField, _rxNumberFormats,
_nControlObjectID, "", _nInventor, _nLabelObjectID, _nControlObjectID, "", _nInventor, _nLabelObjectID,
_pLabelPage, _pControlPage, _rModel, _rModel,
_rpLabel, _rpControl _rpLabel, _rpControl
); );
} }
......
...@@ -1526,8 +1526,6 @@ bool FmXFormView::createControlLabelPair( OutputDevice const & _rOutDev, sal_Int ...@@ -1526,8 +1526,6 @@ bool FmXFormView::createControlLabelPair( OutputDevice const & _rOutDev, sal_Int
_rFieldPostfix, _rFieldPostfix,
SdrInventor::FmForm, SdrInventor::FmForm,
OBJ_FM_FIXEDTEXT, OBJ_FM_FIXEDTEXT,
getView()->GetSdrPageView()->GetPage(),
getView()->GetSdrPageView()->GetPage(),
// tdf#118963 Hand over a SdrModel to SdrObject-creation. It uses the local m_pView // tdf#118963 Hand over a SdrModel to SdrObject-creation. It uses the local m_pView
// and already returning false when nullptr == getView() could be done, but m_pView // and already returning false when nullptr == getView() could be done, but m_pView
...@@ -1559,7 +1557,7 @@ bool FmXFormView::createControlLabelPair( OutputDevice const & _rOutDev, sal_Int ...@@ -1559,7 +1557,7 @@ bool FmXFormView::createControlLabelPair( OutputDevice const & _rOutDev, sal_Int
const Reference< XPropertySet >& _rxField, const Reference< XPropertySet >& _rxField,
const Reference< XNumberFormats >& _rxNumberFormats, sal_uInt16 _nControlObjectID, const Reference< XNumberFormats >& _rxNumberFormats, sal_uInt16 _nControlObjectID,
const OUString& _rFieldPostfix, SdrInventor _nInventor, sal_uInt16 _nLabelObjectID, const OUString& _rFieldPostfix, SdrInventor _nInventor, sal_uInt16 _nLabelObjectID,
SdrPage* _pLabelPage, SdrPage* _pControlPage, SdrModel& _rModel, SdrModel& _rModel,
std::unique_ptr<SdrUnoObj, SdrObjectFreeOp>& _rpLabel, std::unique_ptr<SdrUnoObj, SdrObjectFreeOp>& _rpControl) std::unique_ptr<SdrUnoObj, SdrObjectFreeOp>& _rpLabel, std::unique_ptr<SdrUnoObj, SdrObjectFreeOp>& _rpControl)
{ {
sal_Int32 nDataType = 0; sal_Int32 nDataType = 0;
...@@ -1606,7 +1604,6 @@ bool FmXFormView::createControlLabelPair( OutputDevice const & _rOutDev, sal_Int ...@@ -1606,7 +1604,6 @@ bool FmXFormView::createControlLabelPair( OutputDevice const & _rOutDev, sal_Int
_rModel, _rModel,
_nInventor, _nInventor,
_nLabelObjectID))); _nLabelObjectID)));
_pLabelPage->NbcInsertObject(pLabel.get());
OSL_ENSURE(pLabel, "FmXFormView::createControlLabelPair: could not create the label!"); OSL_ENSURE(pLabel, "FmXFormView::createControlLabelPair: could not create the label!");
...@@ -1639,7 +1636,6 @@ bool FmXFormView::createControlLabelPair( OutputDevice const & _rOutDev, sal_Int ...@@ -1639,7 +1636,6 @@ bool FmXFormView::createControlLabelPair( OutputDevice const & _rOutDev, sal_Int
_rModel, _rModel,
_nInventor, _nInventor,
_nControlObjectID))); _nControlObjectID)));
_pControlPage->NbcInsertObject(pControl.get());
OSL_ENSURE(pControl, "FmXFormView::createControlLabelPair: could not create the control!"); OSL_ENSURE(pControl, "FmXFormView::createControlLabelPair: could not create the control!");
......
...@@ -263,8 +263,6 @@ private: ...@@ -263,8 +263,6 @@ private:
// tdf#118963 Need a SdrModel for SdrObject creation. To make the // tdf#118963 Need a SdrModel for SdrObject creation. To make the
// demand clear, hand over a SdrMldel& // demand clear, hand over a SdrMldel&
SdrPage* _pLabelPage,
SdrPage* _pControlPage,
SdrModel& _rModel, SdrModel& _rModel,
std::unique_ptr<SdrUnoObj, SdrObjectFreeOp>& _rpLabel, std::unique_ptr<SdrUnoObj, SdrObjectFreeOp>& _rpLabel,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment