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

Print this page

        

@@ -733,10 +733,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;

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