Fix move handling of C++ Sendable in SmartDashboard and LiveWindow

This commit is contained in:
Peter Johnson
2019-10-17 22:01:31 -07:00
parent d726591ce4
commit 05c25deb7b
6 changed files with 244 additions and 134 deletions

View File

@@ -1,5 +1,5 @@
/*----------------------------------------------------------------------------*/
/* Copyright (c) 2017-2018 FIRST. All Rights Reserved. */
/* Copyright (c) 2017-2019 FIRST. All Rights Reserved. */
/* Open Source Software - may be modified and shared by FRC teams. The code */
/* must be accompanied by the FIRST BSD license file in the root directory of */
/* the project. */
@@ -45,6 +45,12 @@ class SendableBuilderImpl : public SendableBuilder {
*/
std::shared_ptr<nt::NetworkTable> GetTable();
/**
* Return whether this sendable has an associated table.
* @return True if it has a table, false if not.
*/
bool HasTable() const;
/**
* Return whether this sendable should be treated as an actuator.
* @return True if actuator, false if not.
@@ -78,6 +84,11 @@ class SendableBuilderImpl : public SendableBuilder {
*/
void StopLiveWindowMode();
/**
* Clear properties.
*/
void ClearProperties();
void SetSmartDashboardType(const wpi::Twine& type) override;
void SetActuator(bool value) override;
void SetSafeState(std::function<void()> func) override;