Fixed some minor layout issues in GuiMetaDataEd when running on a vertically oriented screen.

This commit is contained in:
Leon Styhre 2023-02-11 13:22:08 +01:00
parent 8a60bf0877
commit 260c1da574

View file

@ -288,7 +288,8 @@ GuiMetaDataEd::GuiMetaDataEd(MetaDataList* md,
bracket->setImage(":/graphics/arrow.svg");
row.addElement(bracket, false);
const std::string title {it->displayPrompt};
const std::string title {mRenderer->getIsVerticalOrientation() ? "select emulator" :
it->displayPrompt};
// OK callback (apply new value to ed).
auto updateVal = [this, ed, originalValue](const std::string& newVal) {
@ -394,7 +395,8 @@ GuiMetaDataEd::GuiMetaDataEd(MetaDataList* md,
const float aspectValue {1.778f / mRenderer->getScreenAspectRatio()};
const float maxWidthModifier {
glm::clamp(0.64f * aspectValue, 0.42f, 0.92f)};
glm::clamp(0.64f * aspectValue, 0.42f,
(mRenderer->getIsVerticalOrientation() ? 0.95f : 0.92f))};
const float maxWidth {static_cast<float>(mRenderer->getScreenWidth()) *
maxWidthModifier};