diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2015-05-20 08:16:07 -0400 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2015-06-29 14:18:14 -0400 |
commit | 16c34acc880b3d7e4f257b5cf0c446e756ef8002 (patch) | |
tree | 76196741517478c09ccc96f4d7e3c108c7b791bb /libs/evoral | |
parent | 48fb3e3b486847ed2e24a6906f28989ed5a1b9e9 (diff) |
add operator bool() to Evoral::Beats
Diffstat (limited to 'libs/evoral')
-rw-r--r-- | libs/evoral/evoral/Beats.hpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libs/evoral/evoral/Beats.hpp b/libs/evoral/evoral/Beats.hpp index e0277c4b3d..c419c920f1 100644 --- a/libs/evoral/evoral/Beats.hpp +++ b/libs/evoral/evoral/Beats.hpp @@ -191,6 +191,8 @@ public: bool operator!() const { return _time == 0; } + operator bool() const { return _time != 0; } + static Beats min() { return Beats(DBL_MIN); } static Beats max() { return Beats(DBL_MAX); } static Beats tick() { return Beats(1.0 / PPQN); } |