Inform user about Drone version incompatibility
This commit is contained in:
parent
f01bdd257f
commit
a2b349e5b7
@ -200,6 +200,19 @@ void PortGroup::processVersionCompatibility(PbRpcController *controller)
|
||||
qPrintable(QString::fromStdString(verCompat->notes())));
|
||||
compat = kIncompatible;
|
||||
emit portGroupDataChanged(mPortGroupId);
|
||||
|
||||
QMessageBox msgBox;
|
||||
msgBox.setIcon(QMessageBox::Warning);
|
||||
msgBox.setTextFormat(Qt::RichText);
|
||||
msgBox.setStyleSheet("messagebox-text-interaction-flags: 5");
|
||||
msgBox.setText(tr("The Drone agent at %1:%2 is incompatible with this "
|
||||
"Ostinato version - %3")
|
||||
.arg(serverName())
|
||||
.arg(int(serverPort()))
|
||||
.arg(version));
|
||||
msgBox.setInformativeText(QString::fromStdString(verCompat->notes()));
|
||||
msgBox.exec();
|
||||
|
||||
goto _error_exit;
|
||||
}
|
||||
|
||||
|
@ -590,7 +590,7 @@ void MyService::checkVersion(::google::protobuf::RpcController* controller,
|
||||
}
|
||||
else {
|
||||
response->set_result(OstProto::VersionCompatibility::kIncompatible);
|
||||
response->set_notes(QString("Drone needs client version %1.%2.x")
|
||||
response->set_notes(QString("Drone needs controller version %1.%2.x")
|
||||
.arg(my[0], my[1]).toStdString());
|
||||
static_cast<PbRpcController*>(controller)->TriggerDisconnect();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user