Again, thinking about having it as public API: you should probably document these methods, answering questions like: Is it a blocking call or does it return immediately?
What's the user expected to do with those return values? I don't see you using them for anything.
"""
connect(QCoreApplication::instance(), &QCoreApplication::aboutToQuit, d->serverWorker, &MirServerWorker::stop, Qt::DirectConnection); // see FIXME in MirServerWorker
"""
"""
if (!d->serverWorker->waitForMirStartup())
{
qCritical() << "ERROR: QMirServer - Mir failed to start"; QCoreApplication::quit();
"""
Isn't QMirServer going out of its territory when it modifies QCoreApplication directly like that?
I would expect the user of QMirServer to do this instead, like:
"""
if (!qmirServer->run()) {
QCoreApplication::quit();
}
"""
In src/platforms/ mirserver/ qmirserver. h
"""
bool run();
Q_SLOT bool stop();
"""
Again, thinking about having it as public API: you should probably document these methods, answering questions like: Is it a blocking call or does it return immediately?
What's the user expected to do with those return values? I don't see you using them for anything.
""" QCoreApplicatio n::instance( ), &QCoreApplicati on::aboutToQuit ,
d- >serverWorker, &MirServerWorke r::stop, Qt::DirectConne ction); // see FIXME in MirServerWorker
connect(
"""
""" er->waitForMirS tartup( ))
QCoreApplicati on::quit( );
if (!d->serverWork
{
qCritical() << "ERROR: QMirServer - Mir failed to start";
"""
Isn't QMirServer going out of its territory when it modifies QCoreApplication directly like that?
I would expect the user of QMirServer to do this instead, like:
""" >run()) { ation:: quit();
if (!qmirServer-
QCoreApplic
}
"""