summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAkshay Deep <akshaydeepiitr@gmail.com>2016-06-02 16:06:12 +0530
committerSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>2016-06-06 07:05:47 +0000
commita6ea18a9cc83a85f4bf4fce78b7dbef3d1a419c6 (patch)
tree0e455385028d6fd3c5ed00436081027e38ede7f7 /include
parent268a518a1ac1698a769dbce17e52ac99d7737ac4 (diff)
Mark Default Templates in Template Manager
Change-Id: I1dff486605efce09e862d2924b24949601ae0f17 Reviewed-on: https://gerrit.libreoffice.org/25816 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Diffstat (limited to 'include')
-rw-r--r--include/sfx2/templateabstractview.hxx4
-rw-r--r--include/sfx2/templateviewitem.hxx6
2 files changed, 10 insertions, 0 deletions
diff --git a/include/sfx2/templateabstractview.hxx b/include/sfx2/templateabstractview.hxx
index 5a7ddddb9e83..53641a73c632 100644
--- a/include/sfx2/templateabstractview.hxx
+++ b/include/sfx2/templateabstractview.hxx
@@ -112,6 +112,8 @@ public:
long getThumbnailWidth() const { return mnThumbnailWidth;}
long getThumbnailHeight() const {return mnThumbnailHeight;}
+ void RemoveDefaultTemplateIcon( OUString rPath);
+
static BitmapEx scaleImg (const BitmapEx &rImg, long width, long height);
static BitmapEx getDefaultThumbnail( const OUString& rPath );
@@ -122,6 +124,8 @@ protected:
virtual void OnItemDblClicked(ThumbnailViewItem *pItem) override;
+ bool IsDefaultTemplate(const OUString& rPath);
+
protected:
sal_uInt16 mnCurRegionId;
diff --git a/include/sfx2/templateviewitem.hxx b/include/sfx2/templateviewitem.hxx
index 180444ef9fb8..10d4634e4d52 100644
--- a/include/sfx2/templateviewitem.hxx
+++ b/include/sfx2/templateviewitem.hxx
@@ -24,6 +24,10 @@ public:
const OUString& getPath () const { return maPath; }
+ void showDefaultIcon(bool bVal) { mbIsDefaultTemplate = bVal; }
+
+ Rectangle getDefaultIconArea() const;
+
virtual void Paint (drawinglayer::processor2d::BaseProcessor2D *pProcessor,
const ThumbnailItemAttributes *pAttrs) override;
@@ -33,6 +37,8 @@ public:
private:
OUString maPath;
+ BitmapEx maDefaultBitmap;
+ bool mbIsDefaultTemplate;
};
#endif // INCLUDED_SFX2_TEMPLATEVIEWITEM_HXX