private static void getOpenModalDialogChidrenForWindow(Window window,
			List<Dialog> openModalDialogs) {

		// add the window before its children, if it is a modal dialog
		if ((window instanceof Dialog)) {
			Dialog dialog = (Dialog) window;
			if (dialog.isVisible() && dialog.isModal()) {
				openModalDialogs.add(dialog);
			}
		}

		// grab any modal children
		Window[] childWindows = window.getOwnedWindows();
		for (Window childWindow : childWindows) {
			getOpenModalDialogChidrenForWindow(childWindow, openModalDialogs);
		}
	}
Returns true if there are one or more modal dialogs displayed in the current JVM.
@return true if there are one or more modal dialogs displayed in the current JVM.
Ghidra/Framework/Generic/src/main/java/generic/util/WindowUtilities.java