| 804 | } |
| 805 | |
| 806 | static void setupRemoveContextMenuEnry( |
| 807 | MacroEdit *edit, const std::function<void(MacroEdit *, int)> &remove, |
| 808 | const QPoint &pos, MacroSegmentList *list, QMenu &menu) |
| 809 | { |
| 810 | const auto segmentEditIndex = list->IndexAt(pos); |
| 811 | if (segmentEditIndex == -1) { |
| 812 | return; |
| 813 | } |
| 814 | |
| 815 | menu.addAction( |
| 816 | obs_module_text("AdvSceneSwitcher.macroTab.segment.remove"), |
| 817 | edit, [edit, remove, segmentEditIndex]() { |
| 818 | remove(edit, segmentEditIndex); |
| 819 | }); |
| 820 | } |
| 821 | |
| 822 | static bool handleCustomLabelRename(MacroSegmentEdit *segmentEdit) |
| 823 | { |
no test coverage detected