void Calculator::changeOperation(QString newOperation) { if (operation != newOperation) { operation = newOperation; emit operationChanged(operation); } }
void EnginioModel::setOperation(Enginio::Operation operation) { Q_D(EnginioModel); if (operation == d->operation()) return; d->setOperation(operation); emit operationChanged(operation); }
Calculator::Calculator(QObject *parent) : QObject(parent), firstOperand(0), secondOperand(0), operation(""), result(0), resultToShow("") { QObject::connect(this, SIGNAL(firstOperandChanged(int)), this, SLOT(getResult())); QObject::connect(this, SIGNAL(secondOperandChanged(int)), this, SLOT(getResult())); QObject::connect(this, SIGNAL(operationChanged(QString)), this, SLOT(getResult())); }
void ServiceOperationStatus::setOperation(const QString &operation) { if (m_operation == operation) { return; } m_operation = operation; updateStatus(); emit operationChanged(); }
void EnginioModel::setOperation(QtCloudServices::Operation operation) { QTC_D(EnginioModel); if (operation == d->operation()) { return; } d->setOperation(operation); emit operationChanged(operation); }