equal
deleted
inserted
replaced
119 topLayout->addWidget(corner, 0, Qt::AlignBottom); |
119 topLayout->addWidget(corner, 0, Qt::AlignBottom); |
120 topLayout->addStretch(1); |
120 topLayout->addStretch(1); |
121 |
121 |
122 // Cancel button (closes dialog) |
122 // Cancel button (closes dialog) |
123 QPushButton * btnCancel = new QPushButton(tr("Cancel")); |
123 QPushButton * btnCancel = new QPushButton(tr("Cancel")); |
124 connect(btnCancel, SIGNAL(clicked()), this, SLOT(reject())); |
124 connect(btnCancel, SIGNAL(clicked()), this, SLOT(onRejected())); |
125 |
125 |
126 // Select button |
126 // Select button |
127 QPushButton * btnSelect = new QPushButton(tr("Use selected theme")); |
127 QPushButton * btnSelect = new QPushButton(tr("Use selected theme")); |
128 btnSelect->setDefault(true); |
128 btnSelect->setDefault(true); |
129 connect(btnSelect, SIGNAL(clicked()), this, SLOT(onAccepted())); |
129 connect(btnSelect, SIGNAL(clicked()), this, SLOT(onAccepted())); |
168 void ThemePrompt::moveRight() |
168 void ThemePrompt::moveRight() |
169 { |
169 { |
170 list->moveRight(); |
170 list->moveRight(); |
171 } |
171 } |
172 |
172 |
|
173 void ThemePrompt::onRejected() |
|
174 { |
|
175 reject(); |
|
176 filterModel->setFilterFixedString(QString()); |
|
177 } |
|
178 |
173 void ThemePrompt::onAccepted() |
179 void ThemePrompt::onAccepted() |
174 { |
180 { |
175 themeChosen(list->currentIndex()); |
181 themeChosen(list->currentIndex()); |
|
182 filterModel->setFilterFixedString(QString()); |
176 } |
183 } |
177 |
184 |
178 // When a theme is selected |
185 // When a theme is selected |
179 void ThemePrompt::themeChosen(const QModelIndex & index) |
186 void ThemePrompt::themeChosen(const QModelIndex & index) |
180 { |
187 { |