summaryrefslogtreecommitdiff
path: root/svtools
diff options
context:
space:
mode:
authorMark Page <aptitude@btconnect.com>2016-12-06 07:55:14 +0000
committerNoel Grandin <noel.grandin@collabora.co.uk>2016-12-08 05:57:16 +0000
commitc54eb45230ef54c10e7a86d1c249ea42b07881fe (patch)
tree77bea288ada244da2552a6fce823e3ec0d63f276 /svtools
parentbcdaa1ffb5d8a107d687c797425550ab859d9041 (diff)
ImplWallpaper to use std::unique_ptr
Also remove ImplWallpaper::operator==, that does not make sense since members are unique Change-Id: I69d32d91ba33691eb1f86e70ce3c53fa2761e34b Reviewed-on: https://gerrit.libreoffice.org/31666 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svtools')
-rw-r--r--svtools/source/contnr/ivctrl.cxx7
1 files changed, 5 insertions, 2 deletions
diff --git a/svtools/source/contnr/ivctrl.cxx b/svtools/source/contnr/ivctrl.cxx
index 41f2296978e6..198184505a1e 100644
--- a/svtools/source/contnr/ivctrl.cxx
+++ b/svtools/source/contnr/ivctrl.cxx
@@ -338,9 +338,12 @@ void SvtIconChoiceCtrl::SetBackground( const Wallpaper& rPaper )
if( rPaper != GetBackground() )
{
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
- Wallpaper aEmpty;
- if( rPaper == aEmpty )
+ // if it is the default (empty) wallpaper
+ if( rPaper.GetStyle() == WallpaperStyle::NONE && rPaper.GetColor() == COL_TRANSPARENT &&
+ !rPaper.IsBitmap() && !rPaper.IsGradient() && !rPaper.IsRect())
+ {
Control::SetBackground( rStyleSettings.GetFieldColor() );
+ }
else
{
Wallpaper aBackground( rPaper );