Skip to content

Commit

Permalink
Update ImportGraphFilePlugin.java (#2263)
Browse files Browse the repository at this point in the history
Fix to clear filename when filetype changes
  • Loading branch information
andromeda-224 authored Feb 3, 2025
1 parent 2201019 commit 57f5636
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,11 @@ public PluginParameters createParameters() {

@SuppressWarnings("unchecked") //FILE_NAME_PARAMETER_ID is always of type FileParameter
final PluginParameter<FileParameterValue> fileName = (PluginParameter<FileParameterValue>) parameters.get(FILE_NAME_PARAMETER_ID);
// clear filename string on file type change
if (!fileName.getStringValue().isEmpty()) {
fileName.getParameterValue().setStringValue("");
fileName.fireChangeEvent(ParameterChange.VALUE);
}
FileParameterType.setFileFilters(fileName, selection.getExtensionFilter());
}
});
Expand Down

0 comments on commit 57f5636

Please sign in to comment.