use of com.jetbrains.edu.learning.courseFormat.StudyStatus in project intellij-community by JetBrains.
the class LessonDirectoryNode method updateImpl.
@Override
protected void updateImpl(PresentationData data) {
StudyStatus status = myLesson.getStatus();
boolean isSolved = status != StudyStatus.Solved;
JBColor color = isSolved ? JBColor.BLACK : LIGHT_GREEN;
Icon icon = isSolved ? InteractiveLearningIcons.Lesson : InteractiveLearningIcons.LessonCompl;
updatePresentation(data, myLesson.getName(), color, icon, null);
}
use of com.jetbrains.edu.learning.courseFormat.StudyStatus in project intellij-community by JetBrains.
the class TaskDirectoryNode method updateImpl.
@Override
protected void updateImpl(PresentationData data) {
StudyStatus status = myTask.getStatus();
String subtaskInfo = myTask.hasSubtasks() ? getSubtaskInfo() : null;
if (status == StudyStatus.Unchecked) {
updatePresentation(data, myTask.getName(), JBColor.BLACK, InteractiveLearningIcons.Task, subtaskInfo);
return;
}
boolean isSolved = status == StudyStatus.Solved;
JBColor color = isSolved ? LIGHT_GREEN : JBColor.RED;
Icon icon = isSolved ? InteractiveLearningIcons.TaskCompl : InteractiveLearningIcons.TaskProbl;
updatePresentation(data, myTask.getName(), color, icon, subtaskInfo);
}
Aggregations