From 34856077702907aed5568ff3d4b98888ced37edf Mon Sep 17 00:00:00 2001 From: Cédric Bosdonnat Date: Mon, 14 Jan 2013 16:50:03 +0100 Subject: Template Manager: show folders with 4 previews inside a rounded rect The previous display had the inconvenient to be misleading if there was one or no template inside a folder. Change-Id: I16faa2556ca02380bd4dac0d821ecac45b98b8c3 Reviewed-on: https://gerrit.libreoffice.org/1678 Reviewed-by: Noel Power Tested-by: Noel Power --- sfx2/inc/sfx2/templatecontaineritem.hxx | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'sfx2/inc') diff --git a/sfx2/inc/sfx2/templatecontaineritem.hxx b/sfx2/inc/sfx2/templatecontaineritem.hxx index 2c2d18bafb51..476860433c47 100644 --- a/sfx2/inc/sfx2/templatecontaineritem.hxx +++ b/sfx2/inc/sfx2/templatecontaineritem.hxx @@ -18,19 +18,26 @@ class TemplateContainerItem : public ThumbnailViewItem public: BitmapEx maPreview2; + BitmapEx maPreview3; + BitmapEx maPreview4; std::vector maTemplates; TemplateContainerItem (ThumbnailView &rView); virtual ~TemplateContainerItem (); - const Point& getPrev2Pos () const { return maPrev2Pos; } - virtual void Paint (drawinglayer::processor2d::BaseProcessor2D *pProcessor, const ThumbnailItemAttributes *pAttrs); + + virtual void calculateItemsPosition (const long nThumbnailHeight, const long nDisplayHeight, + const long nPadding, sal_uInt32 nMaxTextLenght, + const ThumbnailItemAttributes *pAttrs); + + bool HasMissingPreview( ); + private: - Point maPrev2Pos; + Rectangle maThumbnailArea; }; #endif // TEMPLATEFOLDERVIEWITEM_HXX -- cgit