Skip to content

Commit

Permalink
Fix settings name, disable select
Browse files Browse the repository at this point in the history
  • Loading branch information
ioppermann committed Sep 25, 2024
1 parent a57cd63 commit 2ecf252
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/misc/controls/Preview.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export default function Control(props) {
<Checkbox label={<Trans>Enable browser-compatible H.264 stream</Trans>} checked={settings.enable} onChange={handleChange('enable')} />
</Grid>
<Grid item xs={12} md={6}>
<Select label={<Trans>Video Codec</Trans>} value={settings.video_codec} onChange={handleChange('video_encoder')}>
<Select label={<Trans>Video Codec</Trans>} value={settings.video_encoder} disabled={!settings.enable} onChange={handleChange('video_encoder')}>
<MenuItem value="libx264" disabled={!encoders.includes('libx264')}>
H.264 (libx264)
</MenuItem>
Expand Down Expand Up @@ -77,5 +77,6 @@ export default function Control(props) {

Control.defaulProps = {
settings: {},
encoders: [],
onChange: function (settings, automatic) {},
};

0 comments on commit 2ecf252

Please sign in to comment.