mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2026-07-02 03:16:58 +03:00
Pass option as constructor parameter
Signed-off-by: Dylan Schooner <dschooner05@gmail.com>
This commit is contained in:
parent
55dc9e6a84
commit
11a2ba63b3
6 changed files with 12 additions and 30 deletions
|
|
@ -2,7 +2,7 @@
|
|||
#include <QPushButton>
|
||||
#include "ui_ScrollMessageBox.h"
|
||||
|
||||
ScrollMessageBox::ScrollMessageBox(QWidget* parent, const QString& title, const QString& text, const QString& body)
|
||||
ScrollMessageBox::ScrollMessageBox(QWidget* parent, const QString& title, const QString& text, const QString& body, const QString& option)
|
||||
: QDialog(parent), ui(new Ui::ScrollMessageBox)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
|
@ -10,6 +10,11 @@ ScrollMessageBox::ScrollMessageBox(QWidget* parent, const QString& title, const
|
|||
ui->label->setText(text);
|
||||
ui->textBrowser->setText(body);
|
||||
|
||||
if (!option.isEmpty()) {
|
||||
ui->optionCheckBox->setVisible(true);
|
||||
ui->optionCheckBox->setText(option);
|
||||
}
|
||||
|
||||
ui->buttonBox->button(QDialogButtonBox::Cancel)->setText(tr("Cancel"));
|
||||
ui->buttonBox->button(QDialogButtonBox::Ok)->setText(tr("OK"));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue