Skip to content

Commit

Permalink
CALayer.ShadowOffset fixed
Browse files Browse the repository at this point in the history
macOS has an inverted coordinate system
  • Loading branch information
nor0x committed Jul 12, 2021
1 parent 53e7605 commit 851bf9b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ private void UpdateElevation()

Layer.ShadowColor = NSColor.Black.CGColor;
Layer.ShadowRadius = Math.Abs(adaptedElevation);
Layer.ShadowOffset = new CGSize(0, adaptedElevation);
Layer.ShadowOffset = new CGSize(0, -adaptedElevation);
Layer.ShadowOpacity = opacity;

Layer.MasksToBounds = false;
Expand Down

0 comments on commit 851bf9b

Please sign in to comment.