mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-21 01:01:43 +00:00
SendableChooser: Do not automatically add to LiveWindow. (#964)
SendableChooser::InitSendable() is written such that it saves the table being used in an instance variable. This doesn't work if the chooser is added to both LiveWindow and SmartDashboard. Normally it is not added to LiveWindow because the name is empty, but if setName() is called this could still happen. Note adding the same SendableChooser to SmartDashboard with two different names is also not currently supported, for the same reason. The correct solution will be to remove the instance variable, but this is too high risk to implement mid-season, so instead just remove from LiveWindow.
This commit is contained in:
@@ -12,3 +12,8 @@ using namespace frc;
|
||||
const char* SendableChooserBase::kDefault = "default";
|
||||
const char* SendableChooserBase::kOptions = "options";
|
||||
const char* SendableChooserBase::kSelected = "selected";
|
||||
|
||||
/**
|
||||
* Instantiates a SendableChooser.
|
||||
*/
|
||||
SendableChooserBase::SendableChooserBase() : SendableBase(false) {}
|
||||
|
||||
Reference in New Issue
Block a user