18 QDialog(parentWidget),
19 m_ui(
new QT_PREPEND_NAMESPACE(Ui)::PreferencesDialog())
23 m_optionsPages = core->optionsPages();
25 m_ui->m_optionTabWidget->clear();
26 for (QDesignerOptionsPageInterface *optionsPage : std::as_const(m_optionsPages)) {
27 QWidget *page = optionsPage->createPage(
this);
28 m_ui->m_optionTabWidget->addTab(page, optionsPage->name());
29 if (
auto *appearanceWidget = qobject_cast<QDesignerAppearanceOptionsWidget *>(page))
30 connect(appearanceWidget, &QDesignerAppearanceOptionsWidget::uiModeChanged,
31 this, &PreferencesDialog::slotUiModeChanged);
34 connect(m_ui->m_dialogButtonBox, &QDialogButtonBox::rejected,
this, &PreferencesDialog::slotRejected);
35 connect(m_ui->m_dialogButtonBox, &QDialogButtonBox::accepted,
this, &PreferencesDialog::slotAccepted);
36 connect(applyButton(), &QAbstractButton::clicked,
this, &PreferencesDialog::slotApply);