From d7855213ae60d79fc51d8b9bfe49f13200137c05 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 15 Apr 2020 13:52:37 +0200 Subject: add an IsEmpty method to tools::Size and use it Change-Id: I7f5201e2ea6c74329336e16bf219630e38ff92cf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92264 Tested-by: Jenkins Reviewed-by: Noel Grandin --- framework/source/uielement/imagebuttontoolbarcontroller.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'framework/source/uielement') diff --git a/framework/source/uielement/imagebuttontoolbarcontroller.cxx b/framework/source/uielement/imagebuttontoolbarcontroller.cxx index 3d9997aaaa57..340999620c68 100644 --- a/framework/source/uielement/imagebuttontoolbarcontroller.cxx +++ b/framework/source/uielement/imagebuttontoolbarcontroller.cxx @@ -130,7 +130,7 @@ bool ImageButtonToolbarController::ReadImageFromURL( bool bBigImage, const OUStr const ::Size aSize = bBigImage ? aImageSizeBig : aImageSizeSmall; // Sizes used for toolbar images ::Size aBmpSize = aBitmapEx.GetSizePixel(); - if ( aBmpSize.Width() > 0 && aBmpSize.Height() > 0 ) + if ( !aBmpSize.IsEmpty() ) { ::Size aNoScaleSize( aBmpSize.Width(), aSize.Height() ); if ( aBmpSize != aNoScaleSize ) -- cgit