void mousePressed(MouseEvent e) {
			requestFocus();
			didDrag = false;
			if (e.getButton() != MouseEvent.BUTTON1) {
				return;
			}
			mouseDownX = e.getX();
			mouseDownY = e.getY();

			FieldLocation locationForPoint = getLocationForPoint(mouseDownX, mouseDownY);

			if (isAddToContiguousSelectionActivator(e)) {
				selectionHandler.beginSelectionSequence(cursorPosition);
				selectionHandler.updateSelectionSequence(locationForPoint);
			}
			else if (isAddRemoveDisjointSelectionActivator(e)) {
				AnchoredLayout layout = findLayoutAt(mouseDownY);
				if (layout == null) {
					// the user must have moused over an area without a layout
					return;
				}

				BigInteger index = layout.getIndex();
				BigInteger size = BigInteger.valueOf(layout.getIndexSize());
				FieldLocation start = new FieldLocation(index);
				FieldLocation end = new FieldLocation(index.add(size));
				selectionHandler.beginSelectionSequence(start);
				selectionHandler.setRemoveFromSelection(selection.contains(start));
				selectionHandler.updateSelectionSequence(end);
			}
			else if (!selection.contains(locationForPoint)) {
				selectionHandler.clearSelection();
				selectionHandler.beginSelectionSequence(locationForPoint);
			}
		}
Notifies all listeners that the selection changed.
Ghidra/Framework/Docking/src/main/java/docking/widgets/fieldpanel/FieldPanel.java