QTouchEvents::TouchPoint class migration from Qt5 to Qt6
-
Hello Everyone,
We are migrating our legacy product source code from Qt5 to Qt6. While migration, we found that
QTouchEvents::TouchPoint class earlier had various set APIs(Eg: setState, setPos,setNormalisedPos, setRect, setSceneRect, setScreenRect, etc) which are removed in Qt6 along with the class itself. After going through Qt6 documentation it is discovered that QTouchEvents::TouchPoint class has been replaced with QEventPoint class where we could explicitly set only selected parameters through constructor.As of now we are using QEventPoint class constructor with available parameters being set , going forward it would be great to know -
- The reason for those omission of set APIs
- Is there any alternate class or API implementation apart from QEventPoint for legacy QTouchEvents::TouchPoint set APIs.
- If there are no alternate apart from QEventPoint , then, is setting parameters through constructor enough and ignoring other setters?
Thanks in advance.
-
I found the source of the change but there is not much more colour on the reasoning behind it. The setters were explicitly moved in the private API so constructors look like your only option (unless you want to use the private headers)