1
0
mirror of https://github.com/mifi/lossless-cut.git synced 2024-11-22 02:12:30 +01:00

move overwrite existing button

closes #1688
This commit is contained in:
Mikael Finstad 2023-08-27 22:19:40 +02:00
parent 1f0a1a4e4d
commit 925ddd45e9
No known key found for this signature in database
GPG Key ID: 25AB36E3E81CBC26
2 changed files with 22 additions and 8 deletions

View File

@ -40,7 +40,7 @@ const ExportConfirm = memo(({
}) => {
const { t } = useTranslation();
const { changeOutDir, keyframeCut, toggleKeyframeCut, preserveMovData, movFastStart, avoidNegativeTs, setAvoidNegativeTs, autoDeleteMergedSegments, exportConfirmEnabled, toggleExportConfirmEnabled, segmentsToChapters, toggleSegmentsToChapters, preserveMetadataOnMerge, togglePreserveMetadataOnMerge, enableSmartCut, setEnableSmartCut, effectiveExportMode } = useUserSettings();
const { changeOutDir, keyframeCut, toggleKeyframeCut, preserveMovData, movFastStart, avoidNegativeTs, setAvoidNegativeTs, autoDeleteMergedSegments, exportConfirmEnabled, toggleExportConfirmEnabled, segmentsToChapters, toggleSegmentsToChapters, preserveMetadataOnMerge, togglePreserveMetadataOnMerge, enableSmartCut, setEnableSmartCut, effectiveExportMode, enableOverwriteOutput, setEnableOverwriteOutput } = useUserSettings();
const isMov = ffmpegIsMov(outFormat);
const isIpod = outFormat === 'ipod';
@ -55,6 +55,8 @@ const ExportConfirm = memo(({
separate: t('Export to separate files'),
})[effectiveExportMode], [effectiveExportMode, t]);
const showHelpText = useCallback(({ icon = 'info', timer = 10000, text }) => toast.fire({ icon, timer, text }), []);
const onPreserveMovDataHelpPress = useCallback(() => {
toast.fire({ icon: 'info', timer: 10000, text: i18n.t('Preserve all MOV/MP4 metadata tags (e.g. EXIF, GPS position etc.) from source file? Note that some players have trouble playing back files where all metadata is preserved, like iTunes and other Apple software') });
}, []);
@ -195,6 +197,25 @@ const ExportConfirm = memo(({
</td>
</tr>
)}
<tr>
<td>
{t('Overwrite existing files')}
</td>
<td>
<Switch checked={enableOverwriteOutput} onCheckedChange={setEnableOverwriteOutput} />
</td>
<td>
<HelpIcon onClick={() => showHelpText({ text: t('Overwrite files when exporting, if a file with the same name as the output file name exists?') })} />
</td>
</tr>
<div>
<div>{}</div>
<td>
</td>
</div>
</tbody>
</table>
<h3 style={{ marginBottom: '.5em' }}>{t('Advanced options')}</h3>

View File

@ -237,13 +237,6 @@ const Settings = memo(({
</td>
</Row>
<Row>
<KeyCell>{t('Overwrite files when exporting, if a file with the same name as the output file name exists?')}</KeyCell>
<td>
<Switch checked={enableOverwriteOutput} onCheckedChange={setEnableOverwriteOutput} />
</td>
</Row>
<Row>
<KeyCell>{t('Cleanup files after export?')}</KeyCell>
<td>