Fix Plasma (non-Qt) icon scaling with integer scale factors
requested to merge ngraham/plasma-framework:fix-plasma-icon-scaling-for-non-integer-scale-factors into master
This is an alternative to https://invent.kde.org/frameworks/plasma-framework/-/merge_requests/318.
An embarrassing error in 4edb830f caused the function which returns an appropriate scale factor for icons to both take and return integer values rather than floating point values, preventing it from working properly with any scale factor other than an integer scale factor (e.g. 200%). This commit fixes that issue.
Small size System Tray icons at various scales with this MR applied:
100% scale:
150% scale:
200% scale:
(The panel itself has been manually scaled appropriately because this does not happen automatically)