| 306 | } |
| 307 | |
| 308 | auto BootEntryListModel::removeRows(int row, int count, const QModelIndex &parent) -> bool |
| 309 | { |
| 310 | for(int c = 0; c < count; ++c) |
| 311 | { |
| 312 | auto command = new RemoveBootEntryCommand{*this, parent, row}; |
| 313 | if(!undo_stack) |
| 314 | { |
| 315 | command->redo(); |
| 316 | delete command; |
| 317 | continue; |
| 318 | } |
| 319 | |
| 320 | undo_stack->push(command); |
| 321 | } |
| 322 | |
| 323 | return true; |
| 324 | } |
| 325 | |
| 326 | auto BootEntryListModel::moveRows(const QModelIndex &sourceParent, int sourceRow, int count, const QModelIndex &destinationParent, int destinationChild) -> bool |
| 327 | { |