From ed529a7cae34ddae825032e4c44dd8c21e87b7c7 Mon Sep 17 00:00:00 2001 From: Emmet_v15 Date: Mon, 10 Mar 2025 22:00:45 +0000 Subject: [PATCH] docs: Fix incorrect cycle_modes function documentation (#18237) Update the documentation comment to correctly state that the function responds to spacebar presses rather than mouse clicks. This aligns the documentation with the actual implementation, which was already using keyboard input. # Objective - Fix incorrect documentation comment for the cycle_modes function that inaccurately described using mouse input when the implementation actually uses spacebar. - This ensures documentation accuracy and prevents confusion for new learners. ## Solution - Updated the documentation comment to correctly state that the function responds to spacebar presses rather than mouse clicks. - The code functionality remains unchanged. --- examples/window/low_power.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/window/low_power.rs b/examples/window/low_power.rs index cc75c9df6e..b8893f807c 100644 --- a/examples/window/low_power.rs +++ b/examples/window/low_power.rs @@ -112,7 +112,7 @@ pub(crate) mod test_setup { window::RequestRedraw, }; - /// Switch between update modes when the mouse is clicked. + /// Switch between update modes when the spacebar is pressed. pub(crate) fn cycle_modes( mut mode: ResMut, button_input: Res>,