Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
Kalendar
Commits
ffd277a9
Commit
ffd277a9
authored
Oct 15, 2022
by
Claudio Cambra
Browse files
Move setters into slots for incidenceoccurrencemodel
Signed-off-by:
Claudio Cambra
<
claudio.cambra@gmail.com
>
parent
cc685b64
Pipeline
#248327
failed with stage
in 1 minute and 53 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/models/incidenceoccurrencemodel.h
View file @
ffd277a9
...
...
@@ -75,21 +75,12 @@ public:
~
IncidenceOccurrenceModel
()
override
=
default
;
int
rowCount
(
const
QModelIndex
&
parent
=
{})
const
override
;
QVariant
data
(
const
QModelIndex
&
index
,
int
role
)
const
override
;
void
updateQuery
();
Akonadi
::
ETMCalendar
::
Ptr
calendar
()
const
;
void
setCalendar
(
Akonadi
::
ETMCalendar
::
Ptr
calendar
);
void
setStart
(
const
QDate
&
start
);
QDate
start
()
const
;
void
setLength
(
int
length
);
int
length
()
const
;
Filter
*
filter
()
const
;
void
setFilter
(
Filter
*
filter
);
void
load
();
struct
Occurrence
{
QDateTime
start
;
...
...
@@ -106,12 +97,21 @@ Q_SIGNALS:
void
filterChanged
();
void
calendarChanged
();
public
Q_SLOTS
:
void
setStart
(
const
QDate
&
start
);
void
setLength
(
int
length
);
void
setFilter
(
Filter
*
filter
);
void
setCalendar
(
Akonadi
::
ETMCalendar
::
Ptr
calendar
);
private
Q_SLOTS
:
void
slotSourceDataChanged
(
const
QModelIndex
&
upperLeft
,
const
QModelIndex
&
bottomRight
);
void
slotSourceRowsInserted
(
const
QModelIndex
&
parent
,
const
int
first
,
const
int
last
);
void
load
();
void
refreshView
();
void
updateQuery
();
void
updateFromSource
();
void
slotSourceDataChanged
(
const
QModelIndex
&
upperLeft
,
const
QModelIndex
&
bottomRight
);
void
slotSourceRowsInserted
(
const
QModelIndex
&
parent
,
const
int
first
,
const
int
last
);
private:
static
std
::
pair
<
QDateTime
,
QDateTime
>
incidenceOccurrenceStartEnd
(
const
QDateTime
&
ocStart
,
const
KCalendarCore
::
Incidence
::
Ptr
&
incidence
);
static
uint
incidenceOccurrenceHash
(
const
QDateTime
&
ocStart
,
const
QDateTime
&
ocEnd
,
const
QString
&
incidenceUid
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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