mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-22 19:23:52 +00:00
back & ok button caption
This commit is contained in:
parent
14377ba789
commit
424a90aa92
4 changed files with 8 additions and 3 deletions
|
@ -28,10 +28,12 @@ BirthDialog::BirthDialog(WindowManager& parWindowManager)
|
||||||
// TODO: These buttons should be managed by a Dialog class
|
// TODO: These buttons should be managed by a Dialog class
|
||||||
MyGUI::ButtonPtr backButton;
|
MyGUI::ButtonPtr backButton;
|
||||||
getWidget(backButton, "BackButton");
|
getWidget(backButton, "BackButton");
|
||||||
|
backButton->setCaption(mWindowManager.getGameSettingString("sBack", ""));
|
||||||
backButton->eventMouseButtonClick += MyGUI::newDelegate(this, &BirthDialog::onBackClicked);
|
backButton->eventMouseButtonClick += MyGUI::newDelegate(this, &BirthDialog::onBackClicked);
|
||||||
|
|
||||||
MyGUI::ButtonPtr okButton;
|
MyGUI::ButtonPtr okButton;
|
||||||
getWidget(okButton, "OKButton");
|
getWidget(okButton, "OKButton");
|
||||||
|
okButton->setCaption(mWindowManager.getGameSettingString("sOK", ""));
|
||||||
okButton->eventMouseButtonClick += MyGUI::newDelegate(this, &BirthDialog::onOkClicked);
|
okButton->eventMouseButtonClick += MyGUI::newDelegate(this, &BirthDialog::onOkClicked);
|
||||||
|
|
||||||
updateBirths();
|
updateBirths();
|
||||||
|
|
|
@ -29,10 +29,12 @@ GenerateClassResultDialog::GenerateClassResultDialog(WindowManager& parWindowMan
|
||||||
// TODO: These buttons should be managed by a Dialog class
|
// TODO: These buttons should be managed by a Dialog class
|
||||||
MyGUI::ButtonPtr backButton;
|
MyGUI::ButtonPtr backButton;
|
||||||
getWidget(backButton, "BackButton");
|
getWidget(backButton, "BackButton");
|
||||||
|
backButton->setCaption(mWindowManager.getGameSettingString("sBack", ""));
|
||||||
backButton->eventMouseButtonClick += MyGUI::newDelegate(this, &GenerateClassResultDialog::onBackClicked);
|
backButton->eventMouseButtonClick += MyGUI::newDelegate(this, &GenerateClassResultDialog::onBackClicked);
|
||||||
|
|
||||||
MyGUI::ButtonPtr okButton;
|
MyGUI::ButtonPtr okButton;
|
||||||
getWidget(okButton, "OKButton");
|
getWidget(okButton, "OKButton");
|
||||||
|
okButton->setCaption(mWindowManager.getGameSettingString("sOK", ""));
|
||||||
okButton->eventMouseButtonClick += MyGUI::newDelegate(this, &GenerateClassResultDialog::onOkClicked);
|
okButton->eventMouseButtonClick += MyGUI::newDelegate(this, &GenerateClassResultDialog::onOkClicked);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -72,10 +72,12 @@ RaceDialog::RaceDialog(WindowManager& parWindowManager)
|
||||||
// TODO: These buttons should be managed by a Dialog class
|
// TODO: These buttons should be managed by a Dialog class
|
||||||
MyGUI::ButtonPtr backButton;
|
MyGUI::ButtonPtr backButton;
|
||||||
getWidget(backButton, "BackButton");
|
getWidget(backButton, "BackButton");
|
||||||
|
backButton->setCaption(mWindowManager.getGameSettingString("sBack", ""));
|
||||||
backButton->eventMouseButtonClick += MyGUI::newDelegate(this, &RaceDialog::onBackClicked);
|
backButton->eventMouseButtonClick += MyGUI::newDelegate(this, &RaceDialog::onBackClicked);
|
||||||
|
|
||||||
MyGUI::ButtonPtr okButton;
|
MyGUI::ButtonPtr okButton;
|
||||||
getWidget(okButton, "OKButton");
|
getWidget(okButton, "OKButton");
|
||||||
|
okButton->setCaption(mWindowManager.getGameSettingString("sOK", ""));
|
||||||
okButton->eventMouseButtonClick += MyGUI::newDelegate(this, &RaceDialog::onOkClicked);
|
okButton->eventMouseButtonClick += MyGUI::newDelegate(this, &RaceDialog::onOkClicked);
|
||||||
|
|
||||||
updateRaces();
|
updateRaces();
|
||||||
|
@ -94,15 +96,12 @@ void RaceDialog::setNextButtonShow(bool shown)
|
||||||
// TODO: All hardcoded coords for buttons are temporary, will be replaced with a dynamic system.
|
// TODO: All hardcoded coords for buttons are temporary, will be replaced with a dynamic system.
|
||||||
if (shown)
|
if (shown)
|
||||||
{
|
{
|
||||||
okButton->setCaption("Next");
|
|
||||||
|
|
||||||
// Adjust back button when next is shown
|
// Adjust back button when next is shown
|
||||||
backButton->setCoord(MyGUI::IntCoord(471 - 18, 397, 53, 23));
|
backButton->setCoord(MyGUI::IntCoord(471 - 18, 397, 53, 23));
|
||||||
okButton->setCoord(MyGUI::IntCoord(532 - 18, 397, 42 + 18, 23));
|
okButton->setCoord(MyGUI::IntCoord(532 - 18, 397, 42 + 18, 23));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
okButton->setCaption("OK");
|
|
||||||
backButton->setCoord(MyGUI::IntCoord(471, 397, 53, 23));
|
backButton->setCoord(MyGUI::IntCoord(471, 397, 53, 23));
|
||||||
okButton->setCoord(MyGUI::IntCoord(532, 397, 42, 23));
|
okButton->setCoord(MyGUI::IntCoord(532, 397, 42, 23));
|
||||||
}
|
}
|
||||||
|
|
|
@ -93,10 +93,12 @@ ReviewDialog::ReviewDialog(WindowManager& parWindowManager)
|
||||||
// TODO: These buttons should be managed by a Dialog class
|
// TODO: These buttons should be managed by a Dialog class
|
||||||
MyGUI::ButtonPtr backButton;
|
MyGUI::ButtonPtr backButton;
|
||||||
getWidget(backButton, "BackButton");
|
getWidget(backButton, "BackButton");
|
||||||
|
backButton->setCaption(mWindowManager.getGameSettingString("sBack", ""));
|
||||||
backButton->eventMouseButtonClick += MyGUI::newDelegate(this, &ReviewDialog::onBackClicked);
|
backButton->eventMouseButtonClick += MyGUI::newDelegate(this, &ReviewDialog::onBackClicked);
|
||||||
|
|
||||||
MyGUI::ButtonPtr okButton;
|
MyGUI::ButtonPtr okButton;
|
||||||
getWidget(okButton, "OKButton");
|
getWidget(okButton, "OKButton");
|
||||||
|
okButton->setCaption(mWindowManager.getGameSettingString("sOK", ""));
|
||||||
okButton->eventMouseButtonClick += MyGUI::newDelegate(this, &ReviewDialog::onOkClicked);
|
okButton->eventMouseButtonClick += MyGUI::newDelegate(this, &ReviewDialog::onOkClicked);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue