Misc. smaller UI adjustments/style

This commit is contained in:
Klaus Basan
2019-01-02 06:43:26 +01:00
committed by Mat Sutcliffe
parent e85680f1b0
commit cd095dbb3f
11 changed files with 130 additions and 138 deletions

View File

@@ -11,7 +11,7 @@
</rect>
</property>
<property name="windowTitle">
<string>Frame</string>
<string>Aircraft model form</string>
</property>
<layout class="QHBoxLayout" name="vl_AircraftModelForm" stretch="1,1">
<property name="leftMargin">
@@ -28,12 +28,6 @@
</property>
<item>
<widget class="QFrame" name="fr_AircraftModelLeft">
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Plain</enum>
</property>
<layout class="QVBoxLayout" name="vl_AircraftModelFormLeft">
<property name="leftMargin">
<number>0</number>
@@ -125,12 +119,6 @@
<property name="focusPolicy">
<enum>Qt::StrongFocus</enum>
</property>
<property name="frameShape">
<enum>QFrame::StyledPanel</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Raised</enum>
</property>
</widget>
</item>
</layout>

View File

@@ -32,10 +32,10 @@ namespace BlackGui
this->setFrameStyle(QFrame::StyledPanel);
this->setFrameShadow(QFrame::Raised);
this->setAutoFillBackground(true);
this->m_originalStyleSheet = this->styleSheet();
connect(&this->m_resetTimer, &QTimer::timeout, this, &CValidationIndicator::clear);
this->m_resetTimer.setObjectName(this->objectName().append(":").append("resetTimer"));
this->m_resetTimer.start(ResetInterval);
m_originalStyleSheet = this->styleSheet();
connect(&m_resetTimer, &QTimer::timeout, this, &CValidationIndicator::clear);
m_resetTimer.setObjectName(this->objectName().append(":").append("resetTimer"));
m_resetTimer.start(ResetInterval);
}
CValidationIndicator::~CValidationIndicator()
@@ -44,27 +44,27 @@ namespace BlackGui
void CValidationIndicator::passed()
{
this->show();
setBackgroundColor("green");
this->setBackgroundColor("green");
ui->lbl_Icon->setPixmap(CIcons::tick16());
}
void CValidationIndicator::failed()
{
this->show();
setBackgroundColor("red");
this->setBackgroundColor("red");
ui->lbl_Icon->setPixmap(CStatusMessage::convertToIcon(CStatusMessage::SeverityError));
}
void CValidationIndicator::warnings()
{
this->show();
setBackgroundColor("yellow");
this->setBackgroundColor("yellow");
ui->lbl_Icon->setPixmap(CStatusMessage::convertToIcon(CStatusMessage::SeverityWarning));
}
void CValidationIndicator::clear()
{
setBackgroundColor("");
this->setBackgroundColor("");
ui->lbl_Icon->clear();
this->hide();
}
@@ -107,7 +107,7 @@ namespace BlackGui
{
if (colorName.isEmpty())
{
this->setStyleSheet(this->m_originalStyleSheet);
this->setStyleSheet(m_originalStyleSheet);
}
else
{