1 /* -*- mode: C++; c-file-style: "gnu" -*-
2 Copyright (c) 2009 Montel Laurent <montel@kde.org>
4 This program is free software; you can redistribute it and/or modify it
5 under the terms of the GNU General Public License, version 2, as
6 published by the Free Software Foundation.
8 This program is distributed in the hope that it will be useful, but
9 WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 General Public License for more details.
13 You should have received a copy of the GNU General Public License along
14 with this program; if not, write to the Free Software Foundation, Inc.,
15 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 #ifndef MAILCOMMON_COLLECTIONGENERALPAGE_H
19 #define MAILCOMMON_COLLECTIONGENERALPAGE_H
21 #include "mailcommon_export.h"
23 #include <Akonadi/CollectionPropertiesPage>
30 template <typename T
> class QSharedPointer
;
32 namespace KPIMIdentities
{
36 namespace MailCommon
{
38 class FolderCollection
;
40 class MAILCOMMON_EXPORT CollectionGeneralPage
: public Akonadi::CollectionPropertiesPage
45 explicit CollectionGeneralPage( QWidget
*parent
= 0 );
46 ~CollectionGeneralPage();
48 void load( const Akonadi::Collection
&collection
);
49 void save( Akonadi::Collection
&collection
);
51 enum FolderContentsType
{
58 ContentsTypeLast
= ContentsTypeJournal
68 void init( const Akonadi::Collection
& );
71 void slotIdentityCheckboxChanged();
72 void slotFolderContentsSelectionChanged( int );
73 void slotNameChanged( const QString
&name
);
76 KComboBox
*mContentsComboBox
;
77 KComboBox
*mIncidencesForComboBox
;
78 QCheckBox
*mSharedSeenFlagsCheckBox
;
80 QCheckBox
*mNewMailCheckBox
;
82 QCheckBox
*mNotifyOnNewMailCheckBox
;
83 QCheckBox
*mKeepRepliesInSameFolderCheckBox
;
84 QCheckBox
*mHideInSelectionDialogCheckBox
;
85 QCheckBox
*mUseDefaultIdentityCheckBox
;
87 KPIMIdentities::IdentityCombo
*mIdentityComboBox
;
88 QSharedPointer
<MailCommon::FolderCollection
> mFolderCollection
;
89 bool mIsLocalSystemFolder
;
90 bool mIsResourceFolder
;
93 AKONADI_COLLECTION_PROPERTIES_PAGE_FACTORY( CollectionGeneralPageFactory
, CollectionGeneralPage
)