[libcalamares] Allow checking a Once object for repeat messages

This commit is contained in:
Adriaan de Groot 2022-03-28 12:28:07 +02:00
parent 9b769f0ae4
commit ec3282e15d

View File

@ -364,6 +364,12 @@ public:
*/
void refresh() { m = true; }
/** @brief Is this object "fresh"?
*
* Once a Once-object has printed (once) it is no longer fresh.
*/
operator bool() const { return m; }
private:
mutable bool m = false;
};