private void addJarCallback() {

		setStatusMessage(EditPluginPathDialog.EMPTY_STATUS);

		GhidraFileChooser fileChooser = new GhidraFileChooser(getComponent());
		fileChooser.setCurrentDirectory(new File(System.getProperty("user.home")));
		fileChooser.setFileSelectionMode(GhidraFileChooserMode.FILES_ONLY);
		fileChooser.setFileFilter(JAR_FILTER);
		fileChooser.setApproveButtonToolTipText("Choose Plugin Jar File");
		fileChooser.setApproveButtonText("Add Jar File");

		fileChooser.setLastDirectoryPreference(Preferences.LAST_PATH_DIRECTORY);

		File dir = fileChooser.getSelectedFile();
		if (dir != null) {
			try {
				String dirPath = dir.getCanonicalPath();
				if (!listModel.contains(dirPath)) {
					listModel.addElement(dirPath);
					pluginPathsChanged = true;
					setApplyEnabled(true);
				}
				else {
					setStatusMessage(dirPath + " is already in the list.");
				}
			}
			catch (IOException e) {
				setStatusMessage(e.getMessage());
			}
		}

		fileChooser.dispose();
	}
Reset the list of paths each time the dialog is shown
@param tool the tool
Ghidra/Framework/Project/src/main/java/ghidra/framework/main/EditPluginPathDialog.java