public static void show(Window frame) {
//		if (frame instanceof JFrame) {
////			((JFrame)frame).getContentPane().pa
//		} else {
		if (frame.getPreferredSize() == null) {
			frame.pack();
		} else {
			frame.setSize(frame.getPreferredSize());
		}
		Point location = frame.getLocation();
		if (location==null || (location.x==0 && location.y ==0)) {
			SwingUtil.centerlize(frame);
		}
//		}
		frame.setVisible(true);
	}