diff --git a/messageviewer/src/header/grantleeheaderstyle.cpp b/messageviewer/src/header/grantleeheaderstyle.cpp index 71e8adbe..cc9bfed5 100644 --- a/messageviewer/src/header/grantleeheaderstyle.cpp +++ b/messageviewer/src/header/grantleeheaderstyle.cpp @@ -1,79 +1,73 @@ /* Copyright (C) 2013-2018 Laurent Montel This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #include "grantleeheaderstyle.h" #include "header/grantleeheaderformatter.h" #include "header/headerstrategy.h" #include "grantleetheme/grantleetheme.h" #include using namespace MessageViewer; class MessageViewer::GrantleeHeaderStylePrivate { public: GrantleeHeaderStylePrivate() { mGrantleeFormatter = new GrantleeHeaderFormatter; } ~GrantleeHeaderStylePrivate() { delete mGrantleeFormatter; } GrantleeHeaderFormatter *mGrantleeFormatter = nullptr; - bool mShowMailAction = true; }; GrantleeHeaderStyle::GrantleeHeaderStyle() : HeaderStyle() , d(new MessageViewer::GrantleeHeaderStylePrivate) { } GrantleeHeaderStyle::~GrantleeHeaderStyle() { delete d; } const char *GrantleeHeaderStyle::name() const { return "grantlee"; } QString GrantleeHeaderStyle::format(KMime::Message *message) const { if (!message) { return QString(); } GrantleeHeaderFormatter::GrantleeHeaderFormatterSettings settings; settings.isPrinting = isPrinting(); settings.theme = theme(); settings.style = this; settings.message = message; settings.showEmoticons = showEmoticons(); return d->mGrantleeFormatter->toHtml(settings); } - -bool GrantleeHeaderStyle::showMailAction() const -{ - return d->mShowMailAction; -} diff --git a/messageviewer/src/header/grantleeheaderstyle.h b/messageviewer/src/header/grantleeheaderstyle.h index df977d08..37100cbf 100644 --- a/messageviewer/src/header/grantleeheaderstyle.h +++ b/messageviewer/src/header/grantleeheaderstyle.h @@ -1,44 +1,41 @@ /* Copyright (C) 2013-2018 Laurent Montel This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #ifndef GRANTLEEHEADERSTYLE_H #define GRANTLEEHEADERSTYLE_H #include "messageviewer/headerstyle.h" namespace MessageViewer { class GrantleeHeaderStylePrivate; class MESSAGEVIEWER_EXPORT GrantleeHeaderStyle : public HeaderStyle { public: GrantleeHeaderStyle(); ~GrantleeHeaderStyle() override; public: const char *name() const override; QString format(KMime::Message *message) const override; - - bool showMailAction() const; - void setShowMailAction(bool showAction); private: GrantleeHeaderStylePrivate *const d; }; } #endif // GRANTLEEHEADERSTYLE_H diff --git a/messageviewer/src/messageviewerheaderplugins/defaultgrantleeheaderstyleplugin/theme/5.2/header.html b/messageviewer/src/messageviewerheaderplugins/defaultgrantleeheaderstyleplugin/theme/5.2/header.html index aa19d7b9..b6a021e0 100644 --- a/messageviewer/src/messageviewerheaderplugins/defaultgrantleeheaderstyleplugin/theme/5.2/header.html +++ b/messageviewer/src/messageviewerheaderplugins/defaultgrantleeheaderstyleplugin/theme/5.2/header.html @@ -1,90 +1,71 @@
- {% if header.showMailAction %} - {% if header.screenmode %} -
-
-
{{ header.newmessageaction|safe }}
-
{{ header.printpreviewmessageaction|safe }}
-
{{ header.printmessageaction|safe }}
-
-
{{ header.replyaction|safe }}
-
{{ header.replyallaction|safe }}
-
{{ header.forwardaction|safe }}
- {% if header.readOnlyMessage %} - {% else %} -
{{ header.trashaction|safe }}
- {% endif %} -
-
- {% endif %} - {% endif %}
{{ header.subject|safe }}
{% if header.photourl %} {% else %} {% endif %}
{{ header.fromi18n }}
{{ header.from|safe }} {% if header.resentfrom %} {{ header.resentfromi18n }}: {{ header.resentfrom|safe }} {% endif %} {% if header.vcardname %} {{ header.vcardi18n }} {% endif %} {% if header.organization %} ({{ header.organization|safe }}) {% endif %}
{% if header.to %}
{{ header.toi18n }}
{{ header.toExpandable|safe }}
{% endif %} {% if header.cc %}
{{ header.cci18n }}
{{ header.ccExpandable|safe }}
{% endif %} {% if header.bcc %}
{{ header.bcci18n }}
{{ header.bcc|safe }}
{% endif %} {% if header.sender %}
{{ header.senderi18n }}
{{ header.sender|safe }}
{% endif %} {% if header.listid %}
{{ header.listidi18n }}
{{ header.listid }}
{% endif %}
{{ header.datei18n }}
{{ header.dateshort }}
{% if header.spamHTML %}
{{ header.spamstatusi18n }}
{{ header.spamHTML|safe }}
{% endif %}
{{ header.attachmentHtml|safe }}