src/solaris/classes/sun/awt/X11/XComponentPeer.java
Print this page
rev 9717 : 8039642: Fix raw and unchecked warnings in sun.awt.*
Reviewed-by:
@@ -234,23 +234,25 @@
public boolean isFocusable() {
/* should be implemented by other sub-classes */
return false;
}
- private static Class seClass;
- private static Constructor seCtor;
+ private static Class<?> seClass;
+ private static Constructor<?> seCtor;
final static AWTEvent wrapInSequenced(AWTEvent event) {
try {
if (seClass == null) {
seClass = Class.forName("java.awt.SequencedEvent");
}
if (seCtor == null) {
- seCtor = (Constructor) AccessController.doPrivileged(new PrivilegedExceptionAction() {
- public Object run() throws Exception {
- Constructor ctor = seClass.getConstructor(new Class[] { AWTEvent.class });
+ seCtor = AccessController.doPrivileged(new
+ PrivilegedExceptionAction<Constructor<?>>() {
+ public Constructor<?> run() throws Exception {
+ Constructor<?> ctor = seClass.getConstructor(
+ new Class<?>[] { AWTEvent.class });
ctor.setAccessible(true);
return ctor;
}
});
}
@@ -1319,11 +1321,11 @@
}finally{
XToolkit.awtUnlock();
}
}
- private void addTree(Collection order, Set set, Container cont) {
+ private void addTree(Collection<Long> order, Set<Long> set, Container cont) {
for (int i = 0; i < cont.getComponentCount(); i++) {
Component comp = cont.getComponent(i);
ComponentPeer peer = comp.getPeer();
if (peer instanceof XComponentPeer) {
Long window = Long.valueOf(((XComponentPeer)peer).getWindow());