private void init(Component parent, String title, String message,
String buttonText) {
Panel p = new Panel();
add("Center", new Label(message));
Button btn = new Button(buttonText);
btn.addActionListener(this);
p.add(btn);
add("South", p);
pack();
Dimension dDim = getSize();
if (parent != null) {
Rectangle fRect = parent.getBounds();
setLocation(fRect.x + ((fRect.width - dDim.width) / 2),
fRect.y + ((fRect.height - dDim.height) / 2));
}
}
WPrinterJob.java 文件源码
java
阅读 26
收藏 0
点赞 0
评论 0
项目:lookaside_java-1.8.0-openjdk
作者:
评论列表
文章目录