Skip to content

Commit

Permalink
xdg-activation: Initial implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
Drakulix committed Nov 7, 2023
1 parent b958144 commit 5f6eb1a
Show file tree
Hide file tree
Showing 8 changed files with 380 additions and 47 deletions.
12 changes: 10 additions & 2 deletions src/shell/focus/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -91,11 +91,10 @@ impl ActiveFocus {
}

impl Shell {
pub fn set_focus<'a>(
pub fn append_focus_stack(
state: &mut State,
target: Option<&KeyboardFocusTarget>,
active_seat: &Seat<State>,
serial: Option<Serial>,
) {
// update FocusStack and notify layouts about new focus (if any window)
let element = match target {
Expand Down Expand Up @@ -125,6 +124,15 @@ impl Shell {
}
}
}
}

pub fn set_focus(
state: &mut State,
target: Option<&KeyboardFocusTarget>,
active_seat: &Seat<State>,
serial: Option<Serial>,
) {
Self::append_focus_stack(state, target, active_seat);

// update keyboard focus
if let Some(keyboard) = active_seat.get_keyboard() {
Expand Down
2 changes: 1 addition & 1 deletion src/shell/layout/floating/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ pub use self::grabs::*;

#[derive(Debug, Default)]
pub struct FloatingLayout {
pub(in crate::shell) space: Space<CosmicMapped>,
pub(crate) space: Space<CosmicMapped>,
}

impl FloatingLayout {
Expand Down
Loading

0 comments on commit 5f6eb1a

Please sign in to comment.