1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

Changed the buttons back to 'Cancel' and 'Remove'

This commit is contained in:
Impyy 2015-09-23 18:10:55 +02:00
parent 3d72a75ed3
commit 91e51f8a10
2 changed files with 3 additions and 1 deletions

View File

@ -46,7 +46,7 @@
<enum>Qt::Horizontal</enum>
</property>
<property name="standardButtons">
<set>QDialogButtonBox::No|QDialogButtonBox::Yes</set>
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
</property>
</widget>
</item>

View File

@ -9,6 +9,8 @@ RemoveFriendDialog::RemoveFriendDialog(QWidget *parent, const Friend *f)
setAttribute(Qt::WA_QuitOnClose, false);
ui.setupUi(this);
ui.label->setText(ui.label->text().replace("&lt;name&gt;", f->getDisplayedName()));
auto removeButton = ui.buttonBox->button(QDialogButtonBox::Ok);
removeButton->setText(tr("Remove"));
adjustSize();
connect(ui.buttonBox, &QDialogButtonBox::accepted, this, &RemoveFriendDialog::onAccepted);
connect(ui.buttonBox, &QDialogButtonBox::rejected, this, &RemoveFriendDialog::close);