提交 c9a43c5e 编写于 作者: A ant

8022512: JLightweightFrame: the content pane should be transparent

Reviewed-by: anthony
上级 9b98edba
......@@ -106,7 +106,7 @@ public final class JLightweightFrame extends LightweightFrame implements RootPan
public JLightweightFrame() {
super();
copyBufferEnabled = "true".equals(AccessController.
doPrivileged(new GetPropertyAction("jlf.copyBufferEnabled", "true")));
doPrivileged(new GetPropertyAction("swing.jlf.copyBufferEnabled", "true")));
add(rootPane, BorderLayout.CENTER);
setFocusTraversalPolicy(new LayoutFocusTraversalPolicy());
......@@ -250,6 +250,11 @@ public final class JLightweightFrame extends LightweightFrame implements RootPan
};
contentPane.setLayout(new BorderLayout());
contentPane.add(component);
if ("true".equals(AccessController.
doPrivileged(new GetPropertyAction("swing.jlf.contentPaneTransparent", "false"))))
{
contentPane.setOpaque(false);
}
setContentPane(contentPane);
contentPane.addContainerListener(new ContainerListener() {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册