mirror of
https://github.com/tnodir/fort
synced 2024-11-14 22:19:05 +00:00
UI: GraphPage: Simplify setupGraphColors() to have less lines
This commit is contained in:
parent
9f21147705
commit
e62381e3ff
@ -256,6 +256,12 @@ void GraphPage::setupColorsBox()
|
||||
}
|
||||
|
||||
void GraphPage::setupGraphColors()
|
||||
{
|
||||
setupGraphColors1();
|
||||
setupGraphColors2();
|
||||
}
|
||||
|
||||
void GraphPage::setupGraphColors1()
|
||||
{
|
||||
m_graphColor = ControlUtil::createLabelColor(
|
||||
iniUser()->graphWindowColor(), iniUser()->graphWindowDarkColor(),
|
||||
@ -289,7 +295,10 @@ void GraphPage::setupGraphColors()
|
||||
iniUser()->setGraphWindowDarkColorOut(v);
|
||||
ctrl()->setIniUserEdited();
|
||||
});
|
||||
}
|
||||
|
||||
void GraphPage::setupGraphColors2()
|
||||
{
|
||||
m_graphAxisColor = ControlUtil::createLabelColor(
|
||||
iniUser()->graphWindowAxisColor(), iniUser()->graphWindowDarkAxisColor(),
|
||||
[&](const QColor &v) {
|
||||
|
@ -31,6 +31,8 @@ private:
|
||||
QLayout *setupTrafUnitsLayout();
|
||||
void setupColorsBox();
|
||||
void setupGraphColors();
|
||||
void setupGraphColors1();
|
||||
void setupGraphColors2();
|
||||
|
||||
private:
|
||||
QGroupBox *m_gbGraph = nullptr;
|
||||
|
Loading…
Reference in New Issue
Block a user