• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdepim API Reference
  • KDE Home
  • Contact Us
 

kmail

  • sources
  • kde-4.12
  • kdepim
  • kmail
  • editor
attachmentview.h
Go to the documentation of this file.
1 /*
2  * This file is part of KMail.
3  * Copyright (c) 2012 Laurent Montel <montel@kde.org>
4  * Copyright (c) 2009 Constantin Berzan <exit3219@gmail.com>
5  *
6  * Parts based on KMail code by:
7  * Copyright (c) 2003 Ingo Kloecker <kloecker@kde.org>
8  * Copyright (c) 2007 Thomas McGuire <Thomas.McGuire@gmx.net>
9  *
10  * This program is free software; you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation; either version 2 of the License, or
13  * (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the GNU General Public License along
21  * with this program; if not, write to the Free Software Foundation, Inc.,
22  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
23  */
24 
25 #ifndef KMAIL_ATTACHMENTVIEW_H
26 #define KMAIL_ATTACHMENTVIEW_H
27 
28 #include <QTreeView>
29 
30 class QContextMenuEvent;
31 
32 namespace MessageComposer {
33 class AttachmentModel;
34 }
35 
36 namespace KMail {
37 
38 class AttachmentView : public QTreeView
39 {
40  Q_OBJECT
41 
42 public:
44  explicit AttachmentView( MessageComposer::AttachmentModel *model, QWidget *parent = 0 );
45  ~AttachmentView();
46 
47  QWidget *widget();
48 
49 public slots:
51  void setEncryptEnabled( bool enabled );
52  void setSignEnabled( bool enabled );
53  void hideIfEmpty();
54  void selectNewAttachment();
55 
56  void updateAttachmentLabel();
57 
58 protected:
60  void startDrag( Qt::DropActions supportedActions );
61  /* reimpl */
62  void contextMenuEvent( QContextMenuEvent *event );
63  /* reimpl */
64  void keyPressEvent( QKeyEvent *event );
66  void dragEnterEvent( QDragEnterEvent *event );
67 
68 private Q_SLOTS:
69  void slotShowHideAttchementList(bool);
70 
71 private:
72  void saveHeaderState();
73  void restoreHeaderState();
74 
75 signals:
76  void contextMenuRequested();
77  void modified(bool);
78 
79 private:
80  class Private;
81  Private *const d;
82 };
83 
84 } // namespace KMail
85 
86 #endif // KMAIL_ATTACHMENTVIEW_H
KMail::AttachmentView::keyPressEvent
void keyPressEvent(QKeyEvent *event)
Definition: attachmentview.cpp:134
KMail::AttachmentView
Definition: attachmentview.h:38
KMail::AttachmentView::selectNewAttachment
void selectNewAttachment()
Definition: attachmentview.cpp:195
QWidget
KMail::AttachmentView::widget
QWidget * widget()
Definition: attachmentview.cpp:216
KMail::AttachmentView::contextMenuRequested
void contextMenuRequested()
KMail::AttachmentView::modified
void modified(bool)
QTreeView
KMail::AttachmentView::startDrag
void startDrag(Qt::DropActions supportedActions)
reimpl to avoid default drag cursor
Definition: attachmentview.cpp:203
KMail::AttachmentView::updateAttachmentLabel
void updateAttachmentLabel()
Definition: attachmentview.cpp:185
KMail::AttachmentView::setEncryptEnabled
void setEncryptEnabled(bool enabled)
model sets these
Definition: attachmentview.cpp:161
KMail::AttachmentView::AttachmentView
AttachmentView(MessageComposer::AttachmentModel *model, QWidget *parent=0)
can't change model afterwards.
Definition: attachmentview.cpp:79
KMail::AttachmentView::dragEnterEvent
void dragEnterEvent(QDragEnterEvent *event)
reimpl to avoid drags from ourselves
Definition: attachmentview.cpp:151
KMail::AttachmentView::setSignEnabled
void setSignEnabled(bool enabled)
Definition: attachmentview.cpp:166
KMail::AttachmentView::~AttachmentView
~AttachmentView()
Definition: attachmentview.cpp:109
KMail::AttachmentView::contextMenuEvent
void contextMenuEvent(QContextMenuEvent *event)
Definition: attachmentview.cpp:128
KMail::AttachmentView::hideIfEmpty
void hideIfEmpty()
Definition: attachmentview.cpp:171
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:58:51 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kmail

Skip menu "kmail"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members

kdepim API Reference

Skip menu "kdepim API Reference"
  • akonadi_next
  • akregator
  • blogilo
  • calendarsupport
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt2
  • kjots
  • kleopatra
  • kmail
  • knode
  • knotes
  • kontact
  • korgac
  • korganizer
  • ktimetracker
  • libkdepim
  • libkleo
  • libkpgp
  • mailcommon
  • messagelist
  • messageviewer

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal