Add cosmic-keyboard-layout-unstable-v1 protocol
https://github.com/pop-os/cosmic-protocols/pull/28 Allows clients like `cosmic-applet-input-sources` to show which layout group is active and update it. Currently this is implemented by update the `xkb_config` to change the layout order.
This commit is contained in:
parent
031fdc389a
commit
29320bdab5
7 changed files with 215 additions and 11 deletions
10
src/wayland/handlers/keyboard_layout.rs
Normal file
10
src/wayland/handlers/keyboard_layout.rs
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
// SPDX-License-Identifier: GPL-3.0-only
|
||||
|
||||
use crate::state::State;
|
||||
use crate::wayland::protocols::keyboard_layout::{KeyboardLayoutHandler, KeyboardLayoutState};
|
||||
|
||||
impl KeyboardLayoutHandler for State {
|
||||
fn keyboard_layout_state(&mut self) -> &mut KeyboardLayoutState {
|
||||
&mut self.common.keyboard_layout_state
|
||||
}
|
||||
}
|
||||
|
|
@ -18,6 +18,7 @@ pub mod idle_notify;
|
|||
pub mod image_capture_source;
|
||||
pub mod image_copy_capture;
|
||||
pub mod input_method;
|
||||
pub mod keyboard_layout;
|
||||
pub mod keyboard_shortcuts_inhibit;
|
||||
pub mod layer_shell;
|
||||
pub mod output;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue