src/macosx/classes/sun/lwawt/macosx/CPlatformWindow.java

Print this page

        

@@ -735,10 +735,19 @@
         CWrapper.NSWindow.setOpaque(getNSWindowPtr(), isOpaque);
         if (!isOpaque) {
             long clearColor = CWrapper.NSColor.clearColor();
             CWrapper.NSWindow.setBackgroundColor(getNSWindowPtr(), clearColor);
         }
+
+        //This is a temporary workaround. Looks like after 7124236 will be fixed
+        //the correct place for invalidateShadow() is CGLayer.drawInCGLContext.
+        SwingUtilities.invokeLater(new Runnable() {
+            @Override
+            public void run() {
+                invalidateShadow();
+            }
+        });
     }
 
     @Override
     public void enterFullScreenMode() {
         isFullScreenMode = true;

@@ -803,10 +812,14 @@
         }
 
         nativeSetEnabled(getNSWindowPtr(), !blocked);
     }
 
+    public final void invalidateShadow(){
+        nativeRevalidateNSWindowShadow(getNSWindowPtr());
+    }
+
     // ----------------------------------------------------------------------
     //                          UTILITY METHODS
     // ----------------------------------------------------------------------
 
     /*