@Override
	public CategoryPath getCategoryPath(TreePath selectedPath) {
		DataTypeChooserDialog dialog = new DataTypeChooserDialog(this);
		dialog.setCategorySelectionMode(true);
		dialog.setShowProgramArchiveOnly(true);

		if (selectedPath != null) {
			dialog.setSelectedPath(selectedPath);
		}
		tool.showDialog(dialog);
		return dialog.getSelectedCategoryPath();
	}
Create the actions for the menu on the tool.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/datamgr/DataTypeManagerPlugin.java