diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2018-08-07 12:59:49 +0200 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2018-08-15 00:02:09 +0200 |
commit | 0e6d0bfaf5f1dd2e7aa4fc210160c62658be1458 (patch) | |
tree | a95781274b97856ca4220928ab8782c9c230be50 | |
parent | ea6ba98e19f970dc56fb762085aec35915681718 (diff) | |
download | kube-0e6d0bfaf5f1dd2e7aa4fc210160c62658be1458.tar.gz kube-0e6d0bfaf5f1dd2e7aa4fc210160c62658be1458.zip |
Invert the calendar filter so all calendars are enabled by default
unless explicitly disabled.
-rw-r--r-- | framework/src/domain/daylongeventmodel.cpp | 2 | ||||
-rw-r--r-- | framework/src/domain/perioddayeventmodel.cpp | 2 | ||||
-rw-r--r-- | views/calendar/qml/View.qml | 4 |
3 files changed, 4 insertions, 4 deletions
diff --git a/framework/src/domain/daylongeventmodel.cpp b/framework/src/domain/daylongeventmodel.cpp index 53b50652..cd26b5c4 100644 --- a/framework/src/domain/daylongeventmodel.cpp +++ b/framework/src/domain/daylongeventmodel.cpp | |||
@@ -99,7 +99,7 @@ bool DayLongEventModel::filterAcceptsRow(int sourceRow, const QModelIndex &sourc | |||
99 | auto idx = sourceModel()->index(sourceRow, 0, sourceParent); | 99 | auto idx = sourceModel()->index(sourceRow, 0, sourceParent); |
100 | auto event = idx.data(Sink::Store::DomainObjectRole).value<Event::Ptr>(); | 100 | auto event = idx.data(Sink::Store::DomainObjectRole).value<Event::Ptr>(); |
101 | 101 | ||
102 | if (!mCalendarFilter.contains(event->getCalendar())) { | 102 | if (mCalendarFilter.contains(event->getCalendar())) { |
103 | return false; | 103 | return false; |
104 | } | 104 | } |
105 | 105 | ||
diff --git a/framework/src/domain/perioddayeventmodel.cpp b/framework/src/domain/perioddayeventmodel.cpp index 149c0fcb..1f08fbd3 100644 --- a/framework/src/domain/perioddayeventmodel.cpp +++ b/framework/src/domain/perioddayeventmodel.cpp | |||
@@ -83,7 +83,7 @@ void PeriodDayEventModel::partitionData() | |||
83 | SinkWarning() << "Invalid date in the eventModel, ignoring..."; | 83 | SinkWarning() << "Invalid date in the eventModel, ignoring..."; |
84 | continue; | 84 | continue; |
85 | } | 85 | } |
86 | if (!mCalendarFilter.contains(event->getCalendar())) { | 86 | if (mCalendarFilter.contains(event->getCalendar())) { |
87 | continue; | 87 | continue; |
88 | } | 88 | } |
89 | 89 | ||
diff --git a/views/calendar/qml/View.qml b/views/calendar/qml/View.qml index ac446b88..529f165f 100644 --- a/views/calendar/qml/View.qml +++ b/views/calendar/qml/View.qml | |||
@@ -132,8 +132,8 @@ RowLayout { | |||
132 | spacing: Kube.Units.smallSpacing | 132 | spacing: Kube.Units.smallSpacing |
133 | Kube.CheckBox { | 133 | Kube.CheckBox { |
134 | opacity: 0.9 | 134 | opacity: 0.9 |
135 | checked: model.checked | 135 | checked: !model.checked |
136 | onToggled: model.checked = checked | 136 | onToggled: model.checked = !checked |
137 | } | 137 | } |
138 | Kube.Label { | 138 | Kube.Label { |
139 | text: model.name | 139 | text: model.name |