[screenlocker] Share QQmlEngine between all views in the greeter
Review Request #124947 - Created Aug. 27, 2015 and submitted
In a multi-screen setup we have multiple views showing the same Qml scene. Let's share the engine for all views.
This makes creating a second view basically free (from timing perspective)
It might be nice to check if this pointer isn't 0 after the cast.
Also, coding style.
Or the other way around, but then all the others need to change ;)
Not quite sure which one is appropiate here, the style guideline isn't clear on this. I think the one with the space is the adviced way (which would mean that the rest needs to change, not this line)
Just a suggestion, not an issue. Can't this (and m_views where this one is inserted later on) be a smart pointer? That makes it go out of scope instead of relying on qDeleteAll(m_views) which is done in the destructor. Both methods work just fine, but i - personal preference - prefer smart pointers :)
QuickViewSharedEngine * view
I can't really give a +1.. I just don't know this or the implications it might have.
So just a style review then :)