diff options
Diffstat (limited to 'src/preferences/dialog/dlgpreferences.cpp')
-rw-r--r-- | src/preferences/dialog/dlgpreferences.cpp | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/src/preferences/dialog/dlgpreferences.cpp b/src/preferences/dialog/dlgpreferences.cpp index d1b2fdcd35..da1761dd32 100644 --- a/src/preferences/dialog/dlgpreferences.cpp +++ b/src/preferences/dialog/dlgpreferences.cpp @@ -152,17 +152,20 @@ DlgPreferences::DlgPreferences( tr("Interface"), "ic_preferences_interface.svg"); - DlgPrefWaveform* pWaveformPage = new DlgPrefWaveform(this, m_pConfig, pLibrary); - addPageWidget(PreferencesPage( - pWaveformPage, - new QTreeWidgetItem(contentsTreeWidget, QTreeWidgetItem::Type)), - tr("Waveforms"), - "ic_preferences_waveforms.svg"); - connect(pWaveformPage, - &DlgPrefWaveform::reloadUserInterface, - this, - &DlgPreferences::reloadUserInterface, - Qt::DirectConnection); + // ugly proxy for determining whether this is being instantiated for QML or legacy QWidgets GUI + if (pSkinLoader) { + DlgPrefWaveform* pWaveformPage = new DlgPrefWaveform(this, m_pConfig, pLibrary); + addPageWidget(PreferencesPage( + pWaveformPage, + new QTreeWidgetItem(contentsTreeWidget, QTreeWidgetItem::Type)), + tr("Waveforms"), + "ic_preferences_waveforms.svg"); + connect(pWaveformPage, + &DlgPrefWaveform::reloadUserInterface, + this, + &DlgPreferences::reloadUserInterface, + Qt::DirectConnection); + } addPageWidget(PreferencesPage( new DlgPrefColors(this, m_pConfig, pLibrary), |