Skip to content

Commit e8f345f

Browse files
acehighdanCalcProgrammer1
authored andcommitted
Sync autostart system configuration with OpenRGB settings on startup
If the autostart system configuration is deleted (e.g. by a reinstall or package manager) but the JSON config still has enabled=true, OpenRGB would silently fail to start at login. Fix by calling ConfigureAutoStart() in the settings page constructor so the system configuration is always reconciled with the stored JSON state every time OpenRGB starts. Commit amended to make wording more generic by Adam Honse <calcprogrammer1@gmail.com>
1 parent aff0610 commit e8f345f

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

qt/OpenRGBSettingsPage/OpenRGBSettingsPage.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -343,6 +343,14 @@ OpenRGBSettingsPage::OpenRGBSettingsPage(QWidget *parent) :
343343

344344
ui->AutoStartStatusLabel->hide();
345345
autostart_initialized = true;
346+
347+
/*---------------------------------------------------------*\
348+
| Sync the autostart system configuration with settings on |
349+
| startup. This ensures the file is recreated if it was |
350+
| deleted (e.g. by a reinstall) without requiring the user |
351+
| to manually toggle the checkbox. |
352+
\*---------------------------------------------------------*/
353+
ConfigureAutoStart();
346354
}
347355

348356
OpenRGBSettingsPage::~OpenRGBSettingsPage()

0 commit comments

Comments
 (0)