void (JFrame frame) { frame.setResizable(false); frame.pack(); Point location = DimensionService.getInstance().getLocation(WelcomeFrame.DIMENSION_KEY, null); Rectangle screenBounds = ScreenUtil.getScreenRectangle(location != null ? location : new Point(0, 0)); frame.setLocation(new Point( screenBounds.x + (screenBounds.width - frame.getWidth()) / 2, screenBounds.y + (screenBounds.height - frame.getHeight()) / 3 )); }