@Override
	public boolean isEnabledForContext(ActionContext context) {
		if (context instanceof NavigatableActionContext) {
			return ((NavigatableActionContext) context).getLocation() != null;
		}
		return false;
	}
Actions for creating a selection using two distinct steps. The first time the action is invoked,
it records the current location as the start of a selection. The second time the action is
invoked it creates a selection from the recorded location to the current location.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/codebrowser/MarkAndSelectionAction.java