@AliQT
OK, I have done a version which compiles, splitting all 3 classes into their own source files.
It's a .zip file containing just the sources. I have uploaded to a free site where I understand the link remains available for a week. It is https://limewire.com/d/sFtIk#JbakOrsCmy . I created/uploaded it via https://file.io . So far as I understand this a common site and is all safe & legit, but obviously access at your own risk.
There are indeed issues which affect the normally-more-straightforward processes of splitting C++ classes into separate files. These were due to Qt features including Q_PROPERTY and QScopedPointer. I commented these where the problems arose and put in my replacement. I believe the functionality is the same. I agree there are tricky issues here. If what I have done is indeed required then I agree it would not be easy for a beginner.
I do not do Qt under Windows so I cannot actually compile, let alone test, the stuff to do with QAxObject (you do realise that is Windows only, right?). I have commented out all the lines which which can only compile under Windows, you can put them back in.
You will have to test with COM/ActiveX --- like the VB example they give on the example page --- to verify whether the couple of changes I was forced to make lead to any problems.
I may return to this to understand whether I could have made it work without having to make the changes I did.