Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
PIM
KOrganizer
Commits
027424e0
Commit
027424e0
authored
Nov 04, 2020
by
Laurent Montel
😁
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Modernize code
parent
0d7861ba
Pipeline
#39458
passed with stage
in 18 minutes and 7 seconds
Changes
10
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
18 additions
and
18 deletions
+18
-18
korgac/alarmdialog.h
korgac/alarmdialog.h
+1
-1
src/calendarview.cpp
src/calendarview.cpp
+1
-1
src/datenavigatorcontainer.cpp
src/datenavigatorcontainer.cpp
+1
-1
src/interfaces/korganizer/part.h
src/interfaces/korganizer/part.h
+1
-1
src/kontactplugin/korganizer/summaryeventinfo.h
src/kontactplugin/korganizer/summaryeventinfo.h
+1
-1
src/korganizer.h
src/korganizer.h
+2
-2
src/views/collectionview/autotests/reparentingmodeltest.cpp
src/views/collectionview/autotests/reparentingmodeltest.cpp
+1
-1
src/views/collectionview/reparentingmodel.cpp
src/views/collectionview/reparentingmodel.cpp
+6
-6
src/views/collectionview/reparentingmodel.h
src/views/collectionview/reparentingmodel.h
+2
-2
src/widgets/kdatenavigator.cpp
src/widgets/kdatenavigator.cpp
+2
-2
No files found.
korgac/alarmdialog.h
View file @
027424e0
...
...
@@ -94,7 +94,7 @@ private Q_SLOTS:
private:
void
update
();
void
updateButtons
();
typedef
QList
<
ReminderTreeItem
*>
ReminderList
;
using
ReminderList
=
QList
<
ReminderTreeItem
*>
;
static
Q_REQUIRED_RESULT
QDateTime
triggerDateForIncidence
(
const
KCalendarCore
::
Incidence
::
Ptr
&
inc
,
const
QDateTime
&
reminderAt
,
QString
&
displayStr
);
...
...
src/calendarview.cpp
View file @
027424e0
...
...
@@ -361,7 +361,7 @@ QDate CalendarView::activeIncidenceDate()
}
}
return
QDate
()
;
return
{}
;
}
QDate
CalendarView
::
startDate
()
...
...
src/datenavigatorcontainer.cpp
View file @
027424e0
...
...
@@ -351,7 +351,7 @@ QDate DateNavigatorContainer::monthOfNavigator(int navigatorIndex) const
if
(
navigatorIndex
<=
mExtraViews
.
count
()
&&
navigatorIndex
>=
0
)
{
return
mExtraViews
[
navigatorIndex
-
1
]
->
month
();
}
else
{
return
QDate
()
;
return
{}
;
}
}
...
...
src/interfaces/korganizer/part.h
View file @
027424e0
...
...
@@ -31,7 +31,7 @@ public:
return
QStringLiteral
(
"KOrganizer/Part"
);
}
typedef
QList
<
Part
*>
List
;
using
List
=
QList
<
Part
*>
;
explicit
Part
(
MainWindow
*
parent
)
:
KParts
::
Part
(
parent
?
(
parent
->
topLevelWidget
())
:
nullptr
)
...
...
src/kontactplugin/korganizer/summaryeventinfo.h
View file @
027424e0
...
...
@@ -18,7 +18,7 @@ class SummaryEventInfo
{
public:
typedef
QList
<
SummaryEventInfo
*>
List
;
using
List
=
QList
<
SummaryEventInfo
*>
;
SummaryEventInfo
();
...
...
src/korganizer.h
View file @
027424e0
...
...
@@ -21,8 +21,8 @@
class
CalendarView
;
// Workaround for moc workaround for visual c++ 6.0 sucking
typedef
KOrg
::
MainWindow
KOrgMainWindow
;
typedef
KParts
::
MainWindow
KPartsMainWindow
;
using
KOrgMainWindow
=
KOrg
::
MainWindow
;
using
KPartsMainWindow
=
KParts
::
MainWindow
;
/**
This is the main class for KOrganizer. It extends the KDE KMainWindow.
...
...
src/views/collectionview/autotests/reparentingmodeltest.cpp
View file @
027424e0
...
...
@@ -152,7 +152,7 @@ QModelIndex getIndex(const char *string, const QAbstractItemModel &model)
=
model
.
match
(
model
.
index
(
0
,
0
),
Qt
::
DisplayRole
,
QString
::
fromLatin1
(
string
),
1
,
Qt
::
MatchRecursive
);
if
(
list
.
isEmpty
())
{
return
QModelIndex
()
;
return
{}
;
}
return
list
.
first
();
}
...
...
src/views/collectionview/reparentingmodel.cpp
View file @
027424e0
...
...
@@ -608,7 +608,7 @@ ReparentingModel::Node *ReparentingModel::extractNode(const QModelIndex &index)
QModelIndex
ReparentingModel
::
index
(
int
row
,
int
column
,
const
QModelIndex
&
parent
)
const
{
if
(
row
<
0
||
column
!=
0
)
{
return
QModelIndex
()
;
return
{}
;
}
// qCDebug(KORGANIZER_LOG) << parent << row;
const
Node
*
parentNode
;
...
...
@@ -630,7 +630,7 @@ QModelIndex ReparentingModel::index(int row, int column, const QModelIndex &pare
QModelIndex
ReparentingModel
::
mapToSource
(
const
QModelIndex
&
idx
)
const
{
if
(
!
idx
.
isValid
()
||
!
sourceModel
())
{
return
QModelIndex
()
;
return
{}
;
}
Node
*
node
=
extractNode
(
idx
);
if
(
!
node
->
isSourceNode
())
{
...
...
@@ -655,7 +655,7 @@ QModelIndex ReparentingModel::mapFromSource(const QModelIndex &sourceIndex) cons
{
// qCDebug(KORGANIZER_LOG) << sourceIndex << sourceIndex.data().toString();
if
(
!
sourceIndex
.
isValid
())
{
return
QModelIndex
()
;
return
{}
;
}
Node
*
node
=
getSourceNode
(
sourceIndex
);
if
(
!
node
)
{
...
...
@@ -807,7 +807,7 @@ QModelIndex ReparentingModel::index(Node *node) const
{
const
int
r
=
row
(
node
);
if
(
r
<
0
)
{
return
QModelIndex
()
;
return
{}
;
}
return
createIndex
(
r
,
0
,
node
);
}
...
...
@@ -816,7 +816,7 @@ QModelIndex ReparentingModel::parent(const QModelIndex &child) const
{
// qCDebug(KORGANIZER_LOG) << child << child.data().toString();
if
(
!
child
.
isValid
())
{
return
QModelIndex
()
;
return
{}
;
}
const
Node
*
node
=
extractNode
(
child
);
return
index
(
node
->
parent
);
...
...
@@ -825,7 +825,7 @@ QModelIndex ReparentingModel::parent(const QModelIndex &child) const
QModelIndex
ReparentingModel
::
buddy
(
const
QModelIndex
&
index
)
const
{
if
(
!
index
.
isValid
()
||
!
sourceModel
())
{
return
QModelIndex
()
;
return
{}
;
}
Node
*
node
=
extractNode
(
index
);
if
(
node
->
isSourceNode
())
{
...
...
src/views/collectionview/reparentingmodel.h
View file @
027424e0
...
...
@@ -20,7 +20,7 @@ class ReparentingModel : public QAbstractProxyModel
Q_OBJECT
public:
struct
Node
{
typedef
QSharedPointer
<
Node
>
Ptr
;
using
Ptr
=
QSharedPointer
<
Node
>
;
virtual
~
Node
();
virtual
bool
operator
==
(
const
Node
&
)
const
;
...
...
@@ -51,7 +51,7 @@ public:
};
struct
NodeManager
{
typedef
QSharedPointer
<
NodeManager
>
Ptr
;
using
Ptr
=
QSharedPointer
<
NodeManager
>
;
NodeManager
(
ReparentingModel
&
m
)
:
model
(
m
)
{
...
...
src/widgets/kdatenavigator.cpp
View file @
027424e0
...
...
@@ -121,8 +121,8 @@ void KDateNavigator::setBaseDate(const QDate &date)
QSizePolicy
KDateNavigator
::
sizePolicy
()
const
{
return
QSizePolicy
(
QSizePolicy
::
MinimumExpanding
,
QSizePolicy
::
MinimumExpanding
)
;
return
{
QSizePolicy
::
MinimumExpanding
,
QSizePolicy
::
MinimumExpanding
}
;
}
void
KDateNavigator
::
updateToday
()
...
...
Write
Preview
Markdown
is supported
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