1
0
Fork 0
mirror of https://gitlab.com/kauron/jstudy synced 2024-12-22 08:23:33 +01:00

Corrected repeat mistakes, it kept on increasing the bars

This commit is contained in:
Carlos Galindo 2016-06-12 13:40:15 +02:00
parent e8111c0714
commit f61c0a40ba
Signed by: kauron
GPG key ID: 83E68706DEE119A3

View file

@ -53,6 +53,8 @@ public class TestController implements Initializable {
// Remove the question from the pool if the question was correctly answered or there is no repetition
if (right || !AppConfig.repeatWrong) {
list.remove(current);
progress.setProgress(progress.getProgress() + 1.0/total);
progressLabel.setText((int) (progress.getProgress() * total) + "/" + total);
if (list.size() == 0) {
answer.setText("");
answer.setDisable(true);
@ -60,8 +62,6 @@ public class TestController implements Initializable {
return;
}
}
progress.setProgress(progress.getProgress() + 1.0/total);
progressLabel.setText((int) (progress.getProgress() * total) + "/" + total);
onSkipAction(event);
}