public static GGlassPane getGlassPane(Component c) {

		// TODO: validate component has been realized? ...check for window, but that would
		//       then put the onus on the client

		Window window = WindowUtilities.windowForComponent(c);
		if (window instanceof JFrame) {
			JFrame frame = (JFrame) window;
			Component glass = frame.getGlassPane();

			if (!(glass instanceof GGlassPane)) {
				Msg.error(AnimationUtils.class, "GGlassPane not installed on window: " + window,
					new AssertException());
				return null;
			}

			return ((GGlassPane) glass);
		}
		else if (window instanceof JDialog) {
			JDialog frame = (JDialog) window;
			Component glass = frame.getGlassPane();

			if (!(glass instanceof GGlassPane)) {
				Msg.error(AnimationUtils.class, "GGlassPane not installed on window: " + window,
					new AssertException());
				return null;
			}

			return ((GGlassPane) glass);
		}
		return null;
	}
Returns the {@link GGlassPane} for the given component

@param c the component
@return the glass pane
Ghidra/Framework/Docking/src/main/java/docking/util/AnimationUtils.java