格式修改
This commit is contained in:
parent
5c65f62860
commit
6cc2e731eb
|
@ -116,11 +116,12 @@ void SwitchButton::enterEvent(QEvent *event)
|
||||||
{
|
{
|
||||||
if (m_enabled && m_bIsOn) {
|
if (m_enabled && m_bIsOn) {
|
||||||
m_colorActive = COLOR_ACTIVE_HOVER;
|
m_colorActive = COLOR_ACTIVE_HOVER;
|
||||||
}
|
} else if (m_enabled && !m_bIsOn) {
|
||||||
else if (m_enabled && !m_bIsOn) {
|
|
||||||
m_colorInactive = COLOR_INACTIVE_HOVER;
|
m_colorInactive = COLOR_INACTIVE_HOVER;
|
||||||
}
|
}
|
||||||
|
|
||||||
this->update();
|
this->update();
|
||||||
|
|
||||||
return QWidget::enterEvent(event);
|
return QWidget::enterEvent(event);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -131,7 +132,9 @@ void SwitchButton::leaveEvent(QEvent *event)
|
||||||
} else if (m_enabled && !m_bIsOn) {
|
} else if (m_enabled && !m_bIsOn) {
|
||||||
m_colorInactive = COLOR_INACTIVE;
|
m_colorInactive = COLOR_INACTIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
this->update();
|
this->update();
|
||||||
|
|
||||||
return QWidget::leaveEvent(event);
|
return QWidget::leaveEvent(event);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue