cargo fmt
This commit is contained in:
parent
43062c1754
commit
39de286d51
40 changed files with 1557 additions and 1080 deletions
|
|
@ -1,18 +1,14 @@
|
|||
// SPDX-License-Identifier: GPL-3.0-only
|
||||
|
||||
use smithay::reexports::wayland_server::DisplayHandle;
|
||||
use crate::{
|
||||
state::ClientState,
|
||||
wayland::protocols::workspace::{
|
||||
Request,
|
||||
WorkspaceHandler,
|
||||
WorkspaceState,
|
||||
WorkspaceClientHandler,
|
||||
WorkspaceClientState,
|
||||
delegate_workspace,
|
||||
},
|
||||
utils::prelude::*,
|
||||
wayland::protocols::workspace::{
|
||||
delegate_workspace, Request, WorkspaceClientHandler, WorkspaceClientState,
|
||||
WorkspaceHandler, WorkspaceState,
|
||||
},
|
||||
};
|
||||
use smithay::reexports::wayland_server::DisplayHandle;
|
||||
|
||||
impl WorkspaceClientHandler for ClientState {
|
||||
fn workspace_state(&self) -> &WorkspaceClientState {
|
||||
|
|
@ -28,18 +24,24 @@ impl WorkspaceHandler for State {
|
|||
fn workspace_state_mut(&mut self) -> &mut WorkspaceState<Self> {
|
||||
&mut self.common.shell.workspace_state
|
||||
}
|
||||
|
||||
|
||||
fn commit_requests(&mut self, _dh: &DisplayHandle, requests: Vec<Request>) {
|
||||
for request in requests.into_iter() {
|
||||
match request {
|
||||
Request::Activate(handle) => {
|
||||
if let Some(idx) = self.common.shell.spaces.iter().position(|w| w.handle == handle) {
|
||||
if let Some(idx) = self
|
||||
.common
|
||||
.shell
|
||||
.spaces
|
||||
.iter()
|
||||
.position(|w| w.handle == handle)
|
||||
{
|
||||
let seat = &self.common.last_active_seat;
|
||||
let output = active_output(seat, &self.common);
|
||||
self.common.shell.activate(seat, &output, idx);
|
||||
}
|
||||
},
|
||||
_ => {},
|
||||
}
|
||||
_ => {}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue