From 49cd7f199673b5267acfe757b7b2e62bc81cea7c Mon Sep 17 00:00:00 2001 From: Mikael Finstad Date: Sun, 6 Mar 2022 21:48:43 +0800 Subject: [PATCH] Rename events toggleCurrentSegmentEnabled->toggleCurrentSegmentSelected enableOnlyCurrentSegment->selectOnlyCurrentSegment enableAllSegments->selectAllSegments disableAllSegments->deselectAllSegments --- src/App.jsx | 10 +++++----- src/components/KeyboardShortcuts.jsx | 8 ++++---- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/App.jsx b/src/App.jsx index 0a7128bc..04065b0c 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -1865,10 +1865,10 @@ const App = memo(() => { toggleCaptureFormat, toggleStripAudio, setStartTimeOffset: askSetStartTimeOffset, - disableAllSegments: deselectAllSegments, - enableAllSegments: selectAllSegments, - enableOnlyCurrentSegment: selectOnlyCurrentSegment, - toggleCurrentSegmentEnabled: toggleCurrentSegmentSelected, + deselectAllSegments, + selectAllSegments, + selectOnlyCurrentSegment, + toggleCurrentSegmentSelected, removeSelectedSegments, fixInvalidDuration: tryFixInvalidDuration, increaseVolume: () => setPlaybackVolume((val) => Math.min(1, val + 0.07)), @@ -1914,7 +1914,7 @@ const App = memo(() => { if (match) return bubble; return true; // bubble the event - }, [addSegment, askSetStartTimeOffset, batchFileJump, batchOpenSelectedFile, captureSnapshot, changePlaybackRate, cleanupFilesDialog, clearSegments, closeBatch, closeExportConfirm, concatCurrentBatch, concatDialogVisible, convertFormatBatch, createFixedDurationSegments, createNumSegments, currentSegIndexSafe, cutSegmentsHistory, deselectAllSegments, exportConfirmVisible, extractAllStreams, fillSegmentsGaps, goToTimecode, increaseRotation, invertAllCutSegments, jumpCutEnd, jumpCutStart, jumpSeg, jumpTimelineEnd, jumpTimelineStart, keyboardNormalSeekSpeed, keyboardSeekAccFactor, keyboardShortcutsVisible, onExportConfirm, onExportPress, onLabelSegmentPress, pause, play, removeCutSegment, reorderSegsByStartTime, seekClosestKeyframe, seekRel, seekRelPercent, selectAllSegments, selectOnlyCurrentSegment, setCutEnd, setCutStart, setPlaybackVolume, shortStep, shuffleSegments, splitCurrentSegment, timelineToggleComfortZoom, toggleCaptureFormat, toggleCurrentSegmentSelected, toggleHelp, toggleKeyboardShortcuts, toggleKeyframeCut, togglePlay, toggleSegmentsList, toggleStreamsSelector, toggleStripAudio, tryFixInvalidDuration, userHtml5ifyCurrentFile, zoomRel]); + }, [addSegment, askSetStartTimeOffset, batchFileJump, batchOpenSelectedFile, captureSnapshot, changePlaybackRate, cleanupFilesDialog, clearSegments, closeBatch, closeExportConfirm, concatCurrentBatch, concatDialogVisible, convertFormatBatch, createFixedDurationSegments, createNumSegments, currentSegIndexSafe, cutSegmentsHistory, deselectAllSegments, exportConfirmVisible, extractAllStreams, fillSegmentsGaps, goToTimecode, increaseRotation, invertAllCutSegments, jumpCutEnd, jumpCutStart, jumpSeg, jumpTimelineEnd, jumpTimelineStart, keyboardNormalSeekSpeed, keyboardSeekAccFactor, keyboardShortcutsVisible, onExportConfirm, onExportPress, onLabelSegmentPress, pause, play, removeCutSegment, removeSelectedSegments, reorderSegsByStartTime, seekClosestKeyframe, seekRel, seekRelPercent, selectAllSegments, selectOnlyCurrentSegment, setCutEnd, setCutStart, setPlaybackVolume, shortStep, shuffleSegments, splitCurrentSegment, timelineToggleComfortZoom, toggleCaptureFormat, toggleCurrentSegmentSelected, toggleHelp, toggleKeyboardShortcuts, toggleKeyframeCut, togglePlay, toggleSegmentsList, toggleStreamsSelector, toggleStripAudio, tryFixInvalidDuration, userHtml5ifyCurrentFile, zoomRel]); useKeyboard({ keyBindings, onKeyPress }); diff --git a/src/components/KeyboardShortcuts.jsx b/src/components/KeyboardShortcuts.jsx index 278b460d..70e0ce3a 100644 --- a/src/components/KeyboardShortcuts.jsx +++ b/src/components/KeyboardShortcuts.jsx @@ -312,19 +312,19 @@ const KeyboardShortcuts = memo(({ name: t('Show sidebar'), category: segmentsAndCutpointsCategory, }, - enableOnlyCurrentSegment: { + selectOnlyCurrentSegment: { name: t('Select only this segment'), category: segmentsAndCutpointsCategory, }, - disableAllSegments: { + deselectAllSegments: { name: t('Deselect all segments'), category: segmentsAndCutpointsCategory, }, - enableAllSegments: { + selectAllSegments: { name: t('Select all segments'), category: segmentsAndCutpointsCategory, }, - toggleCurrentSegmentEnabled: { + toggleCurrentSegmentSelected: { name: t('Toggle current segment selected'), category: segmentsAndCutpointsCategory, },