Commit 2373f612 authored by Laurent Montel's avatar Laurent Montel 😁

const'ify

parent f20a22d0
Pipeline #37408 passed with stage
in 15 minutes and 24 seconds
......@@ -201,9 +201,8 @@ AlarmDialog::AlarmDialog(const Akonadi::ETMCalendar::Ptr &calendar, QWidget *par
setMinimumSize(280, 160);
// take out some padding which makes it larger
topLayout->setSpacing(2);
QMargins margins(0, 0, 0, 0);
topLayout->setContentsMargins(margins);
setContentsMargins(margins);
topLayout->setContentsMargins({});
setContentsMargins({});
QLabel *label = new QLabel(
i18nc("@label",
......@@ -482,7 +481,7 @@ void AlarmDialog::dismiss(const ReminderList &selections)
void AlarmDialog::edit()
{
ReminderList selection = selectedItems();
const ReminderList selection = selectedItems();
if (selection.count() == 1) {
Incidence::Ptr incidence = CalendarSupport::incidence(selection.first()->mIncidence);
if (!mCalendar->hasRight(selection.first()->mIncidence,
......
......@@ -171,7 +171,7 @@ bool KOAlarmClient::collectionsAvailable() const
for (int row = 0; row < rowCount; ++row) {
static const int column = 0;
const QModelIndex index = mETM->index(row, column);
bool haveData
const bool haveData
= mETM->data(index, Akonadi::EntityTreeModel::IsPopulatedRole).toBool();
if (!haveData) {
return false;
......
......@@ -110,7 +110,7 @@ bool MailClient::mailAttendees(const KCalendarCore::IncidenceBase::Ptr &incidenc
QString subject;
if (incidence->type() != KCalendarCore::Incidence::TypeFreeBusy) {
KCalendarCore::Incidence::Ptr inc = incidence.staticCast<KCalendarCore::Incidence>();
const KCalendarCore::Incidence::Ptr inc = incidence.staticCast<KCalendarCore::Incidence>();
subject = inc->summary();
} else {
subject = i18n("Free Busy Object");
......@@ -129,7 +129,7 @@ bool MailClient::mailOrganizer(const KCalendarCore::IncidenceBase::Ptr &incidenc
QString subject = sub;
if (incidence->type() != KCalendarCore::Incidence::TypeFreeBusy) {
KCalendarCore::Incidence::Ptr inc = incidence.staticCast<KCalendarCore::Incidence>();
const KCalendarCore::Incidence::Ptr inc = incidence.staticCast<KCalendarCore::Incidence>();
if (subject.isEmpty()) {
subject = inc->summary();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment