profile: remove special iOS DPR handling for event icons

On iOS there was special code to scale event icons with DPR
(device pixel ratio). However, that became redundant, when
printing started to also use DPR to scale the icons. Now,
on iOS icon sizes where multiplied twice with DPR.

Let's remove that and, if it is broken, try to fix it
at the correct place.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2021-08-31 09:14:30 +02:00 committed by Dirk Hohndel
parent 1d58553864
commit 5f22de7ebe

View file

@ -21,15 +21,10 @@ DivePixmaps::DivePixmaps(int dpr) : dpr(dpr)
const IconMetrics &metrics = defaultIconMetrics();
#ifndef SUBSURFACE_MOBILE
int sz_bigger = metrics.sz_med + metrics.sz_small; // ex 40px
#else
#if defined(Q_OS_IOS)
// on iOS devices we need to adjust for Device Pixel Ratio
int sz_bigger = metrics.sz_med * metrics.dpr;
#else
// SUBSURFACE_MOBILE, seems a little big from the code,
// but looks fine on device
int sz_bigger = metrics.sz_big + metrics.sz_med;
#endif
#endif
sz_bigger = lrint(sz_bigger * dprf);
int sz_pix = sz_bigger / 2; // ex 20px