Allow creating ph::phrase from rpl::producer.
This commit is contained in:
parent
40d7581c36
commit
9afafd34eb
2 changed files with 5 additions and 0 deletions
|
|
@ -22,6 +22,10 @@ phrase::phrase(const QString &initial) : value(initial) {
|
|||
}
|
||||
}
|
||||
|
||||
phrase::phrase(rpl::producer<QString> initial) : value(std::move(initial)) {
|
||||
}
|
||||
|
||||
|
||||
now_t start_phrase_count() {
|
||||
PhraseCounter() = 1;
|
||||
return now;
|
||||
|
|
|
|||
1
ui/ph.h
1
ui/ph.h
|
|
@ -26,6 +26,7 @@ struct phrase {
|
|||
phrase(const char (&initial)[Size])
|
||||
: phrase(QString::fromUtf8(initial, Size - 1)) {
|
||||
}
|
||||
explicit phrase(rpl::producer<QString> initial);
|
||||
|
||||
template <typename P = I, typename = Result<P>>
|
||||
Result<P> operator()(ph::now_t, P p = P()) const {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue