microsoft / FluentDarkModeKit

A library for backporting Dark Mode in iOS
MIT License
1.63k stars 125 forks source link

DMDynamicImageProxy may crash when proxying resizable Image #56

Closed linlinyao1 closed 2 years ago

linlinyao1 commented 4 years ago

(UIImage *)resizableImageWithCapInsets:(UIEdgeInsets)capInsets resizingMode:(UIImageResizingMode)resizingMode returns _UIResizableImage, and when using DMDynamicImageProxy as _UIResizableImage in a UIButton, it tries to access to image's ivar which is not aligned with DMDynamicImageProxy class

linlinyao1 commented 4 years ago

change DMDynamicImageProxy from NSProxy to NSObject solve this problem

levinli303 commented 4 years ago

@imWildCat @linlinyao1 do you still have sample codes that can reproduce it?

levinli303 commented 2 years ago

Closing as there is no sample code provided.