Mailcommon
collectiongeneralpage.cpp
51 mIsLocalSystemFolder = CommonKernel->isSystemFolderCollection(collection) || Kernel::folderIsInbox(collection);
65 innerLayout->insertRow(0, i18nc("@label:textbox Name of the folder.", "Folder &Name:"), mNameEdit);
72 PimCommon::CollectionTypeUtil::FolderContentsType contentsType = PimCommon::CollectionTypeUtil::ContentsTypeMail;
74 const auto *annotationAttribute = collection.attribute<PimCommon::CollectionAnnotationsAttribute>();
76 const QMap<QByteArray, QByteArray> annotations = (annotationAttribute ? annotationAttribute->annotations() : QMap<QByteArray, QByteArray>());
78 const bool sharedSeen = (annotations.value(PimCommon::CollectionTypeUtil::kolabSharedSeen()) == "true");
82 collectionUtil.incidencesForFromString(QLatin1String(annotations.value(PimCommon::CollectionTypeUtil::kolabIncidencesFor())));
85 collectionUtil.typeFromKolabName(annotations.value(PimCommon::CollectionTypeUtil::kolabFolderType()));
91 connect(mContentsComboBox, &PimCommon::ContentTypeWidget::activated, this, &CollectionGeneralPage::slotFolderContentsSelectionChanged);
101 (folderType == PimCommon::CollectionTypeUtil::ContentsTypeCalendar || folderType == PimCommon::CollectionTypeUtil::ContentsTypeTask);
138 const auto *annotationsAttribute = collection.attribute<PimCommon::CollectionAnnotationsAttribute>();
144 mContentsComboBox->setCurrentItem(collectionUtil.typeNameFromKolabType(annotations[PimCommon::CollectionTypeUtil::kolabFolderType()]));
155 bool canRenameFolder = !(nameFolder.startsWith(QLatin1Char('.')) || nameFolder.endsWith(QLatin1Char('.')) || nameFolder.contains(QLatin1Char('/'))
160 Akonadi::AgentInstance instance = Akonadi::AgentManager::self()->instance(collection.resource());
174 auto *annotationsAttribute = collection.attribute<PimCommon::CollectionAnnotationsAttribute>(Collection::AddIfMissing);
178 annotations[PimCommon::CollectionTypeUtil::kolabSharedSeen()] = mSharedSeenFlagsCheckBox->isChecked() ? "true" : "false";
184 collectionUtil.incidencesForToString(static_cast<PimCommon::CollectionTypeUtil::IncidencesFor>(mIncidencesForComboBox->currentIndex())).toLatin1();
188 const PimCommon::CollectionTypeUtil::FolderContentsType type = collectionUtil.contentsTypeFromString(mContentsComboBox->currentText());
193 auto *attribute = collection.attribute<Akonadi::EntityDisplayAttribute>(Akonadi::Collection::AddIfMissing);
209 const PimCommon::CollectionTypeUtil::FolderContentsType type = collectionUtil.contentsTypeFromString(mContentsComboBox->currentText());
220 const bool enable = (type == PimCommon::CollectionTypeUtil::ContentsTypeCalendar || type == PimCommon::CollectionTypeUtil::ContentsTypeTask);
231 if (name.startsWith(QLatin1Char('.')) || name.endsWith(QLatin1Char('.')) || name.contains(QLatin1Char('/')) || name.trimmed().isEmpty()) {
currentText
void setWhatsThis(const QString &)
bool contains(const Key &key) const const
static QString labelName()
palette
void setPageTitle(const QString &title)
Type type(const QSqlDatabase &db)
NegativeBackground
QString displayName() const
void setCurrentIndex(int index)
styleSheet
void setChecked(bool)
void removeAttribute()
QString displayName() const
QMetaObject::Connection connect(const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
bool hasAttribute() const
AgentInstance instance(const QString &identifier) const
static QString labelName()
QString i18n(const char *text, const TYPE &arg...)
void setName(const QString &name)
void setText(const QString &)
void textChanged(const QString &text)
bool isEmpty() const const
const T * attribute() const
Collection & parentCollection()
static Collection root()
void setEnabled(bool)
void setIconName(const QString &name)
bool isEmpty() const const
void setObjectName(const QString &name)
const char * name(StandardAction id)
QString resource() const
QString i18nc(const char *context, const char *text, const TYPE &arg...)
static AgentManager * self()
AddIfMissing
void information(QWidget *parent, const QString &text, const QString &title=QString(), const QString &dontShowAgainName=QString(), Options options=Notify)
void activated(int index)
BackgroundRole
void setName(const QString &name)
void setText(const QString &text)
QString message
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Mar 27 2023 04:14:42 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Mar 27 2023 04:14:42 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.