please include function flatInfoBox. static JWindow showTempWindowInTopRightCorner(JComponent c) { ret showTempWindowInTopRightCorner(c, flatInfoBox_defaultTime); } static JWindow showTempWindowInTopRightCorner(final JComponent c, final double seconds) { if (isHeadless()) null; final JWindow window = showWindowInTopRightCorner(c); disposeWindowAfter(iround(seconds*1000), window); ret window; }