checkin for saving current state
This commit is contained in:
@@ -5,23 +5,35 @@
|
||||
|
||||
CheckUpdateActivationCommand::CheckUpdateActivationCommand(QString const &command,
|
||||
Worker *worker,
|
||||
int nextCommandIndex,
|
||||
int start_timeout,
|
||||
int finish_timeout)
|
||||
: UpdateCommand(command, worker, start_timeout, finish_timeout) {
|
||||
: UpdateCommand(command, worker, nextCommandIndex, start_timeout, finish_timeout) {
|
||||
}
|
||||
|
||||
void CheckUpdateActivationCommand::finished(int exitCode, QProcess::ExitStatus exitStatus) {
|
||||
qCritical() << __func__ << ":" << __LINE__ << command() << exitCode << exitStatus;
|
||||
return UpdateCommand::finished(exitCode, exitStatus);
|
||||
}
|
||||
|
||||
void CheckUpdateActivationCommand::readyReadStandardOutput() {
|
||||
QProcess *p = (QProcess *)sender();
|
||||
if (p) {
|
||||
QString s = p->readAllStandardOutput();
|
||||
|
||||
// TODO
|
||||
Worker *w = worker();
|
||||
if (w) {
|
||||
//static constexpr const char *UPDATE_NOT_NECESSARY{"not necessary"};
|
||||
//static constexpr const char *UPDATE_NOT_REQUESTED{"not requested"};
|
||||
//static constexpr const char *UPDATE_REQUESTED{"requested"};
|
||||
emit w->showUpdateRequest(UpdateCommand::UPDATE_REQUESTED);
|
||||
QString s = p->readAllStandardOutput().trimmed();
|
||||
if (s == UpdateCommand::UPDATE_REQUESTED) {
|
||||
emit w->showUpdateRequest(UpdateCommand::UPDATE_REQUESTED);
|
||||
} else
|
||||
if (s == UpdateCommand::UPDATE_NOT_NECESSARY) {
|
||||
emit w->showUpdateRequest(UpdateCommand::UPDATE_NOT_NECESSARY);
|
||||
} else
|
||||
if (s == UpdateCommand::UPDATE_NOT_REQUESTED) {
|
||||
emit w->showUpdateRequest(UpdateCommand::UPDATE_NOT_REQUESTED);
|
||||
} else
|
||||
if (s == UpdateCommand::NO_CUSTOMER_REPOSITORY) {
|
||||
emit w->showUpdateRequest(UpdateCommand::NO_CUSTOMER_REPOSITORY);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user