forked from qt-creator/qt-creator
ScreenRecorder: Fix "show dialog or settings" logic
If the user selects "Record Screen" while the ffmpeg/ffprobe are not set, the ScreenRecorder settings are shown. The ScreenRecorder dialog did open up after the settings page, even if the user just pressed OK without setting the tools. With this change, not the settings page return value determines whether to show the ScreenRecorder dialog, but rather a second check if the tools are set/registered. Change-Id: I35b8f4e3afe7ea5e6834fcff74ce8f73d3a115b4 Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -135,9 +135,11 @@ public:
|
||||
private:
|
||||
void showDialogOrSettings()
|
||||
{
|
||||
if (!Internal::settings().toolsRegistered() &&
|
||||
!Core::ICore::showOptionsDialog(Constants::TOOLSSETTINGSPAGE_ID)) {
|
||||
return;
|
||||
if (!Internal::settings().toolsRegistered()) {
|
||||
// Show options if ffmpeg/ffprobe are neither autodetected nor manually set
|
||||
Core::ICore::showOptionsDialog(Constants::TOOLSSETTINGSPAGE_ID);
|
||||
if (!Internal::settings().toolsRegistered())
|
||||
return; // User did not set ffmpeg/ffprobe
|
||||
}
|
||||
|
||||
ScreenRecorderDialog::showDialog();
|
||||
|
Reference in New Issue
Block a user