| 1425 | } |
| 1426 | |
| 1427 | void InputEditorModel::shiftMarkers(int startRow, int offset) { |
| 1428 | if (!context->config.editor_move_marker) |
| 1429 | return; |
| 1430 | |
| 1431 | // Create a temporary map to store updated markers |
| 1432 | std::map<int, std::string> updatedMarkers; |
| 1433 | |
| 1434 | for (const auto& marker : movie->editor->markers) { |
| 1435 | if (marker.first >= startRow) { |
| 1436 | updatedMarkers[marker.first + offset] = marker.second; |
| 1437 | } else { |
| 1438 | updatedMarkers[marker.first] = marker.second; |
| 1439 | } |
| 1440 | } |
| 1441 | |
| 1442 | // Replace the old markers with the updated ones |
| 1443 | movie->editor->markers = std::move(updatedMarkers); |
| 1444 | } |
| 1445 | |
| 1446 | void InputEditorModel::removeMarkersInRange(int startRow, int endRow) { |
| 1447 | if (!context->config.editor_move_marker) |
no outgoing calls
no test coverage detected