UI: Fix disabling "resize output to source"

This should always be disabled if video output is active.  Additionally,
the expression used to determine whether it should be enabled/disabled
was very unreadable.
This commit is contained in:
jp9000 2019-02-19 19:26:37 -08:00
parent 0bab66ca52
commit 103bec6526

View File

@ -4361,10 +4361,7 @@ void OBSBasic::CreateSourcePopupMenu(int idx, bool preview)
int width = obs_source_get_width(source); int width = obs_source_get_width(source);
int height = obs_source_get_height(source); int height = obs_source_get_height(source);
resizeOutput->setEnabled(!(ui->streamButton->isChecked() || resizeOutput->setEnabled(!obs_video_active());
ui->recordButton->isChecked() ||
(replayBufferButton &&
replayBufferButton->isChecked())));
if (width == 0 || height == 0) if (width == 0 || height == 0)
resizeOutput->setEnabled(false); resizeOutput->setEnabled(false);