1
0
Fork 0
forked from wry/wry

all: set rust edition to 2024

This commit is contained in:
Julian Orth 2025-02-21 10:44:29 +01:00
parent 02a18f620b
commit 3338909170
515 changed files with 1225 additions and 1187 deletions

View file

@ -6,10 +6,10 @@ use {
fixed::Fixed,
gfx_api::GfxTexture,
ifs::wl_seat::{
collect_kb_foci, collect_kb_foci2,
BTN_LEFT, BTN_RIGHT, NodeSeatState, SeatId, WlSeatGlobal, collect_kb_foci,
collect_kb_foci2,
tablet::{TabletTool, TabletToolChanges, TabletToolId},
wl_pointer::PendingScroll,
NodeSeatState, SeatId, WlSeatGlobal, BTN_LEFT, BTN_RIGHT,
},
rect::Rect,
renderer::Renderer,
@ -17,9 +17,9 @@ use {
state::State,
text::TextTexture,
tree::{
default_tile_drag_bounds, walker::NodeVisitor, ContainingNode, Direction,
FindTreeResult, FindTreeUsecase, FoundNode, Node, NodeId, TddType, TileDragDestination,
ToplevelData, ToplevelNode, ToplevelNodeBase, WorkspaceNode,
ContainingNode, Direction, FindTreeResult, FindTreeUsecase, FoundNode, Node, NodeId,
TddType, TileDragDestination, ToplevelData, ToplevelNode, ToplevelNodeBase,
WorkspaceNode, default_tile_drag_bounds, walker::NodeVisitor,
},
utils::{
asyncevent::AsyncEvent,

View file

@ -3,14 +3,13 @@ use {
backend::ConnectorId,
cursor::KnownCursor,
fixed::Fixed,
ifs::wl_seat::{tablet::TabletTool, NodeSeatState, WlSeatGlobal},
ifs::wl_seat::{NodeSeatState, WlSeatGlobal, tablet::TabletTool},
rect::Rect,
renderer::Renderer,
state::State,
tree::{
walker::NodeVisitor, FindTreeResult, FindTreeUsecase, FoundNode, Node, NodeId,
OutputNode, StackedNode, TileDragDestination, WorkspaceDragDestination,
WorkspaceNodeId,
FindTreeResult, FindTreeUsecase, FoundNode, Node, NodeId, OutputNode, StackedNode,
TileDragDestination, WorkspaceDragDestination, WorkspaceNodeId, walker::NodeVisitor,
},
utils::{copyhashmap::CopyHashMap, linkedlist::LinkedList},
},

View file

@ -5,8 +5,8 @@ use {
cursor_user::CursorUser,
fixed::Fixed,
ifs::wl_seat::{
BTN_LEFT, NodeSeatState, SeatId, WlSeatGlobal,
tablet::{TabletTool, TabletToolChanges, TabletToolId},
NodeSeatState, SeatId, WlSeatGlobal, BTN_LEFT,
},
rect::Rect,
renderer::Renderer,
@ -14,8 +14,8 @@ use {
state::State,
text::TextTexture,
tree::{
walker::NodeVisitor, ContainingNode, Direction, FindTreeResult, FindTreeUsecase,
FoundNode, Node, NodeId, StackedNode, TileDragDestination, ToplevelNode, WorkspaceNode,
ContainingNode, Direction, FindTreeResult, FindTreeUsecase, FoundNode, Node, NodeId,
StackedNode, TileDragDestination, ToplevelNode, WorkspaceNode, walker::NodeVisitor,
},
utils::{
asyncevent::AsyncEvent, clonecell::CloneCell, double_click_state::DoubleClickState,

View file

@ -12,16 +12,15 @@ use {
wl_buffer::WlBufferStorage,
wl_output::WlOutputGlobal,
wl_seat::{
collect_kb_foci2,
BTN_LEFT, NodeSeatState, SeatId, WlSeatGlobal, collect_kb_foci2,
tablet::{TabletTool, TabletToolChanges, TabletToolId},
wl_pointer::PendingScroll,
NodeSeatState, SeatId, WlSeatGlobal, BTN_LEFT,
},
wl_surface::{
SurfaceSendPreferredScaleVisitor, SurfaceSendPreferredTransformVisitor,
ext_session_lock_surface_v1::ExtSessionLockSurfaceV1,
tray::DynTrayItem,
zwlr_layer_surface_v1::{ExclusiveSize, ZwlrLayerSurfaceV1},
SurfaceSendPreferredScaleVisitor, SurfaceSendPreferredTransformVisitor,
},
workspace_manager::{
ext_workspace_group_handle_v1::ExtWorkspaceGroupHandleV1,
@ -38,9 +37,9 @@ use {
state::State,
text::TextTexture,
tree::{
walker::NodeVisitor, Direction, FindTreeResult, FindTreeUsecase, FoundNode, Node,
NodeId, StackedNode, TddType, TileDragDestination, WorkspaceDragDestination,
WorkspaceNode, WorkspaceNodeId,
Direction, FindTreeResult, FindTreeUsecase, FoundNode, Node, NodeId, StackedNode,
TddType, TileDragDestination, WorkspaceDragDestination, WorkspaceNode, WorkspaceNodeId,
walker::NodeVisitor,
},
utils::{
asyncevent::AsyncEvent, clonecell::CloneCell, copyhashmap::CopyHashMap,

View file

@ -10,9 +10,9 @@ use {
state::State,
text::TextTexture,
tree::{
default_tile_drag_destination, ContainerSplit, Direction, FindTreeResult,
FindTreeUsecase, FoundNode, Node, NodeId, NodeVisitor, TileDragDestination,
ToplevelData, ToplevelNode, ToplevelNodeBase,
ContainerSplit, Direction, FindTreeResult, FindTreeUsecase, FoundNode, Node, NodeId,
NodeVisitor, TileDragDestination, ToplevelData, ToplevelNode, ToplevelNodeBase,
default_tile_drag_destination,
},
utils::{
asyncevent::AsyncEvent, errorfmt::ErrorFmt, on_drop_event::OnDropEvent,

View file

@ -7,7 +7,7 @@ use {
ext_image_copy::ext_image_copy_capture_session_v1::ExtImageCopyCaptureSessionV1,
jay_screencast::JayScreencast,
jay_toplevel::JayToplevel,
wl_seat::{collect_kb_foci, collect_kb_foci2, NodeSeatState},
wl_seat::{NodeSeatState, collect_kb_foci, collect_kb_foci2},
wl_surface::WlSurface,
},
rect::Rect,
@ -23,7 +23,7 @@ use {
hash_map_ext::HashMapExt,
numcell::NumCell,
threshold_counter::ThresholdCounter,
toplevel_identifier::{toplevel_identifier, ToplevelIdentifier},
toplevel_identifier::{ToplevelIdentifier, toplevel_identifier},
},
wire::{
ExtForeignToplevelHandleV1Id, ExtImageCopyCaptureSessionV1Id, JayScreencastId,
@ -453,7 +453,9 @@ impl ToplevelData {
ws: &Rc<WorkspaceNode>,
) {
if ws.fullscreen.is_some() {
log::info!("Cannot fullscreen a node on a workspace that already has a fullscreen node attached");
log::info!(
"Cannot fullscreen a node on a workspace that already has a fullscreen node attached"
);
return;
}
if node.node_is_placeholder() {
@ -520,11 +522,15 @@ impl ToplevelData {
self.is_fullscreen.set(false);
match fd.workspace.fullscreen.get() {
None => {
log::error!("Node is supposed to be fullscreened on a workspace but workspace has not fullscreen node.");
log::error!(
"Node is supposed to be fullscreened on a workspace but workspace has not fullscreen node."
);
return;
}
Some(f) if f.tl_as_node().node_id() != node.tl_as_node().node_id() => {
log::error!("Node is supposed to be fullscreened on a workspace but the workspace has a different node attached.");
log::error!(
"Node is supposed to be fullscreened on a workspace but the workspace has a different node attached."
);
return;
}
_ => {}

View file

@ -1,12 +1,12 @@
use {
crate::{
ifs::wl_surface::{
WlSurface,
ext_session_lock_surface_v1::ExtSessionLockSurfaceV1,
tray::jay_tray_item_v1::JayTrayItemV1,
x_surface::xwindow::Xwindow,
xdg_surface::{xdg_popup::XdgPopup, xdg_toplevel::XdgToplevel},
zwlr_layer_surface_v1::ZwlrLayerSurfaceV1,
WlSurface,
},
tree::{
ContainerNode, DisplayNode, FloatNode, Node, OutputNode, PlaceholderNode, WorkspaceNode,

View file

@ -6,9 +6,9 @@ use {
ifs::{
jay_workspace::JayWorkspace,
wl_output::OutputId,
wl_seat::{tablet::TabletTool, NodeSeatState, WlSeatGlobal},
wl_seat::{NodeSeatState, WlSeatGlobal, tablet::TabletTool},
wl_surface::{
x_surface::xwindow::Xwindow, xdg_surface::xdg_toplevel::XdgToplevel, WlSurface,
WlSurface, x_surface::xwindow::Xwindow, xdg_surface::xdg_toplevel::XdgToplevel,
},
workspace_manager::{
ext_workspace_handle_v1::ExtWorkspaceHandleV1,
@ -20,9 +20,9 @@ use {
state::State,
text::TextTexture,
tree::{
container::ContainerNode, walker::NodeVisitor, ContainingNode, Direction,
FindTreeResult, FindTreeUsecase, FoundNode, Node, NodeId, NodeVisitorBase, OutputNode,
PlaceholderNode, StackedNode, ToplevelNode,
ContainingNode, Direction, FindTreeResult, FindTreeUsecase, FoundNode, Node, NodeId,
NodeVisitorBase, OutputNode, PlaceholderNode, StackedNode, ToplevelNode,
container::ContainerNode, walker::NodeVisitor,
},
utils::{
clonecell::CloneCell,