Skip to content

Commit

Permalink
Merge pull request #1946 from cwensley/curtis/wpf-current-transform
Browse files Browse the repository at this point in the history
Fix possible NRE with Graphics.CurrentTransform
  • Loading branch information
cwensley authored May 2, 2021
2 parents 4a44f80 + b729d5c commit 4b4de9b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Eto.Wpf/Drawing/GraphicsHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,7 @@ public void RestoreTransform()

public IMatrix CurrentTransform
{
get { return transforms.Current != null ? transforms.Current.Clone() : Matrix.Create(); }
get { return transforms?.Current?.Clone() ?? Matrix.Create(); }
}

void RewindOffset()
Expand Down

0 comments on commit 4b4de9b

Please sign in to comment.