mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-06-15 06:58:37 +02:00
DolphinQt: Remove MappingButton bold/italic text indication.
This commit is contained in:
@ -72,7 +72,7 @@ bool MappingButton::IsInput() const
|
||||
return m_reference->IsInput();
|
||||
}
|
||||
|
||||
MappingButton::MappingButton(MappingWidget* parent, ControlReference* ref, bool indicator)
|
||||
MappingButton::MappingButton(MappingWidget* parent, ControlReference* ref)
|
||||
: ElidedButton(RefToDisplayString(ref)), m_mapping_window(parent->GetParent()), m_reference(ref)
|
||||
{
|
||||
if (IsInput())
|
||||
@ -87,9 +87,6 @@ MappingButton::MappingButton(MappingWidget* parent, ControlReference* ref, bool
|
||||
|
||||
connect(this, &MappingButton::clicked, this, &MappingButton::Clicked);
|
||||
|
||||
if (indicator)
|
||||
connect(parent, &MappingWidget::Update, this, &MappingButton::UpdateIndicator);
|
||||
|
||||
connect(parent, &MappingWidget::ConfigChanged, this, &MappingButton::ConfigChanged);
|
||||
connect(this, &MappingButton::ConfigChanged, [this] {
|
||||
setText(RefToDisplayString(m_reference));
|
||||
@ -134,21 +131,6 @@ void MappingButton::Clear()
|
||||
m_mapping_window->UnQueueInputDetection(this);
|
||||
}
|
||||
|
||||
void MappingButton::UpdateIndicator()
|
||||
{
|
||||
QFont f = m_mapping_window->font();
|
||||
|
||||
if (isActiveWindow() && m_reference->IsInput() && m_reference->GetState<bool>() && !m_is_mapping)
|
||||
f.setBold(true);
|
||||
|
||||
// If the expression has failed to parse, show it in italic.
|
||||
// Some expressions still work even the failed to parse so don't prevent the GetState() above.
|
||||
if (m_reference->GetParseStatus() == ciface::ExpressionParser::ParseStatus::SyntaxError)
|
||||
f.setItalic(true);
|
||||
|
||||
setFont(f);
|
||||
}
|
||||
|
||||
void MappingButton::StartMapping()
|
||||
{
|
||||
// Focus just makes it more clear which button is currently being mapped.
|
||||
|
Reference in New Issue
Block a user