@Override
	public void okCallback() {
		close();

		ClearOptions options = new ClearOptions();

		options.setShouldClear(ClearType.INSTRUCTIONS, instructionsCb.isSelected());
		options.setShouldClear(ClearType.DATA, dataCb.isSelected());
		options.setShouldClear(ClearType.SYMBOLS, symbolsCb.isSelected());
		options.setShouldClear(ClearType.COMMENTS, commentsCb.isSelected());
		options.setShouldClear(ClearType.PROPERTIES, propertiesCb.isSelected());
		options.setShouldClear(ClearType.FUNCTIONS, functionsCb.isSelected());
		options.setShouldClear(ClearType.REGISTERS, registersCb.isSelected());
		options.setShouldClear(ClearType.EQUATES, equatesCb.isSelected());
		options.setShouldClear(ClearType.USER_REFERENCES, userReferencesCb.isSelected());
		options.setShouldClear(ClearType.ANALYSIS_REFERENCES, analysisReferencesCb.isSelected());
		options.setShouldClear(ClearType.IMPORT_REFERENCES, importReferencesCb.isSelected());
		options.setShouldClear(ClearType.DEFAULT_REFERENCES, systemReferencesCb.isSelected());
		options.setShouldClear(ClearType.BOOKMARKS, bookmarksCb.isSelected());

		plugin.clear(options, context);
	}
Gets called when the user clicks on the OK Action for the dialog.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/clear/ClearDialog.java