Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Romain De Laage De Bellefaye
LO21-projet
Commits
89065203
Commit
89065203
authored
Jun 12, 2021
by
Leon Do Castelo
Browse files
Update paramalpha.cpp
parent
4878bd08
Pipeline
#79799
passed with stage
in 15 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/paramalpha.cpp
View file @
89065203
...
...
@@ -29,7 +29,7 @@ ParamAlpha::ParamAlpha(const int nbEtats, const QWidget *parent): QWidget(), nb(
form
[
i
]
->
addRow
(
"Bleu:"
,
blue
[
i
]);
}
connect
(
valider
,
SIGNAL
(
clicked
()),
this
,
SLOT
(
valide
()));
connect
(
valider
,
SIGNAL
(
clicked
()),
this
,
SLOT
(
valide
()));
connect
(
valider
,
SIGNAL
(
clicked
()),
parent
,
SLOT
(
changerVoisinage
()));
connect
(
valider
,
SIGNAL
(
clicked
()),
parent
,
SLOT
(
paramRegle
()));
connect
(
valider
,
SIGNAL
(
clicked
()),
this
,
SLOT
(
close
()));
...
...
@@ -50,13 +50,14 @@ ParamAlpha::ParamAlpha(const int nbEtats, const QWidget *parent): QWidget(), nb(
if
(
nb
==
8
)
general
->
addLayout
(
form
[
7
],
2
,
1
,
1
,
1
);
general
->
addWidget
(
valider
,
2
,
2
,
1
,
1
,
Qt
::
AlignBottom
);
}
void
ParamAlpha
::
valide
()
{
Automate
::
getInstance
().
getEnsemble
().
reset
();
for
(
int
i
=
0
;
i
<
nb
;
++
i
)
Automate
::
getInstance
().
getEnsemble
().
ajouterEtat
(
i
,
label
[
i
]
->
text
().
toStdString
(),
red
[
i
]
->
value
(),
green
[
i
]
->
value
(),
blue
[
i
]
->
value
());
this
->
close
();
}
void
ParamAlpha
::
valide
()
{
Automate
::
getInstance
().
getEnsemble
().
reset
();
for
(
int
i
=
0
;
i
<
nb
;
++
i
)
{
Automate
::
getInstance
().
getEnsemble
().
ajouterEtat
(
i
,
label
[
i
]
->
text
().
toStdString
(),
red
[
i
]
->
value
(),
green
[
i
]
->
value
(),
blue
[
i
]
->
value
());
}
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment