From b5afa744f29d65d59b6c6c581b366b63728bce35 Mon Sep 17 00:00:00 2001 From: Eivind Gamst Date: Sat, 14 Dec 2024 15:31:04 +0800 Subject: [PATCH] input-method-next --- .gitmodules | 4 ++++ wayland-protocols/protocols | 2 +- wayland-protocols/src/wp.rs | 22 ++++++++++++++++++++-- 3 files changed, 25 insertions(+), 3 deletions(-) diff --git a/.gitmodules b/.gitmodules index 9edb2764371..1c0116081c5 100644 --- a/.gitmodules +++ b/.gitmodules @@ -7,3 +7,7 @@ [submodule "wayland-protocols-plasma/plasma-wayland-protocols"] path = wayland-protocols-plasma/plasma-wayland-protocols url = https://github.com/KDE/plasma-wayland-protocols.git +[submodule "wayland-protocols/wayland-protocols"] + path = wayland-protocols/protocols + url = git@gitlab.freedesktop.org:rano/wayland-protocols.git + branch = input-method-next diff --git a/wayland-protocols/protocols b/wayland-protocols/protocols index 9ac1a0977ee..93f954b94ff 160000 --- a/wayland-protocols/protocols +++ b/wayland-protocols/protocols @@ -1 +1 @@ -Subproject commit 9ac1a0977eea1b2f525e375089131f7d696a74ee +Subproject commit 93f954b94ff2589d109d88cf518966b2d55c723d diff --git a/wayland-protocols/src/wp.rs b/wayland-protocols/src/wp.rs index 07635204ec9..7be16a41fc2 100644 --- a/wayland-protocols/src/wp.rs +++ b/wayland-protocols/src/wp.rs @@ -126,17 +126,25 @@ pub mod idle_inhibit { } } -#[cfg(feature = "unstable")] pub mod input_method { //! Input method protocol /// Unstable version 1 + #[cfg(feature = "unstable")] pub mod zv1 { wayland_protocol!( "./protocols/unstable/input-method/input-method-unstable-v1.xml", [] ); } + /// Staging version 3 + #[cfg(feature = "staging")] + pub mod v3 { + wayland_protocol!( + "./protocols/staging/input-method/input-method-v3.xml", + [crate::wp::text_input::v3, crate::xdg::shell] + ); + } } #[cfg(feature = "unstable")] @@ -441,11 +449,11 @@ pub mod tablet { } } -#[cfg(feature = "unstable")] pub mod text_input { //! Text input protocol /// Unstable version 1 + #[cfg(feature = "unstable")] pub mod zv1 { wayland_protocol!( "./protocols/unstable/text-input/text-input-unstable-v1.xml", @@ -454,12 +462,22 @@ pub mod text_input { } /// Unstable version 3 + #[cfg(feature = "unstable")] pub mod zv3 { wayland_protocol!( "./protocols/unstable/text-input/text-input-unstable-v3.xml", [] ); } + + /// Staging version 3.2 + #[cfg(feature = "staging")] + pub mod v3 { + wayland_protocol!( + "./protocols/staging/text-input/text-input-v3.xml", + [] + ); + } } pub mod viewporter {