Changed mechanism of Source Callback and Input Mapping

Session stores list of all callback instances and reacts on input release by calling the reverse callback if it exists, or by finishing the ongoing callback. This means the behavior of Callbacks is different for those who are reversible (i.e. returns a non-null reverse) from those which do not have reverse. The reversible callbacks enforce to be exclusive while active (key pressed), others can be repeated and complementary (run in parallel).
This commit is contained in:
Bruno Herbelin
2023-02-09 23:18:24 +01:00
parent 7433772606
commit 128e8834e8
8 changed files with 103 additions and 165 deletions

View File

@@ -149,6 +149,7 @@ public:
// add callback to each update
void call(SourceCallback *callback, bool override = false);
void finish(SourceCallback *callback);
// update mode
inline bool active () const { return active_; }