Fix text overlapped with long translation

This commit is contained in:
Benau 2021-02-22 10:14:06 +08:00
parent d6967050ab
commit 035a761b30
2 changed files with 3 additions and 8 deletions

View File

@ -57,9 +57,6 @@
<spacer width="2%" height="10" />
<button id="rename_config" I18N="In the input configuration screen" text="Rename Configuration"/>
<spacer width="2%" height="10" />
<label id="conflict" proportion="1" text="" word_wrap="true" align="center"/>
</div>
</box>
</div>

View File

@ -19,6 +19,7 @@
#include "config/user_config.hpp"
#include "guiengine/CGUISpriteBank.hpp"
#include "guiengine/message_queue.hpp"
#include "guiengine/scalable_font.hpp"
#include "guiengine/screen.hpp"
#include "guiengine/widget.hpp"
@ -389,10 +390,6 @@ void OptionsScreenDevice::updateInputButtons()
} // if existing key
} // for action <= PA_LAST_MENU_ACTION;
GUIEngine::Widget* conflict_label =
getWidget<GUIEngine::LabelWidget>("conflict");
core::stringw warning;
if (conflicts_between)
{
@ -402,7 +399,8 @@ void OptionsScreenDevice::updateInputButtons()
}
if (conflicts_inside)
warning += _("* A red item means a conflict in the current configuration");
conflict_label->setText(warning);
if (!warning.empty())
MessageQueue::add(MessageQueue::MT_ERROR, warning);
} // updateInputButtons