65 : QWidget(parent), d(new
Private)
67 QHBoxLayout*
const hlay =
new QHBoxLayout(
this);
68 d->combo =
new QComboBox(
this);
69 d->resetButton =
new QToolButton(
this);
70 d->resetButton->setAutoRaise(
true);
71 d->resetButton->setFocusPolicy(Qt::NoFocus);
73 d->resetButton->setToolTip(i18nc(
"@info:tooltip",
"Reset to default value"));
75 hlay->addWidget(
d->combo);
76 hlay->addWidget(
d->resetButton);
77 hlay->setStretchFactor(
d->combo, 10);
78 hlay->setContentsMargins(0, 0, 0, 0);
79 hlay->setSpacing(QApplication::style()->pixelMetric(QStyle::PM_LayoutHorizontalSpacing));
83 connect(
d->resetButton, &QToolButton::clicked,
86 connect(
d->combo,
static_cast<void (QComboBox::*)(
int)
>(&QComboBox::activated),
89 connect(
d->combo,
static_cast<void (QComboBox::*)(
int)
>(&QComboBox::currentIndexChanged),