| 168 | } |
| 169 | |
| 170 | void ListModel::searchWithTerm(const QString& term, int sort) |
| 171 | { |
| 172 | if (currentSearchTerm == term && currentSearchTerm.isNull() == term.isNull() && currentSort == sort) { |
| 173 | return; |
| 174 | } |
| 175 | currentSearchTerm = term; |
| 176 | currentSort = sort; |
| 177 | if (jobPtr) { |
| 178 | jobPtr->abort(); |
| 179 | searchState = ResetRequested; |
| 180 | return; |
| 181 | } else { |
| 182 | beginResetModel(); |
| 183 | modpacks.clear(); |
| 184 | endResetModel(); |
| 185 | searchState = None; |
| 186 | } |
| 187 | nextSearchOffset = 0; |
| 188 | performPaginatedSearch(); |
| 189 | } |
| 190 | |
| 191 | void Flame::ListModel::searchRequestFinished() |
| 192 | { |
no test coverage detected