Refactor QGeoSimplify into a namespace, simplify, remove dead code


The class had only static functions, with the internal helpers declared
as protected. Move those helpers into an anonymous namespace inside the
translation unit.

This helped identify significant amounts of dead code. Remove it,
simplify the remaining function, and fix the coding style, including
replacing int with qsizetype.

Pick-to: 6.2
Change-Id: I4936b8c5f53323e06db082b5378fa185c562a948
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
commit42e4a7df150a96ef94166837c59bcbf167ff5be8
parent6786f0fc1505d5a1b9ef3341e06bc209e463304a
authorVolker Hilsheimer <volker.hilsheimer@qt.io>
committerVolker Hilsheimer <volker.hilsheimer@qt.io>
commit timeMon, 12 Sep 2022 22:19:46 +0200