Added Yes/No dialog box, and used it for the 'allow STK to connect
to internet' question.
This commit is contained in:
parent
c012e98f9b
commit
69c155063a
@ -1156,7 +1156,7 @@ void askForInternetPermission()
|
||||
"at a later time, go to options, select tab "
|
||||
"'User Interface', and edit \"Allow STK to connect to the "
|
||||
"Internet\" and \"Allow STK to send anonymous HW statistics\")."),
|
||||
MessageDialog::MESSAGE_DIALOG_CONFIRM,
|
||||
MessageDialog::MESSAGE_DIALOG_YESNO,
|
||||
new ConfirmServer(), true);
|
||||
}
|
||||
|
||||
|
@ -95,6 +95,14 @@ void MessageDialog::doInit(MessageDialogType type,
|
||||
cancelbtn->setText(_("OK"));
|
||||
cancelbtn->setFocusForPlayer(PLAYER_ID_GAME_MASTER);
|
||||
}
|
||||
else if (type == MessageDialog::MESSAGE_DIALOG_YESNO)
|
||||
{
|
||||
ButtonWidget* yesbtn = getWidget<ButtonWidget>("confirm");
|
||||
|
||||
ButtonWidget* cancelbtn = getWidget<ButtonWidget>("cancel");
|
||||
cancelbtn->setText(_("No"));
|
||||
|
||||
}
|
||||
else if (type == MessageDialog::MESSAGE_DIALOG_OK_CANCEL)
|
||||
{
|
||||
// In case of a OK_CANCEL dialog, change the text from 'Yes' to 'Ok'
|
||||
|
@ -62,7 +62,7 @@ public:
|
||||
};
|
||||
|
||||
enum MessageDialogType { MESSAGE_DIALOG_OK, MESSAGE_DIALOG_CONFIRM,
|
||||
MESSAGE_DIALOG_OK_CANCEL };
|
||||
MESSAGE_DIALOG_OK_CANCEL, MESSAGE_DIALOG_YESNO };
|
||||
|
||||
private:
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user