diff options
| author | Carl Hetherington <cth@carlh.net> | 2022-12-01 20:00:09 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2022-12-01 20:00:09 +0100 |
| commit | a733da8088152a2487691629753fe8a2addfa5a3 (patch) | |
| tree | 789f3ddf26e56fb7733614f655474d7af0e3e1ed /src/lib | |
| parent | 704e1112538d809fd55bd7f25385eaa5d064966c (diff) | |
Save playlist when content is added, moved or removed.
Diffstat (limited to 'src/lib')
| -rw-r--r-- | src/lib/spl.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/lib/spl.h b/src/lib/spl.h index b002a0882..f55a9fe1f 100644 --- a/src/lib/spl.h +++ b/src/lib/spl.h @@ -114,6 +114,21 @@ public: Changed(Change::NAME); } + void add(SPLEntry e) { + SPL::add(e); + Changed(Change::CONTENT); + } + + void remove(std::size_t index) { + SPL::remove(index); + Changed(Change::CONTENT); + } + + void swap(size_t a, size_t b) { + SPL::swap(a, b); + Changed(Change::CONTENT); + } + boost::signals2::signal<void (Change)> Changed; }; |
