mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-08-01 02:56:34 -04:00
Hide implementation of MessageHandlerMap.
This commit is contained in:
parent
2aa8ae0d1f
commit
a7226820d0
9 changed files with 95 additions and 78 deletions
|
@ -26,13 +26,15 @@
|
|||
namespace ui {
|
||||
|
||||
void Channel::on_show() {
|
||||
context().message_map[Message::ID::ChannelStatistics] = [this](const Message* const p) {
|
||||
this->on_statistics_update(static_cast<const ChannelStatisticsMessage*>(p)->statistics);
|
||||
};
|
||||
context().message_map.register_handler(Message::ID::ChannelStatistics,
|
||||
[this](const Message* const p) {
|
||||
this->on_statistics_update(static_cast<const ChannelStatisticsMessage*>(p)->statistics);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
void Channel::on_hide() {
|
||||
context().message_map[Message::ID::ChannelStatistics] = nullptr;
|
||||
context().message_map.unregister_handler(Message::ID::ChannelStatistics);
|
||||
}
|
||||
|
||||
void Channel::paint(Painter& painter) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue