basctl/source/basicide/baside2b.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
New commits: commit 53c641702a280be8b80976301f3427b41d2e0b74 Author: Aman Jha <amanjha752...@gmail.com> AuthorDate: Mon Jan 9 19:34:40 2023 +0530 Commit: Ilmari Lauhakangas <ilmari.lauhakan...@libreoffice.org> CommitDate: Tue May 2 12:30:27 2023 +0200 tdf#114441 Convert sal_uLong to better integer types * Use tools::Long for nY as it stores calculations with result values that can be sometimes negative * Cast nLine to sal_uInt16 as rModulWindow.ToggleBreakPoint() takes parameter of type sal_uInt16 Change-Id: Ibfdee40f37714406ee0f089c9a87f8b9a650e492 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145210 Tested-by: Jenkins Reviewed-by: Hossein <hoss...@libreoffice.org> Tested-by: Ilmari Lauhakangas <ilmari.lauhakan...@libreoffice.org> Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakan...@libreoffice.org> diff --git a/basctl/source/basicide/baside2b.cxx b/basctl/source/basicide/baside2b.cxx index a82cf2ae4e4b..cf7e7388dd52 100644 --- a/basctl/source/basicide/baside2b.cxx +++ b/basctl/source/basicide/baside2b.cxx @@ -1476,7 +1476,7 @@ void BreakPointWindow::ShowMarker(vcl::RenderContext& rRenderContext) aMarkerOff.setX( (aOutSz.Width() - aMarkerSz.Width()) / 2 ); aMarkerOff.setY( (nLineHeight - aMarkerSz.Height()) / 2 ); - sal_uLong nY = nMarkerPos * nLineHeight - nCurYOffset; + tools::Long nY = nMarkerPos * nLineHeight - nCurYOffset; Point aPos(0, nY); aPos += aMarkerOff; @@ -1531,7 +1531,7 @@ void BreakPointWindow::MouseButtonDown( const MouseEvent& rMEvt ) { tools::Long nYPos = aMousePos.Y() + nCurYOffset; tools::Long nLine = nYPos / nLineHeight + 1; - rModulWindow.ToggleBreakPoint( static_cast<sal_uLong>(nLine) ); + rModulWindow.ToggleBreakPoint( static_cast<sal_uInt16>(nLine) ); Invalidate(); } }