#pragma once #include "interfaces/statusline.hpp" #include "interfaces/statusline_subscriber_adapter.hpp" #include "interfaces/subscriber.hpp" #include #include #include template class StatusLineSubscriberAdapter : public ISubscriber { public: StatusLineSubscriberAdapter( std::shared_ptr status_manager, std::string (*format_func)(std::size_t section_index, const Context &context), const std::vector §ions ) noexcept; void update(const Context &context) noexcept override; private: std::shared_ptr _status_manager; std::string (*_format_func)(std::size_t section_index, const Context &context); std::vector _sections; }; #include "statusline_subscriber_adapter.tpp"