[core] Replace std::function with lightweight Callback in CallbackManager (#14853)
This commit is contained in:
1 parent
fdd5956c1e
commit
8fe36cde23
85 files changed
+319
-385
No files matched your search
@@ -20,6 +20,5 @@ void Button::press() {
|
||||
this->press_action();
|
||||
this->press_callback_.call();
|
||||
}
|
||||
void Button::add_on_press_callback(std::function<void()> &&callback) { this->press_callback_.add(std::move(callback)); }
|
||||
|
||||
} // namespace esphome::button
|
||||
Reference in new issue
Block a user