mirror of https://github.com/BURAI-team/burai.git
fix PDOS
This commit is contained in:
parent
ba4c13f489
commit
a3b18e0c38
|
@ -29,7 +29,8 @@ public class QEFXDosButton extends QEFXGraphButton<QEFXDosViewer> {
|
|||
private static final String BUTTON_FONT_COLOR = "-fx-text-fill: ivory";
|
||||
private static final String BUTTON_BACKGROUND = "-fx-background-color: derive(lightslategrey, -45.0%)";
|
||||
|
||||
public static QEFXResultButtonWrapper<QEFXDosButton> getWrapper(QEFXProjectController projectController, Project project) {
|
||||
public static QEFXResultButtonWrapper<QEFXDosButton> getWrapper(QEFXProjectController projectController,
|
||||
Project project) {
|
||||
if (projectController == null) {
|
||||
return null;
|
||||
}
|
||||
|
@ -50,12 +51,14 @@ public class QEFXDosButton extends QEFXGraphButton<QEFXDosViewer> {
|
|||
}
|
||||
|
||||
List<DosData> dosDataList = projectDos.listDosData();
|
||||
if (dosDataList == null || dosDataList.size() < 2) {
|
||||
//if (dosDataList == null || dosDataList.size() < 2) {
|
||||
if (dosDataList == null || dosDataList.size() < 1) {
|
||||
return null;
|
||||
}
|
||||
|
||||
String dirPath = project == null ? null : project.getDirectoryPath();
|
||||
String fileName = project == null ? null : (project.getPrefixName() + ".pdos_tot");
|
||||
//String fileName = project == null ? null : (project.getPrefixName() + ".pdos_tot");
|
||||
String fileName = project == null ? null : (project.getPrefixName() + ".dos");
|
||||
|
||||
File file = null;
|
||||
if (dirPath != null && fileName != null) {
|
||||
|
|
|
@ -374,7 +374,18 @@ public enum RunningType {
|
|||
|
||||
conditionList.add((project, input) -> true);
|
||||
conditionList.add((project, input) -> true);
|
||||
conditionList.add((project, input) -> true);
|
||||
|
||||
conditionList.add((project, input) -> {
|
||||
QENamelist nmlSystem = input == null ? null : input.getNamelist(QEInput.NAMELIST_SYSTEM);
|
||||
if (nmlSystem == null) {
|
||||
return false;
|
||||
}
|
||||
|
||||
QEValue value = nmlSystem.getValue("occupations");
|
||||
String occup = value == null ? "" : value.getCharacterValue();
|
||||
return !(occup.startsWith("tetrahedra"));
|
||||
});
|
||||
|
||||
break;
|
||||
|
||||
case Project.INPUT_MODE_BAND:
|
||||
|
|
Loading…
Reference in New Issue