Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit 832fbe96 authored by Laurent Montel's avatar Laurent Montel 😁

Read gravatar config

parent 0e4a7e6b
......@@ -37,6 +37,7 @@
#include "viewer/mimeparttree/mimeparttreeview.h"
#include "widgets/openattachmentfolderwidget.h"
#include "pimcommon/widgets/slidecontainer.h"
#include "pimcommon/gravatar/gravatarcache.h"
#include "messageviewer/job/attachmentencryptwithchiasmusjob.h"
#include "messageviewer/job/attachmenteditjob.h"
#include "messageviewer/job/modifymessagedisplayformatjob.h"
......@@ -1143,6 +1144,7 @@ void ViewerPrivate::readConfig()
mZoomTextOnly = GlobalSettings::self()->zoomTextOnly();
setZoomTextOnly( mZoomTextOnly );
readGravatarConfig();
if (headerStrategy() )
headerStrategy()->readConfig();
......@@ -1176,6 +1178,14 @@ void ViewerPrivate::readConfig()
mColorBar->update();
}
void ViewerPrivate::readGravatarConfig()
{
PimCommon::GravatarCache::self()->setMaximumSize(GlobalSettings::self()->gravatarCacheSize());
if (!GlobalSettings::self()->gravatarSupportEnabled()) {
PimCommon::GravatarCache::self()->clear();
}
}
void ViewerPrivate::slotGeneralFontChanged()
{
delete mCSSHelper;
......
......@@ -628,6 +628,7 @@ private:
QString recipientsQuickListLinkHtml( bool, const QString & ) const;
void initGrantleeThemeName();
void readGravatarConfig();
public:
NodeHelper* mNodeHelper;
bool mHtmlMailGlobalSetting, mHtmlLoadExternalGlobalSetting, mHtmlLoadExtOverride;
......
......@@ -26,7 +26,7 @@ using namespace PimCommon;
K_GLOBAL_STATIC( GravatarCache, s_gravatarCache )
GravatarCache::GravatarCache()
: mMaximumSize(30)
: mMaximumSize(20)
{
mCachePixmap.setMaxCost(mMaximumSize);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment