Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
KMail
Commits
bfafaaf0
Commit
bfafaaf0
authored
Feb 08, 2021
by
Laurent Montel
😁
Browse files
Constify pointer
parent
f3a14f84
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/editor/attachment/attachmentview.cpp
View file @
bfafaaf0
...
...
@@ -38,23 +38,23 @@ using namespace KMail;
AttachmentView
::
AttachmentView
(
MessageComposer
::
AttachmentModel
*
model
,
QWidget
*
parent
)
:
QTreeView
(
parent
)
,
mModel
(
model
)
,
mToolButton
(
new
QToolButton
(
this
))
,
mInfoAttachment
(
new
QLabel
(
this
))
,
mWidget
(
new
QWidget
())
,
grp
(
KMKernel
::
self
()
->
config
()
->
group
(
"AttachmentView"
))
{
mWidget
=
new
QWidget
();
auto
lay
=
new
QHBoxLayout
(
mWidget
);
lay
->
setContentsMargins
({});
mToolButton
=
new
QToolButton
;
connect
(
mToolButton
,
&
QAbstractButton
::
toggled
,
this
,
&
AttachmentView
::
slotShowHideAttchementList
);
mToolButton
->
setIcon
(
QIcon
::
fromTheme
(
QStringLiteral
(
"mail-attachment"
)));
mToolButton
->
setAutoRaise
(
true
);
mToolButton
->
setCheckable
(
true
);
lay
->
addWidget
(
mToolButton
);
mInfoAttachment
=
new
QLabel
;
mInfoAttachment
->
setContentsMargins
({});
mInfoAttachment
->
setTextFormat
(
Qt
::
PlainText
);
lay
->
addWidget
(
mInfoAttachment
);
mModel
=
model
;
connect
(
model
,
&
MessageComposer
::
AttachmentModel
::
encryptEnabled
,
this
,
&
AttachmentView
::
setEncryptEnabled
);
connect
(
model
,
&
MessageComposer
::
AttachmentModel
::
signEnabled
,
this
,
&
AttachmentView
::
setSignEnabled
);
...
...
src/editor/attachment/attachmentview.h
View file @
bfafaaf0
...
...
@@ -64,10 +64,10 @@ Q_SIGNALS:
void
modified
(
bool
);
private:
MessageComposer
::
AttachmentModel
*
mModel
=
nullptr
;
QToolButton
*
mToolButton
=
nullptr
;
QLabel
*
mInfoAttachment
=
nullptr
;
QWidget
*
mWidget
=
nullptr
;
MessageComposer
::
AttachmentModel
*
const
mModel
;
QToolButton
*
const
mToolButton
;
QLabel
*
const
mInfoAttachment
;
QWidget
*
const
mWidget
;
KConfigGroup
grp
;
};
}
// namespace KMail
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment