| 218 | } |
| 219 | |
| 220 | void CodeInput::requestCode() { |
| 221 | const auto result = collectDigits(); |
| 222 | if (result.size() == _digitsCountMax) { |
| 223 | _codeCollected.fire_copy(result); |
| 224 | } else { |
| 225 | findEmptyAndPerform([&](int i) { _digits[i]->shake(); }); |
| 226 | } |
| 227 | } |
| 228 | |
| 229 | rpl::producer<QString> CodeInput::codeCollected() const { |
| 230 | return _codeCollected.events(); |
no test coverage detected