| 262 | } |
| 263 | |
| 264 | void BootEntryListModel::setEntryNextBoot(const QModelIndex &index, bool value) |
| 265 | { |
| 266 | if(!index.isValid() || !checkIndex(index)) |
| 267 | return; |
| 268 | |
| 269 | auto command = new SetBootEntryValueCommand<bool>{*this, index, tr("next boot"), &BootEntry::is_next_boot, value}; |
| 270 | if(!undo_stack) |
| 271 | { |
| 272 | command->redo(); |
| 273 | delete command; |
| 274 | return; |
| 275 | } |
| 276 | |
| 277 | undo_stack->push(command); |
| 278 | } |
| 279 | |
| 280 | auto BootEntryListModel::insertRows(int row, int count, const QModelIndex &parent) -> bool |
| 281 | { |