Hide naga info logs & Derive PartialEq on Timer and Stopwatch (#8664)

# Objective

- Fixes https://github.com/bevyengine/bevy/issues/8662
- Fixes https://github.com/bevyengine/bevy/issues/8663

---------

Co-authored-by: Andres O. Vela <andresovela@users.noreply.github.com>
This commit is contained in:
张林伟 2023-05-24 23:16:15 +08:00 committed by GitHub
parent 897daa0ad6
commit a9ca40506e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 3 deletions

View File

@ -102,7 +102,7 @@ pub struct LogPlugin {
impl Default for LogPlugin {
fn default() -> Self {
Self {
filter: "wgpu=error".to_string(),
filter: "wgpu=error,naga=warn".to_string(),
level: Level::INFO,
}
}

View File

@ -23,7 +23,7 @@ use bevy_utils::Duration;
/// assert!(stopwatch.paused());
/// assert_eq!(stopwatch.elapsed_secs(), 0.0);
/// ```
#[derive(Clone, Debug, Default, Reflect, FromReflect)]
#[derive(Clone, Debug, Default, PartialEq, Eq, Reflect, FromReflect)]
#[cfg_attr(feature = "serialize", derive(serde::Deserialize, serde::Serialize))]
#[reflect(Default)]
pub struct Stopwatch {

View File

@ -9,7 +9,7 @@ use bevy_utils::Duration;
/// exceeded, and can still be reset at any given point.
///
/// Paused timers will not have elapsed time increased.
#[derive(Clone, Debug, Default, Reflect, FromReflect)]
#[derive(Clone, Debug, Default, PartialEq, Eq, Reflect, FromReflect)]
#[cfg_attr(feature = "serialize", derive(serde::Deserialize, serde::Serialize))]
#[reflect(Default)]
pub struct Timer {