┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/kitemviews/kfileitemmodelrolesupdater.h
diff options
context:
space:
mode:
authorPeter Penz <[email protected]>2012-04-06 23:06:05 +0200
committerPeter Penz <[email protected]>2012-04-06 23:12:07 +0200
commitdc555b8e56162bb908ad398341c5d7828d443bf3 (patch)
treebd2f5d817a466cc3ae56d54405ae92344a6a2cd5 /src/kitemviews/kfileitemmodelrolesupdater.h
parent5d27eb81cd038d1cf66f21efa24cb8c2ebd52557 (diff)
Allow to specify whether an upscaling of images should be done
The option is currently hidden as up to now only Nuno requested it, but it seems to be urgent: "my icon making productivity has drop subtantialy" ((c) 2012 Nuno) As I don't want to get blamed for an outdated Oxygen-icon-set I have no other choice ;-) CCMAIL: [email protected]
Diffstat (limited to 'src/kitemviews/kfileitemmodelrolesupdater.h')
-rw-r--r--src/kitemviews/kfileitemmodelrolesupdater.h23
1 files changed, 20 insertions, 3 deletions
diff --git a/src/kitemviews/kfileitemmodelrolesupdater.h b/src/kitemviews/kfileitemmodelrolesupdater.h
index d22867511..e5e105e04 100644
--- a/src/kitemviews/kfileitemmodelrolesupdater.h
+++ b/src/kitemviews/kfileitemmodelrolesupdater.h
@@ -81,8 +81,16 @@ public:
* of the file. If \a show is false the MIME type icon will be used for the "iconPixmap"
* role.
*/
- void setPreviewShown(bool show);
- bool isPreviewShown() const;
+ void setPreviewsShown(bool show);
+ bool previewsShown() const;
+
+ /**
+ * If enabled a small preview gets upscaled to the icon size in case where
+ * the icon size is larger than the preview. Per default enlarging is
+ * enabled.
+ */
+ void setEnlargeSmallPreviews(bool enlarge);
+ bool enlargeSmallPreviews() const;
/**
* If \a paused is set to true the asynchronous resolving of roles will be paused.
@@ -187,6 +195,12 @@ private:
*/
int subItemsCount(const QString& path) const;
+ /**
+ * Must be invoked if a property has been changed that affects
+ * the look of the preview. Takes care to update all previews.
+ */
+ void updateAllPreviews();
+
private:
// Property for setPaused()/isPaused().
bool m_paused;
@@ -197,9 +211,12 @@ private:
bool m_iconSizeChangedDuringPausing;
bool m_rolesChangedDuringPausing;
- // Property for setPreviewShown()/previewShown().
+ // Property for setPreviewsShown()/previewsShown().
bool m_previewShown;
+ // Property for setEnlargeSmallPreviews()/enlargeSmallPreviews()
+ bool m_enlargeSmallPreviews;
+
// True if the role "iconPixmap" should be cleared when resolving the next
// role with resolveRole(). Is necessary if the preview gets disabled
// during the roles-updater has been paused by setPaused().