From b95d0e060d76a8d0d104b88ab0b20e5c6a01ee00 Mon Sep 17 00:00:00 2001 From: Evan <53529192+BruceMcRooster@users.noreply.github.com> Date: Sun, 22 Jan 2023 01:09:55 -0500 Subject: [PATCH] [wpilib] XboxController: Fix docs discrepancy (NFC) (#4993) Comments for leftTrigger said they attach to the right trigger of the controller. --- wpilibc/src/main/native/include/frc/XboxController.h | 2 +- .../main/java/edu/wpi/first/wpilibj/XboxController.java | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/wpilibc/src/main/native/include/frc/XboxController.h b/wpilibc/src/main/native/include/frc/XboxController.h index 370e46e3f0..a8bade8916 100644 --- a/wpilibc/src/main/native/include/frc/XboxController.h +++ b/wpilibc/src/main/native/include/frc/XboxController.h @@ -359,7 +359,7 @@ class XboxController : public GenericHID { * Constructs an event instance around the axis value of the left trigger. * The returned trigger will be true when the axis value is greater than 0.5. * @param loop the event loop instance to attach the event to. - * @return an event instance that is true when the right trigger's axis + * @return an event instance that is true when the left trigger's axis * exceeds 0.5, attached to the given event loop */ BooleanEvent LeftTrigger(EventLoop* loop) const; diff --git a/wpilibj/src/main/java/edu/wpi/first/wpilibj/XboxController.java b/wpilibj/src/main/java/edu/wpi/first/wpilibj/XboxController.java index 47195eb1df..c346ae3c82 100644 --- a/wpilibj/src/main/java/edu/wpi/first/wpilibj/XboxController.java +++ b/wpilibj/src/main/java/edu/wpi/first/wpilibj/XboxController.java @@ -539,13 +539,13 @@ public class XboxController extends GenericHID { } /** - * Constructs an event instance around the axis value of the right trigger. The returned trigger + * Constructs an event instance around the axis value of the left trigger. The returned trigger * will be true when the axis value is greater than {@code threshold}. * * @param threshold the minimum axis value for the returned {@link BooleanEvent} to be true. This * value should be in the range [0, 1] where 0 is the unpressed state of the axis. * @param loop the event loop instance to attach the event to. - * @return an event instance that is true when the right trigger's axis exceeds the provided + * @return an event instance that is true when the left trigger's axis exceeds the provided * threshold, attached to the given event loop */ public BooleanEvent leftTrigger(double threshold, EventLoop loop) { @@ -553,11 +553,11 @@ public class XboxController extends GenericHID { } /** - * Constructs an event instance around the axis value of the right trigger. The returned trigger + * Constructs an event instance around the axis value of the left trigger. The returned trigger * will be true when the axis value is greater than 0.5. * * @param loop the event loop instance to attach the event to. - * @return an event instance that is true when the right trigger's axis exceeds the provided + * @return an event instance that is true when the left trigger's axis exceeds the provided * threshold, attached to the given event loop */ public BooleanEvent leftTrigger(EventLoop loop) {