mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-22 22:25:38 +00:00
Fixed color of GuiMetaDataEd title.
Tweaked "fade" transition when launching a game.
This commit is contained in:
parent
64d6af09b4
commit
11065cc582
|
@ -30,7 +30,7 @@ GuiMetaDataEd::GuiMetaDataEd(Window* window, MetaDataList* md, const std::vector
|
||||||
|
|
||||||
mHeaderGrid = std::make_shared<ComponentGrid>(mWindow, Vector2i(1, 5));
|
mHeaderGrid = std::make_shared<ComponentGrid>(mWindow, Vector2i(1, 5));
|
||||||
|
|
||||||
mTitle = std::make_shared<TextComponent>(mWindow, "EDIT METADATA", Font::get(FONT_SIZE_LARGE), 0x333333FF, ALIGN_CENTER);
|
mTitle = std::make_shared<TextComponent>(mWindow, "EDIT METADATA", Font::get(FONT_SIZE_LARGE), 0x555555FF, ALIGN_CENTER);
|
||||||
mSubtitle = std::make_shared<TextComponent>(mWindow, strToUpper(scraperParams.game->getPath().filename().generic_string()),
|
mSubtitle = std::make_shared<TextComponent>(mWindow, strToUpper(scraperParams.game->getPath().filename().generic_string()),
|
||||||
Font::get(FONT_SIZE_SMALL), 0x777777FF, ALIGN_CENTER);
|
Font::get(FONT_SIZE_SMALL), 0x777777FF, ALIGN_CENTER);
|
||||||
mHeaderGrid->setEntry(mTitle, Vector2i(0, 1), false, true);
|
mHeaderGrid->setEntry(mTitle, Vector2i(0, 1), false, true);
|
||||||
|
@ -214,5 +214,6 @@ std::vector<HelpPrompt> GuiMetaDataEd::getHelpPrompts()
|
||||||
{
|
{
|
||||||
std::vector<HelpPrompt> prompts = mGrid.getHelpPrompts();
|
std::vector<HelpPrompt> prompts = mGrid.getHelpPrompts();
|
||||||
prompts.push_back(HelpPrompt("b", "discard"));
|
prompts.push_back(HelpPrompt("b", "discard"));
|
||||||
|
prompts.push_back(HelpPrompt("start", "close"));
|
||||||
return prompts;
|
return prompts;
|
||||||
}
|
}
|
||||||
|
|
|
@ -139,14 +139,15 @@ void ViewController::launch(FileData* game, Eigen::Vector3f center)
|
||||||
{
|
{
|
||||||
// fade out, launch game, fade back in
|
// fade out, launch game, fade back in
|
||||||
auto fadeFunc = [this](float t) {
|
auto fadeFunc = [this](float t) {
|
||||||
t -= 1;
|
//t -= 1;
|
||||||
mFadeOpacity = lerp<float>(0.0f, 1.0f, t*t*t + 1);
|
//mFadeOpacity = lerp<float>(0.0f, 1.0f, t*t*t + 1);
|
||||||
|
mFadeOpacity = lerp<float>(0.0f, 1.0f, t);
|
||||||
};
|
};
|
||||||
setAnimation(new LambdaAnimation(fadeFunc, 1500), 0, [this, game, fadeFunc]
|
setAnimation(new LambdaAnimation(fadeFunc, 800), 0, [this, game, fadeFunc]
|
||||||
{
|
{
|
||||||
game->getSystem()->launchGame(mWindow, game);
|
game->getSystem()->launchGame(mWindow, game);
|
||||||
mLockInput = false;
|
mLockInput = false;
|
||||||
setAnimation(new LambdaAnimation(fadeFunc, 1500), 0, nullptr, true);
|
setAnimation(new LambdaAnimation(fadeFunc, 800), 0, nullptr, true);
|
||||||
this->onFileChanged(game, FILE_METADATA_CHANGED);
|
this->onFileChanged(game, FILE_METADATA_CHANGED);
|
||||||
});
|
});
|
||||||
}else{
|
}else{
|
||||||
|
|
Loading…
Reference in a new issue