diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2021-09-07 12:16:24 +0200 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2022-02-23 16:00:28 +0100 |
commit | f4a62e5479b47d90d6de518f38a97ac0b5322c54 (patch) | |
tree | ff1a90880f5ed9de959a66b447b0b182c32fea94 /reportdesign | |
parent | 4751853b19dabfb57963c58183b0c3557328b3b8 (diff) |
SdrLayerID must be based on sal_Int16
... which is the type corresponding to the related published property
"LayerID" of com.sun.star.drawing.Shape service.
Without this, the code asserts on values passed to the published API
from external sources to be in the 8-bit limits, which is incorrect.
Change-Id: I0449a7dd313f7e6c4adbc1c1f7b8c50b6a51434e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121760
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'reportdesign')
-rw-r--r-- | reportdesign/source/core/api/ReportDefinition.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/reportdesign/source/core/api/ReportDefinition.cxx b/reportdesign/source/core/api/ReportDefinition.cxx index 636346a163c3..9954b50c359e 100644 --- a/reportdesign/source/core/api/ReportDefinition.cxx +++ b/reportdesign/source/core/api/ReportDefinition.cxx @@ -588,9 +588,9 @@ void OReportDefinition::init() m_pImpl->m_pReportModel->GetItemPool().FreezeIdRanges(); m_pImpl->m_pReportModel->SetScaleUnit( MapUnit::Map100thMM ); SdrLayerAdmin& rAdmin = m_pImpl->m_pReportModel->GetLayerAdmin(); - rAdmin.NewLayer("front", sal_uInt8(RPT_LAYER_FRONT)); - rAdmin.NewLayer("back", sal_uInt8(RPT_LAYER_BACK)); - rAdmin.NewLayer("HiddenLayer", sal_uInt8(RPT_LAYER_HIDDEN)); + rAdmin.NewLayer("front", RPT_LAYER_FRONT.get()); + rAdmin.NewLayer("back", RPT_LAYER_BACK.get()); + rAdmin.NewLayer("HiddenLayer", RPT_LAYER_HIDDEN.get()); m_pImpl->m_pUndoManager = new ::dbaui::UndoManager( *this, m_aMutex ); m_pImpl->m_pReportModel->SetSdrUndoManager( &m_pImpl->m_pUndoManager->GetSfxUndoManager() ); |