private void addListeners() {
		final JTable table = referencesPanel.getTable();
		table.getSelectionModel().addListSelectionListener(e -> {
			if (!e.getValueIsAdjusting()) {
				selectionAction.setEnabled(table.getSelectedRowCount() > 0);
			}
		});

		// callback to know when to update our state
		referencesPanel.addTableModelListener(e -> {
			// invalidate our cache
			addressSetCache = null;
			updateHighlights();

			setTitle(generateTitle() + " - " + table.getRowCount() + " locations");
		});
	}
Sets the new LocationDescriptor and updates the providers table contents. 
@param locationDescriptor the new descriptor
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/navigation/locationreferences/LocationReferencesProvider.java