deps: Update for smithay
This commit is contained in:
parent
219e21d573
commit
7de8d6e979
4 changed files with 19 additions and 19 deletions
6
Cargo.lock
generated
6
Cargo.lock
generated
|
|
@ -1425,7 +1425,7 @@ checksum = "f2dd574626839106c320a323308629dcb1acfc96e32a8cba364ddc61ac23ee83"
|
|||
[[package]]
|
||||
name = "smithay"
|
||||
version = "0.3.0"
|
||||
source = "git+https://github.com/pop-os/smithay?branch=main#c24ac85b70606c184a973e396fe4acaae1239147"
|
||||
source = "git+https://github.com/pop-os/smithay?branch=main#6b7db881ebe1fed0ffb000629d6f90e20c00daf1"
|
||||
dependencies = [
|
||||
"appendlist",
|
||||
"bitflags",
|
||||
|
|
@ -1515,9 +1515,9 @@ checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601"
|
|||
|
||||
[[package]]
|
||||
name = "syn"
|
||||
version = "1.0.93"
|
||||
version = "1.0.94"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "04066589568b72ec65f42d65a1a52436e954b168773148893c020269563decf2"
|
||||
checksum = "a07e33e919ebcd69113d5be0e4d70c5707004ff45188910106854f38b960df4a"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
|
|
|
|||
|
|
@ -785,7 +785,7 @@ impl State {
|
|||
pub fn handle_window_movement(surface: Option<&WlSurface>, space: &mut Space) {
|
||||
// TODO: this is why to hardcoded and hacky, but wayland-rs 0.30 will make this unnecessary anyway.
|
||||
if let Some(surface) = surface {
|
||||
if let Some(window) = space.window_for_surface(&surface).cloned() {
|
||||
if let Some(window) = space.window_for_surface(&surface, WindowSurfaceType::TOPLEVEL).cloned() {
|
||||
if let Some(new_position) =
|
||||
crate::shell::layout::floating::MoveSurfaceGrab::apply_move_state(&window)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ use smithay::{
|
|||
backend::renderer::utils::on_commit_buffer_handler,
|
||||
desktop::{
|
||||
layer_map_for_output, Kind, LayerSurface, PopupGrab, PopupKeyboardGrab, PopupKind,
|
||||
PopupPointerGrab, PopupUngrabStrategy, Window,
|
||||
PopupPointerGrab, PopupUngrabStrategy, Window, WindowSurfaceType,
|
||||
},
|
||||
reexports::{
|
||||
wayland_protocols::xdg_shell::server::xdg_toplevel,
|
||||
|
|
@ -101,7 +101,7 @@ pub fn init_shell(config: &Config, display: &mut Display) -> super::Shell {
|
|||
.unwrap();
|
||||
let window = workspace
|
||||
.space
|
||||
.window_for_surface(surface.get_surface().unwrap())
|
||||
.window_for_surface(surface.get_surface().unwrap(), WindowSurfaceType::TOPLEVEL)
|
||||
.unwrap()
|
||||
.clone();
|
||||
|
||||
|
|
@ -125,7 +125,7 @@ pub fn init_shell(config: &Config, display: &mut Display) -> super::Shell {
|
|||
.unwrap();
|
||||
let window = workspace
|
||||
.space
|
||||
.window_for_surface(surface.get_surface().unwrap())
|
||||
.window_for_surface(surface.get_surface().unwrap(), WindowSurfaceType::TOPLEVEL)
|
||||
.unwrap()
|
||||
.clone();
|
||||
|
||||
|
|
@ -140,7 +140,7 @@ pub fn init_shell(config: &Config, display: &mut Display) -> super::Shell {
|
|||
if let Some(window) = state
|
||||
.shell
|
||||
.space_for_surface(&surface)
|
||||
.and_then(|workspace| workspace.space.window_for_surface(&surface))
|
||||
.and_then(|workspace| workspace.space.window_for_surface(&surface, WindowSurfaceType::TOPLEVEL))
|
||||
{
|
||||
crate::shell::layout::floating::ResizeSurfaceGrab::ack_configure(
|
||||
window, configure,
|
||||
|
|
@ -154,7 +154,7 @@ pub fn init_shell(config: &Config, display: &mut Display) -> super::Shell {
|
|||
|
||||
if let Some(workspace) = state.shell.space_for_surface_mut(surface) {
|
||||
let window =
|
||||
workspace.space.window_for_surface(surface).unwrap().clone();
|
||||
workspace.space.window_for_surface(surface, WindowSurfaceType::TOPLEVEL).unwrap().clone();
|
||||
workspace.maximize_request(&window, &output)
|
||||
}
|
||||
}
|
||||
|
|
@ -222,7 +222,7 @@ pub fn init_shell(config: &Config, display: &mut Display) -> super::Shell {
|
|||
if let Some(surface) = surface.get_surface() {
|
||||
if let Some(workspace) = state.shell.space_for_surface_mut(surface) {
|
||||
let window =
|
||||
workspace.space.window_for_surface(surface).unwrap().clone();
|
||||
workspace.space.window_for_surface(surface, WindowSurfaceType::TOPLEVEL).unwrap().clone();
|
||||
workspace.fullscreen_request(&window, &output)
|
||||
}
|
||||
}
|
||||
|
|
@ -231,7 +231,7 @@ pub fn init_shell(config: &Config, display: &mut Display) -> super::Shell {
|
|||
if let Some(surface) = surface.get_surface() {
|
||||
if let Some(workspace) = state.shell.space_for_surface_mut(surface) {
|
||||
let window =
|
||||
workspace.space.window_for_surface(surface).unwrap().clone();
|
||||
workspace.space.window_for_surface(surface, WindowSurfaceType::TOPLEVEL).unwrap().clone();
|
||||
workspace.unfullscreen_request(&window)
|
||||
}
|
||||
}
|
||||
|
|
@ -358,7 +358,7 @@ fn commit(surface: &WlSurface, state: &mut State) {
|
|||
.and_then(|workspace| {
|
||||
workspace
|
||||
.space
|
||||
.window_for_surface(surface)
|
||||
.window_for_surface(surface, WindowSurfaceType::TOPLEVEL)
|
||||
.cloned()
|
||||
.map(|window| (&mut workspace.space, window))
|
||||
})
|
||||
|
|
@ -398,10 +398,10 @@ fn commit(surface: &WlSurface, state: &mut State) {
|
|||
|
||||
if let Some(output) = state.shell.outputs().find(|o| {
|
||||
let map = layer_map_for_output(o);
|
||||
map.layer_for_surface(surface).is_some()
|
||||
map.layer_for_surface(surface, WindowSurfaceType::TOPLEVEL).is_some()
|
||||
}) {
|
||||
let mut map = layer_map_for_output(output);
|
||||
let layer = map.layer_for_surface(surface).unwrap();
|
||||
let layer = map.layer_for_surface(surface, WindowSurfaceType::TOPLEVEL).unwrap();
|
||||
|
||||
// send the initial configure if relevant
|
||||
let initial_configure_sent = with_states(surface, |states| {
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ use crate::{
|
|||
state::Common,
|
||||
};
|
||||
pub use smithay::{
|
||||
desktop::{layer_map_for_output, PopupGrab, PopupManager, PopupUngrabStrategy, Space, Window},
|
||||
desktop::{layer_map_for_output, PopupGrab, PopupManager, PopupUngrabStrategy, Space, Window, WindowSurfaceType},
|
||||
reexports::wayland_server::{protocol::wl_surface::WlSurface, Display},
|
||||
utils::{Logical, Point, Rectangle, Size},
|
||||
wayland::{
|
||||
|
|
@ -604,14 +604,14 @@ impl Shell {
|
|||
.pending_windows
|
||||
.iter()
|
||||
.any(|(w, _)| w.toplevel().get_surface() == Some(surface))
|
||||
|| workspace.space.window_for_surface(surface).is_some()
|
||||
|| workspace.space.window_for_surface(surface, WindowSurfaceType::ALL).is_some()
|
||||
})
|
||||
}
|
||||
|
||||
pub fn space_for_surface_mut(&mut self, surface: &WlSurface) -> Option<&mut Workspace> {
|
||||
self.spaces
|
||||
.iter_mut()
|
||||
.find(|workspace| workspace.space.window_for_surface(surface).is_some())
|
||||
.find(|workspace| workspace.space.window_for_surface(surface, WindowSurfaceType::ALL).is_some())
|
||||
}
|
||||
|
||||
pub fn refresh(&mut self) {
|
||||
|
|
@ -731,7 +731,7 @@ impl Shell {
|
|||
// update FocusStack and notify layouts about new focus (if any window)
|
||||
if let Some(surface) = surface {
|
||||
if let Some(workspace) = self.space_for_surface_mut(surface) {
|
||||
if let Some(window) = workspace.space.window_for_surface(surface) {
|
||||
if let Some(window) = workspace.space.window_for_surface(surface, WindowSurfaceType::ALL) {
|
||||
let mut focus_stack = workspace.focus_stack_mut(active_seat);
|
||||
if Some(window) != focus_stack.last().as_ref() {
|
||||
slog_scope::debug!("Focusing window: {:?}", window);
|
||||
|
|
@ -838,7 +838,7 @@ impl Common {
|
|||
}
|
||||
|
||||
let workspace = self.shell.active_space(&output);
|
||||
if let Some(window) = workspace.space.window_for_surface(&surface) {
|
||||
if let Some(window) = workspace.space.window_for_surface(&surface, WindowSurfaceType::ALL) {
|
||||
let focus_stack = workspace.focus_stack(&seat);
|
||||
if focus_stack.last().map(|w| &w != window).unwrap_or(true) {
|
||||
fixup = true;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue