WORK AROUND
There are no workarounds.
|
|
|
EVALUATION
OK, we can always try to do setAlwaysOnTop() and catch the exception for applets. I think, it shouldn't slow down the code noticeably.
|
|
|
SUGGESTED FIX
src/share/classes/javax/swing/Popup.java
@@ -227,19 +227,16 @@
setFocusableWindowState(false);
setName("###overrideRedirect###");
// Popups are typically transient and most likely won't benefit
// from true double buffering. Turn it off here.
getRootPane().setUseTrueDoubleBuffering(false);
- java.security.AccessController.doPrivileged(
- new java.security.PrivilegedAction<Object>() {
- public Object run() {
+ try {
setAlwaysOnTop(true);
- return null;
+ } catch (SecurityException se) {
+ // igonre
}
}
- );
- }
public void update(Graphics g) {
paint(g);
}
|
|
|
EVALUATION
The changes in the Popup class added by the fix for 6580930 were intended for allowing a popup menu to overlap the Windows task bar. It is important for tray icons. However, popup menus in applets don't need to overlap the task bar. Hence, setAlwaysOnTop() in the Popup class can be called only for applications, but not for applets.
The fix idea is to avoid calling setAlwaysOnTop() in the Popup class for applets, but do it for standalone applications.
|
|
|
EVALUATION
In general it is not easy to determine whether one is running in the context of an applet as opposed to an application.
|
|
|