| 191 | } |
| 192 | |
| 193 | void ProgramModel::toggle_hw_break(const QModelIndex &index) { |
| 194 | machine::Address address; |
| 195 | if (index.column() != 0 || machine == nullptr) { return; } |
| 196 | |
| 197 | if (!get_row_address(address, index.row())) { return; } |
| 198 | |
| 199 | if (machine->is_hwbreak(address)) { |
| 200 | machine->remove_hwbreak(address); |
| 201 | } else { |
| 202 | machine->insert_hwbreak(address); |
| 203 | } |
| 204 | update_all(); |
| 205 | } |
| 206 | |
| 207 | Qt::ItemFlags ProgramModel::flags(const QModelIndex &index) const { |
| 208 | if (index.column() != 2 && index.column() != 3) { |
nothing calls this directly
no test coverage detected