Update accesskit and accesskit_winit requirements (#18285)
# Objective - Fixes #18225 ## Solution - Updated `accesskit` version requirement from 0.17 to 0.18 - Updated `accesskit_winit` version requirement from 0.23 to 0.25 ## Testing - Ran CI checks locally. --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This commit is contained in:
parent
0702f3652d
commit
c16a884ccb
@ -561,7 +561,7 @@ hyper = { version = "1", features = ["server", "http1"] }
|
|||||||
http-body-util = "0.1"
|
http-body-util = "0.1"
|
||||||
anyhow = "1"
|
anyhow = "1"
|
||||||
macro_rules_attribute = "0.2"
|
macro_rules_attribute = "0.2"
|
||||||
accesskit = "0.17"
|
accesskit = "0.18"
|
||||||
nonmax = "0.5"
|
nonmax = "0.5"
|
||||||
|
|
||||||
[target.'cfg(not(target_family = "wasm"))'.dev-dependencies]
|
[target.'cfg(not(target_family = "wasm"))'.dev-dependencies]
|
||||||
|
@ -46,7 +46,7 @@ bevy_ecs = { path = "../bevy_ecs", version = "0.16.0-rc.1", default-features = f
|
|||||||
bevy_reflect = { path = "../bevy_reflect", version = "0.16.0-rc.1", default-features = false, optional = true }
|
bevy_reflect = { path = "../bevy_reflect", version = "0.16.0-rc.1", default-features = false, optional = true }
|
||||||
|
|
||||||
# other
|
# other
|
||||||
accesskit = { version = "0.17", default-features = false }
|
accesskit = { version = "0.18", default-features = false }
|
||||||
serde = { version = "1", default-features = false, features = [
|
serde = { version = "1", default-features = false, features = [
|
||||||
"alloc",
|
"alloc",
|
||||||
], optional = true }
|
], optional = true }
|
||||||
|
@ -40,7 +40,7 @@ thiserror = { version = "2", default-features = false }
|
|||||||
derive_more = { version = "1", default-features = false, features = ["from"] }
|
derive_more = { version = "1", default-features = false, features = ["from"] }
|
||||||
nonmax = "0.5"
|
nonmax = "0.5"
|
||||||
smallvec = "1.11"
|
smallvec = "1.11"
|
||||||
accesskit = "0.17"
|
accesskit = "0.18"
|
||||||
tracing = { version = "0.1", default-features = false, features = ["std"] }
|
tracing = { version = "0.1", default-features = false, features = ["std"] }
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
|
@ -51,7 +51,7 @@ bevy_image = { path = "../bevy_image", version = "0.16.0-rc.1", optional = true
|
|||||||
# other
|
# other
|
||||||
# feature rwh_06 refers to window_raw_handle@v0.6
|
# feature rwh_06 refers to window_raw_handle@v0.6
|
||||||
winit = { version = "0.30", default-features = false, features = ["rwh_06"] }
|
winit = { version = "0.30", default-features = false, features = ["rwh_06"] }
|
||||||
accesskit_winit = { version = "0.23", default-features = false, features = [
|
accesskit_winit = { version = "0.25", default-features = false, features = [
|
||||||
"rwh_06",
|
"rwh_06",
|
||||||
] }
|
] }
|
||||||
approx = { version = "0.5", default-features = false }
|
approx = { version = "0.5", default-features = false }
|
||||||
@ -60,7 +60,7 @@ raw-window-handle = "0.6"
|
|||||||
serde = { version = "1.0", features = ["derive"], optional = true }
|
serde = { version = "1.0", features = ["derive"], optional = true }
|
||||||
bytemuck = { version = "1.5", optional = true }
|
bytemuck = { version = "1.5", optional = true }
|
||||||
wgpu-types = { version = "24", optional = true }
|
wgpu-types = { version = "24", optional = true }
|
||||||
accesskit = "0.17"
|
accesskit = "0.18"
|
||||||
tracing = { version = "0.1", default-features = false, features = ["std"] }
|
tracing = { version = "0.1", default-features = false, features = ["std"] }
|
||||||
|
|
||||||
[target.'cfg(target_arch = "wasm32")'.dependencies]
|
[target.'cfg(target_arch = "wasm32")'.dependencies]
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
use alloc::{collections::VecDeque, sync::Arc};
|
use alloc::{collections::VecDeque, sync::Arc};
|
||||||
use bevy_input_focus::InputFocus;
|
use bevy_input_focus::InputFocus;
|
||||||
use std::sync::Mutex;
|
use std::sync::Mutex;
|
||||||
|
use winit::event_loop::ActiveEventLoop;
|
||||||
|
|
||||||
use accesskit::{
|
use accesskit::{
|
||||||
ActionHandler, ActionRequest, ActivationHandler, DeactivationHandler, Node, NodeId, Role, Tree,
|
ActionHandler, ActionRequest, ActivationHandler, DeactivationHandler, Node, NodeId, Role, Tree,
|
||||||
@ -66,8 +67,7 @@ impl AccessKitState {
|
|||||||
fn build_initial_tree(&mut self) -> TreeUpdate {
|
fn build_initial_tree(&mut self) -> TreeUpdate {
|
||||||
let root = self.build_root();
|
let root = self.build_root();
|
||||||
let accesskit_window_id = NodeId(self.entity.to_bits());
|
let accesskit_window_id = NodeId(self.entity.to_bits());
|
||||||
let mut tree = Tree::new(accesskit_window_id);
|
let tree = Tree::new(accesskit_window_id);
|
||||||
tree.app_name = Some(self.name.clone());
|
|
||||||
self.requested.set(true);
|
self.requested.set(true);
|
||||||
|
|
||||||
TreeUpdate {
|
TreeUpdate {
|
||||||
@ -116,6 +116,7 @@ impl DeactivationHandler for WinitDeactivationHandler {
|
|||||||
|
|
||||||
/// Prepares accessibility for a winit window.
|
/// Prepares accessibility for a winit window.
|
||||||
pub(crate) fn prepare_accessibility_for_window(
|
pub(crate) fn prepare_accessibility_for_window(
|
||||||
|
event_loop: &ActiveEventLoop,
|
||||||
winit_window: &winit::window::Window,
|
winit_window: &winit::window::Window,
|
||||||
entity: Entity,
|
entity: Entity,
|
||||||
name: String,
|
name: String,
|
||||||
@ -131,6 +132,7 @@ pub(crate) fn prepare_accessibility_for_window(
|
|||||||
let deactivation_handler = WinitDeactivationHandler;
|
let deactivation_handler = WinitDeactivationHandler;
|
||||||
|
|
||||||
let adapter = Adapter::with_direct_handlers(
|
let adapter = Adapter::with_direct_handlers(
|
||||||
|
event_loop,
|
||||||
winit_window,
|
winit_window,
|
||||||
activation_handler,
|
activation_handler,
|
||||||
action_handler,
|
action_handler,
|
||||||
|
@ -278,6 +278,7 @@ impl WinitWindows {
|
|||||||
let winit_window = event_loop.create_window(winit_window_attributes).unwrap();
|
let winit_window = event_loop.create_window(winit_window_attributes).unwrap();
|
||||||
let name = window.title.clone();
|
let name = window.title.clone();
|
||||||
prepare_accessibility_for_window(
|
prepare_accessibility_for_window(
|
||||||
|
event_loop,
|
||||||
&winit_window,
|
&winit_window,
|
||||||
entity,
|
entity,
|
||||||
name,
|
name,
|
||||||
|
Loading…
Reference in New Issue
Block a user