private boolean isOnlyFrame(Window window) {
		if (!(window instanceof Frame)) {
			return false;
		}

		//@formatter:off
		long n = getAllWindows()
			.stream()
			.filter(w -> w instanceof Frame && w != window)
			.count()
			;
		//@formatter:on
		return n > 0;
	}
Will try to close dialogs prompting for changes to be saved, whether from program changes
or from tool config changes.
Ghidra/Framework/Docking/src/main/java/docking/test/AbstractDockingTest.java