Changeset View
Changeset View
Standalone View
Standalone View
applets/kicker/plugin/recentusagemodel.cpp
Show First 20 Lines • Show All 132 Lines • ▼ Show 20 Line(s) | |||||
133 | { | 133 | { | ||
134 | refresh(); | 134 | refresh(); | ||
135 | } | 135 | } | ||
136 | 136 | | |||
137 | RecentUsageModel::~RecentUsageModel() | 137 | RecentUsageModel::~RecentUsageModel() | ||
138 | { | 138 | { | ||
139 | } | 139 | } | ||
140 | 140 | | |||
141 | RecentUsageModel::IncludeUsage RecentUsageModel::usage() const | 141 | void RecentUsageModel::setShownItems(IncludeUsage usage) | ||
142 | { | ||||
143 | if (m_usage == usage) { | ||||
144 | return; | ||||
145 | } | ||||
146 | | ||||
147 | m_usage = usage; | ||||
148 | | ||||
149 | emit shownItemsChanged(); | ||||
150 | refresh(); | ||||
davidedmundson: we have QQmlParserStatus in this class, we probably want to use it. | |||||
refresh() implementation already has a check on m_completed (which is set on componentCompleted) mart: refresh() implementation already has a check on m_completed (which is set on componentCompleted) | |||||
151 | } | ||||
152 | | ||||
153 | RecentUsageModel::IncludeUsage RecentUsageModel::shownItems() const | ||||
142 | { | 154 | { | ||
143 | return m_usage; | 155 | return m_usage; | ||
144 | } | 156 | } | ||
145 | 157 | | |||
146 | QString RecentUsageModel::description() const | 158 | QString RecentUsageModel::description() const | ||
147 | { | 159 | { | ||
148 | switch (m_usage) { | 160 | switch (m_usage) { | ||
149 | case AppsAndDocs: | 161 | case AppsAndDocs: | ||
▲ Show 20 Lines • Show All 384 Lines • Show Last 20 Lines |
we have QQmlParserStatus in this class, we probably want to use it.