Compare commits

...

9 Commits
v0.7.1 ... main

Author SHA1 Message Date
76c64f6683 Release
All checks were successful
Test / test (ubuntu-latest) (push) Successful in 1m22s
2025-01-03 14:08:55 -05:00
e0797633bb Update CHANGELOG. 2025-01-03 14:08:44 -05:00
3eca9f067a fix: No need for *any* ctrl-c handling since Bevy already does the right thing. 2025-01-03 14:08:21 -05:00
fb63b2ba79 Release
Some checks failed
Test / test (ubuntu-latest) (push) Failing after 1m18s
2025-01-03 13:52:45 -05:00
621578e756 Update CHANGELOG. 2025-01-03 13:52:26 -05:00
d51ef53f49 fix: Don't explicitly add ctrl-c-handling plugin as it is likely included in related groups. 2025-01-03 13:51:59 -05:00
4fa1e45e93 Release
Some checks failed
Test / test (ubuntu-latest) (push) Failing after 1m35s
2025-01-03 13:42:24 -05:00
50903a8170 Update CHANGELOG. 2025-01-03 13:42:08 -05:00
d8b38e9444 fix: Actually integrate Bevy 0.15's handling for ctrlc. 2025-01-03 13:41:18 -05:00
3 changed files with 20 additions and 14 deletions

View File

@ -2,6 +2,24 @@
All notable changes to this project will be documented in this file. All notable changes to this project will be documented in this file.
## Version 0.7.4 - 2025-01-03
### Bug Fixes
- No need for *any* ctrl-c handling since Bevy already does the right thing.
## Version 0.7.3 - 2025-01-03
### Bug Fixes
- Don't explicitly add ctrl-c-handling plugin as it is likely included in related groups.
## Version 0.7.2 - 2025-01-03
### Bug Fixes
- Actually integrate Bevy 0.15's handling for `ctrlc`.
## Version 0.7.1 - 2024-12-05 ## Version 0.7.1 - 2024-12-05
### Miscellaneous Tasks ### Miscellaneous Tasks

View File

@ -3,7 +3,7 @@ name = "bevy_full_throttle"
description = "Enable CPU performance mode for Bevy games" description = "Enable CPU performance mode for Bevy games"
license = "MIT OR Apache-2.0" license = "MIT OR Apache-2.0"
repository = "https://labs.lightsout.games/projects/bevy_full_throttle" repository = "https://labs.lightsout.games/projects/bevy_full_throttle"
version = "0.7.1" version = "0.7.4"
edition = "2021" edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
@ -12,7 +12,6 @@ edition = "2021"
bevy = { version = "0.15", default-features = false, features = [ bevy = { version = "0.15", default-features = false, features = [
"bevy_window", "bevy_window",
] } ] }
ctrlc = "3"
[target.'cfg(windows)'.dependencies] [target.'cfg(windows)'.dependencies]
windows = { version = "0.58", features = [ windows = { version = "0.58", features = [

View File

@ -1,9 +1,5 @@
#[allow(unused_imports)] #[allow(unused_imports)]
use bevy::{ use bevy::{app::AppExit, prelude::*, window::WindowFocused};
app::{AppExit, TerminalCtrlCHandlerPlugin},
prelude::*,
window::WindowFocused,
};
#[cfg(windows)] #[cfg(windows)]
use windows::{ use windows::{
core::GUID, core::GUID,
@ -29,13 +25,6 @@ fn setup(mut commands: Commands) {
if let Some(active) = active.as_ref() { if let Some(active) = active.as_ref() {
let scheme = DefaultScheme(*active); let scheme = DefaultScheme(*active);
commands.insert_resource(scheme); commands.insert_resource(scheme);
ctrlc::set_handler(move || {
Power::PowerSetActiveScheme(None, Some(active))
.ok()
.expect("Failed to set power scheme");
TerminalCtrlCHandlerPlugin::gracefully_exit();
})
.expect("Failed to set exit handler");
} }
} }
#[cfg(not(windows))] #[cfg(not(windows))]