ESPHome
2026.5.0
Loading...
Searching...
No Matches
esphome
components
copy
button
copy_button.h
Go to the documentation of this file.
1
#pragma once
2
3
#include "
esphome/core/component.h
"
4
#include "
esphome/components/button/button.h
"
5
6
namespace
esphome::copy
{
7
8
class
CopyButton
:
public
button::Button
,
public
Component
{
9
public
:
10
void
set_source
(
button::Button
*source) {
source_
= source; }
11
void
dump_config
()
override
;
12
13
protected
:
14
void
press_action
()
override
;
15
16
button::Button
*
source_
;
17
};
18
19
}
// namespace esphome::copy
button.h
esphome::Component
Definition
component.h:145
esphome::button::Button
Base class for all buttons.
Definition
button.h:25
esphome::copy::CopyButton
Definition
copy_button.h:8
esphome::copy::CopyButton::source_
button::Button * source_
Definition
copy_button.h:16
esphome::copy::CopyButton::press_action
void press_action() override
Definition
copy_button.cpp:10
esphome::copy::CopyButton::dump_config
void dump_config() override
Definition
copy_button.cpp:8
esphome::copy::CopyButton::set_source
void set_source(button::Button *source)
Definition
copy_button.h:10
component.h
esphome::copy
Definition
copy_binary_sensor.cpp:4
Generated by
1.12.0