Bevy Input Docs : the modules (#9467)

# Objective

Complete the documentation of `bevy_input` (#3492).

This PR is part of a triptych of PRs :
- https://github.com/bevyengine/bevy/pull/9468
- https://github.com/bevyengine/bevy/pull/9469

## Solution

Add documentation on modules in `bevy_input`.
This commit is contained in:
Tristan Guichaoua 2023-08-23 14:44:49 +02:00 committed by GitHub
parent 427ba3074a
commit 20c85b5fc3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 22 additions and 0 deletions

View File

@ -1,3 +1,5 @@
//! The generic axis type.
use bevy_ecs::system::Resource;
use bevy_utils::HashMap;
use std::hash::Hash;

View File

@ -1,3 +1,5 @@
//! The gamepad input functionality.
use crate::{Axis, ButtonState, Input};
use bevy_ecs::event::{Event, EventReader, EventWriter};
use bevy_ecs::{

View File

@ -1,3 +1,5 @@
//! The generic input type.
use bevy_ecs::system::Resource;
use bevy_reflect::{std_traits::ReflectDefault, Reflect};
use bevy_utils::HashSet;

View File

@ -1,3 +1,5 @@
//! The keyboard input functionality.
use crate::{ButtonState, Input};
use bevy_ecs::entity::Entity;
use bevy_ecs::{

View File

@ -1,4 +1,11 @@
#![allow(clippy::type_complexity)]
#![warn(missing_docs)]
//! Input functionality for the [Bevy game engine](https://bevyengine.org/).
//!
//! # Supported input devices
//!
//! `bevy` currently supports keyboard, mouse, gamepad, and touch inputs.
mod axis;
/// Common run conditions
@ -13,6 +20,7 @@ pub mod touchpad;
pub use axis::*;
pub use input::*;
/// Most commonly used re-exported types.
pub mod prelude {
#[doc(hidden)]
pub use crate::{

View File

@ -1,3 +1,5 @@
//! The mouse input functionality.
use crate::{ButtonState, Input};
use bevy_ecs::entity::Entity;
use bevy_ecs::{

View File

@ -1,3 +1,5 @@
//! The touch input functionality.
use bevy_ecs::event::{Event, EventReader};
use bevy_ecs::system::{ResMut, Resource};
use bevy_math::Vec2;

View File

@ -1,3 +1,5 @@
//! The touchpad input functionality.
use bevy_ecs::event::Event;
use bevy_reflect::Reflect;