[Libreoffice-commits] core.git: vcl/source
Thorsten Behrens (via logerrit)
logerrit at kemper.freedesktop.org
Sat Nov 21 14:21:37 UTC 2020
vcl/source/window/tabpage.cxx | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
New commits:
commit fdbc616f6dd01a5b34b98abb6317d6fe3894285c
Author: Thorsten Behrens <Thorsten.Behrens at CIB.de>
AuthorDate: Fri Nov 20 14:38:08 2020 +0100
Commit: Thorsten Behrens <Thorsten.Behrens at CIB.de>
CommitDate: Sat Nov 21 15:20:54 2020 +0100
Fix tdf#138373 scrollbars can now actually be nullptr
Change-Id: I224969de51a1d7e0176facb503a5b27cd8da530c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106265
Tested-by: Jenkins
Reviewed-by: Thorsten Behrens <Thorsten.Behrens at CIB.de>
diff --git a/vcl/source/window/tabpage.cxx b/vcl/source/window/tabpage.cxx
index 259b0085f12d..0ee256425709 100644
--- a/vcl/source/window/tabpage.cxx
+++ b/vcl/source/window/tabpage.cxx
@@ -259,7 +259,8 @@ void TabPage::SetScrollTop( tools::Long nTop )
{
Point aOld = mnScrollPos;
lcl_Scroll( mnScrollPos.X() , mnScrollPos.Y() - nTop );
- m_pHScroll->SetThumbPos( 0 );
+ if( m_pHScroll )
+ m_pHScroll->SetThumbPos( 0 );
// new pos is 0,0
mnScrollPos = aOld;
}
@@ -267,7 +268,8 @@ void TabPage::SetScrollLeft( tools::Long nLeft )
{
Point aOld = mnScrollPos;
lcl_Scroll( mnScrollPos.X() - nLeft , mnScrollPos.Y() );
- m_pVScroll->SetThumbPos( 0 );
+ if( m_pVScroll )
+ m_pVScroll->SetThumbPos( 0 );
// new pos is 0,0
mnScrollPos = aOld;
}
More information about the Libreoffice-commits
mailing list