LastMonopoly / scaled_app

Scale the entire UI design proportionally, useful when your UI design is fixed-width.
https://pub.dev/packages/scaled_app
BSD 3-Clause "New" or "Revised" License
14 stars 8 forks source link

Optimize ScaleFactorCallback #4

Closed elMuso closed 1 year ago

elMuso commented 1 year ago

When i used this library the ScaleFactorCallback was not only called on every screen update, but also on every pointer update. I don't know if this is the intended behaviour but on web this triggers the function over 300 times on a mouse movement.

This fix only calls ScaleFactorCallback when the screen changes.

LastMonopoly commented 1 year ago

@elMuso Great work, thanks a lot!

LastMonopoly commented 1 year ago

Updated in version v1.1.0