all: set rust edition to 2024
This commit is contained in:
parent
02a18f620b
commit
3338909170
515 changed files with 1225 additions and 1187 deletions
|
|
@ -1,7 +1,7 @@
|
|||
[package]
|
||||
name = "jay-compositor"
|
||||
version = "1.9.0"
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
build = "build/build.rs"
|
||||
license = "GPL-3.0-only"
|
||||
description = "The Jay compositor"
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
[package]
|
||||
name = "jay-algorithms"
|
||||
version = "0.3.0"
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
license = "GPL-3.0-only"
|
||||
description = "Internal dependency of the Jay compositor"
|
||||
repository = "https://github.com/mahkoh/jay"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use {
|
||||
anyhow::{bail, Context, Result},
|
||||
anyhow::{Context, Result, bail},
|
||||
bstr::{BString, ByteSlice},
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use {
|
||||
crate::open,
|
||||
anyhow::{anyhow, bail, Context},
|
||||
anyhow::{Context, anyhow, bail},
|
||||
shaderc::{CompileOptions, ResolvedInclude},
|
||||
std::{io::Write, path::Path},
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use {
|
||||
crate::open,
|
||||
anyhow::{bail, Context, Result},
|
||||
anyhow::{Context, Result, bail},
|
||||
std::{fs::DirEntry, io::Write, os::unix::ffi::OsStrExt},
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
use {
|
||||
crate::{
|
||||
open,
|
||||
tokens::{tokenize, Lined, Symbol, Token, TokenKind, TreeDelim},
|
||||
tokens::{Lined, Symbol, Token, TokenKind, TreeDelim, tokenize},
|
||||
},
|
||||
anyhow::{bail, Context, Result},
|
||||
anyhow::{Context, Result, bail},
|
||||
bstr::{BStr, BString, ByteSlice},
|
||||
std::{
|
||||
collections::{hash_map::Entry, HashMap},
|
||||
collections::{HashMap, hash_map::Entry},
|
||||
io::Write,
|
||||
os::unix::ffi::OsStrExt,
|
||||
},
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
use {
|
||||
crate::{
|
||||
open,
|
||||
tokens::{tokenize, Symbol, Token, TokenKind, TreeDelim},
|
||||
tokens::{Symbol, Token, TokenKind, TreeDelim, tokenize},
|
||||
},
|
||||
anyhow::{bail, Context, Result},
|
||||
anyhow::{Context, Result, bail},
|
||||
std::{fs::DirEntry, io::Write, os::unix::ffi::OsStrExt},
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
use {
|
||||
crate::{
|
||||
open,
|
||||
tokens::{tokenize, Symbol, Token, TokenKind, TreeDelim},
|
||||
tokens::{Symbol, Token, TokenKind, TreeDelim, tokenize},
|
||||
},
|
||||
anyhow::{bail, Context, Result},
|
||||
anyhow::{Context, Result, bail},
|
||||
bstr::ByteSlice,
|
||||
std::{cell::Cell, collections::HashMap, io::Write, mem, os::unix::ffi::OsStrExt, rc::Rc},
|
||||
};
|
||||
|
|
@ -1171,7 +1171,10 @@ fn format_enum<F: Write>(f: &mut F, s: &Enum, protocols: &Protocols) -> Result<(
|
|||
writeln!(f, " }}")?;
|
||||
writeln!(f, " }}")?;
|
||||
writeln!(f)?;
|
||||
writeln!(f, " pub fn deserialize(parser: &mut Parser{lt_a}, value: u32) -> Result<Self, XconError> {{")?;
|
||||
writeln!(
|
||||
f,
|
||||
" pub fn deserialize(parser: &mut Parser{lt_a}, value: u32) -> Result<Self, XconError> {{"
|
||||
)?;
|
||||
writeln!(f, " let res = match value {{")?;
|
||||
for field in &s.variants {
|
||||
writeln!(
|
||||
|
|
@ -1233,7 +1236,10 @@ fn format_bitmask<F: Write>(f: &mut F, s: &Bitmask, protocols: &Protocols) -> Re
|
|||
writeln!(f, " formatter.write_bytes(&bytes[..pos]);")?;
|
||||
writeln!(f, " }}")?;
|
||||
writeln!(f)?;
|
||||
writeln!(f, " pub fn deserialize(&self, parser: &mut Parser, bitmask: u32) -> Result<Self, XconError> {{")?;
|
||||
writeln!(
|
||||
f,
|
||||
" pub fn deserialize(&self, parser: &mut Parser, bitmask: u32) -> Result<Self, XconError> {{"
|
||||
)?;
|
||||
writeln!(
|
||||
f,
|
||||
" let b = parser.read_slice(bitmask.count_ones() as usize * 4)?;"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,8 @@
|
|||
# Unreleased
|
||||
|
||||
- Needs jay-algorithms release.
|
||||
- Needs jay-config release.
|
||||
- Needs jay-toml-config release.
|
||||
- Needs jay-compositor release.
|
||||
|
||||
# 1.9.0
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
[package]
|
||||
name = "jay-config"
|
||||
version = "1.7.0"
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
license = "GPL-3.0-only"
|
||||
description = "Configuration crate for the Jay compositor"
|
||||
repository = "https://github.com/mahkoh/jay"
|
||||
|
|
|
|||
|
|
@ -3,50 +3,50 @@
|
|||
use {
|
||||
crate::{
|
||||
_private::{
|
||||
bincode_ops,
|
||||
Config, ConfigEntry, ConfigEntryGen, PollableId, VERSION, WireMode, bincode_ops,
|
||||
ipc::{
|
||||
ClientMessage, InitMessage, Response, ServerFeature, ServerMessage, WorkspaceSource,
|
||||
},
|
||||
logging, Config, ConfigEntry, ConfigEntryGen, PollableId, WireMode, VERSION,
|
||||
logging,
|
||||
},
|
||||
Axis, Direction, ModifiedKeySym, PciId, Workspace,
|
||||
exec::Command,
|
||||
input::{
|
||||
acceleration::AccelProfile, capability::Capability, FocusFollowsMouseMode, InputDevice,
|
||||
Seat, SwitchEvent,
|
||||
FocusFollowsMouseMode, InputDevice, Seat, SwitchEvent, acceleration::AccelProfile,
|
||||
capability::Capability,
|
||||
},
|
||||
keyboard::{
|
||||
Keymap,
|
||||
mods::{Modifiers, RELEASE},
|
||||
syms::KeySym,
|
||||
Keymap,
|
||||
},
|
||||
logging::LogLevel,
|
||||
tasks::{JoinHandle, JoinSlot},
|
||||
theme::{colors::Colorable, sized::Resizable, Color},
|
||||
theme::{Color, colors::Colorable, sized::Resizable},
|
||||
timer::Timer,
|
||||
video::{
|
||||
connector_type::{ConnectorType, CON_UNKNOWN},
|
||||
Connector, DrmDevice, Format, GfxApi, Mode, TearingMode, Transform, VrrMode,
|
||||
connector_type::{CON_UNKNOWN, ConnectorType},
|
||||
},
|
||||
xwayland::XScalingMode,
|
||||
Axis, Direction, ModifiedKeySym, PciId, Workspace,
|
||||
},
|
||||
bincode::Options,
|
||||
futures_util::task::ArcWake,
|
||||
std::{
|
||||
cell::{Cell, RefCell},
|
||||
collections::{hash_map::Entry, HashMap, VecDeque},
|
||||
collections::{HashMap, VecDeque, hash_map::Entry},
|
||||
future::Future,
|
||||
mem,
|
||||
ops::Deref,
|
||||
os::fd::IntoRawFd,
|
||||
panic::{catch_unwind, AssertUnwindSafe},
|
||||
panic::{AssertUnwindSafe, catch_unwind},
|
||||
pin::Pin,
|
||||
ptr,
|
||||
rc::Rc,
|
||||
slice,
|
||||
sync::{
|
||||
atomic::{AtomicBool, Ordering::Relaxed},
|
||||
Arc, Mutex,
|
||||
atomic::{AtomicBool, Ordering::Relaxed},
|
||||
},
|
||||
task::{Context, Poll, Waker},
|
||||
time::Duration,
|
||||
|
|
|
|||
|
|
@ -1,19 +1,19 @@
|
|||
use {
|
||||
crate::{
|
||||
_private::{PollableId, WireMode},
|
||||
Axis, Direction, PciId, Workspace,
|
||||
input::{
|
||||
acceleration::AccelProfile, capability::Capability, FocusFollowsMouseMode, InputDevice,
|
||||
Seat, SwitchEvent,
|
||||
FocusFollowsMouseMode, InputDevice, Seat, SwitchEvent, acceleration::AccelProfile,
|
||||
capability::Capability,
|
||||
},
|
||||
keyboard::{mods::Modifiers, syms::KeySym, Keymap},
|
||||
keyboard::{Keymap, mods::Modifiers, syms::KeySym},
|
||||
logging::LogLevel,
|
||||
theme::{colors::Colorable, sized::Resizable, Color},
|
||||
theme::{Color, colors::Colorable, sized::Resizable},
|
||||
timer::Timer,
|
||||
video::{
|
||||
connector_type::ConnectorType, Connector, DrmDevice, Format, GfxApi, TearingMode,
|
||||
Transform, VrrMode,
|
||||
Connector, DrmDevice, Format, GfxApi, TearingMode, Transform, VrrMode,
|
||||
connector_type::ConnectorType,
|
||||
},
|
||||
Axis, Direction, PciId, Workspace,
|
||||
_private::{PollableId, WireMode},
|
||||
xwayland::XScalingMode,
|
||||
},
|
||||
serde::{Deserialize, Serialize},
|
||||
|
|
|
|||
|
|
@ -5,10 +5,10 @@ pub mod capability;
|
|||
|
||||
use {
|
||||
crate::{
|
||||
input::{acceleration::AccelProfile, capability::Capability},
|
||||
keyboard::{mods::Modifiers, Keymap},
|
||||
_private::{DEFAULT_SEAT_NAME, ipc::WorkspaceSource},
|
||||
Axis, Direction, ModifiedKeySym, Workspace,
|
||||
_private::{ipc::WorkspaceSource, DEFAULT_SEAT_NAME},
|
||||
input::{acceleration::AccelProfile, capability::Capability},
|
||||
keyboard::{Keymap, mods::Modifiers},
|
||||
video::Connector,
|
||||
},
|
||||
serde::{Deserialize, Serialize},
|
||||
|
|
|
|||
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
use {
|
||||
crate::_private::PollableId,
|
||||
futures_util::{io::AsyncRead, AsyncWrite},
|
||||
futures_util::{AsyncWrite, io::AsyncRead},
|
||||
std::{
|
||||
future::poll_fn,
|
||||
io::{self, ErrorKind, IoSlice, IoSliceMut, Read, Write},
|
||||
os::fd::{AsFd, AsRawFd},
|
||||
pin::Pin,
|
||||
task::{ready, Context, Poll},
|
||||
task::{Context, Poll, ready},
|
||||
},
|
||||
thiserror::Error,
|
||||
uapi::c,
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
//! Keyboard modifiers
|
||||
|
||||
use {
|
||||
crate::{keyboard::syms::KeySym, ModifiedKeySym},
|
||||
crate::{ModifiedKeySym, keyboard::syms::KeySym},
|
||||
serde::{Deserialize, Serialize},
|
||||
std::ops::{BitAnd, BitAndAssign, BitOr, BitOrAssign},
|
||||
};
|
||||
|
|
|
|||
|
|
@ -30,9 +30,7 @@ macro_rules! try_get {
|
|||
}
|
||||
|
||||
macro_rules! get {
|
||||
() => {{
|
||||
get!(Default::default())
|
||||
}};
|
||||
() => {{ get!(Default::default()) }};
|
||||
($def:expr) => {{
|
||||
let client = unsafe {
|
||||
let client = crate::_private::client::CLIENT.with(|client| client.get());
|
||||
|
|
|
|||
|
|
@ -4,10 +4,10 @@ use {
|
|||
crate::{exec::Command, io::Async, tasks::spawn},
|
||||
bstr::ByteSlice,
|
||||
error_reporter::Report,
|
||||
futures_util::{io::BufReader, AsyncBufReadExt},
|
||||
futures_util::{AsyncBufReadExt, io::BufReader},
|
||||
serde::Deserialize,
|
||||
std::borrow::BorrowMut,
|
||||
uapi::{c, OwnedFd},
|
||||
uapi::{OwnedFd, c},
|
||||
};
|
||||
|
||||
/// Sets the status text.
|
||||
|
|
|
|||
|
|
@ -75,7 +75,10 @@ impl Color {
|
|||
if !validate_f32_all([r, g, b, a]) {
|
||||
Self::BLACK
|
||||
} else if r > a || g > a || b > a {
|
||||
log::warn!("f32 values {:?} are not valid valid for a premultiplied color. Using solid black instead.", [r, g, b, a]);
|
||||
log::warn!(
|
||||
"f32 values {:?} are not valid valid for a premultiplied color. Using solid black instead.",
|
||||
[r, g, b, a]
|
||||
);
|
||||
Self::BLACK
|
||||
} else {
|
||||
Self { r, g, b, a }
|
||||
|
|
|
|||
|
|
@ -2,14 +2,14 @@
|
|||
|
||||
use {
|
||||
crate::{
|
||||
video::connector_type::{
|
||||
ConnectorType, CON_9PIN_DIN, CON_COMPONENT, CON_COMPOSITE, CON_DISPLAY_PORT, CON_DPI,
|
||||
CON_DSI, CON_DVIA, CON_DVID, CON_DVII, CON_EDP, CON_EMBEDDED_WINDOW, CON_HDMIA,
|
||||
CON_HDMIB, CON_LVDS, CON_SPI, CON_SVIDEO, CON_TV, CON_UNKNOWN, CON_USB, CON_VGA,
|
||||
CON_VIRTUAL, CON_WRITEBACK,
|
||||
},
|
||||
PciId,
|
||||
_private::WireMode,
|
||||
PciId,
|
||||
video::connector_type::{
|
||||
CON_9PIN_DIN, CON_COMPONENT, CON_COMPOSITE, CON_DISPLAY_PORT, CON_DPI, CON_DSI,
|
||||
CON_DVIA, CON_DVID, CON_DVII, CON_EDP, CON_EMBEDDED_WINDOW, CON_HDMIA, CON_HDMIB,
|
||||
CON_LVDS, CON_SPI, CON_SVIDEO, CON_TV, CON_UNKNOWN, CON_USB, CON_VGA, CON_VIRTUAL,
|
||||
CON_WRITEBACK, ConnectorType,
|
||||
},
|
||||
},
|
||||
serde::{Deserialize, Serialize},
|
||||
std::{str::FromStr, time::Duration},
|
||||
|
|
|
|||
|
|
@ -1,13 +1,13 @@
|
|||
use {
|
||||
crate::{
|
||||
async_engine::SpawnedFuture,
|
||||
client::{ClientCaps, CAPS_DEFAULT},
|
||||
client::{CAPS_DEFAULT, ClientCaps},
|
||||
state::State,
|
||||
utils::{errorfmt::ErrorFmt, oserror::OsError, xrd::xrd},
|
||||
},
|
||||
std::rc::Rc,
|
||||
thiserror::Error,
|
||||
uapi::{c, format_ustr, Errno, OwnedFd, Ustr, Ustring},
|
||||
uapi::{Errno, OwnedFd, Ustr, Ustring, c, format_ustr},
|
||||
};
|
||||
|
||||
#[derive(Debug, Error)]
|
||||
|
|
|
|||
|
|
@ -2,9 +2,9 @@ use {
|
|||
crate::{
|
||||
format::Format,
|
||||
video::{
|
||||
Modifier,
|
||||
dmabuf::{DmaBuf, DmaBufIds},
|
||||
drm::Drm,
|
||||
Modifier,
|
||||
},
|
||||
},
|
||||
std::{error::Error, rc::Rc},
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ use {
|
|||
fmt::{Debug, Display, Formatter},
|
||||
rc::Rc,
|
||||
},
|
||||
uapi::{c, OwnedFd},
|
||||
uapi::{OwnedFd, c},
|
||||
};
|
||||
|
||||
linear_ids!(ConnectorIds, ConnectorId);
|
||||
|
|
|
|||
|
|
@ -24,13 +24,13 @@ use {
|
|||
},
|
||||
},
|
||||
libinput::{
|
||||
LibInput, LibInputAdapter, LibInputError,
|
||||
consts::{
|
||||
AccelProfile, LIBINPUT_CONFIG_ACCEL_PROFILE_ADAPTIVE,
|
||||
LIBINPUT_CONFIG_ACCEL_PROFILE_FLAT, LIBINPUT_DEVICE_CAP_TABLET_PAD,
|
||||
LIBINPUT_DEVICE_CAP_TABLET_TOOL,
|
||||
},
|
||||
device::{LibInputDevice, RegisteredDevice},
|
||||
LibInput, LibInputAdapter, LibInputError,
|
||||
},
|
||||
logind::{LogindError, Session},
|
||||
state::State,
|
||||
|
|
@ -46,7 +46,7 @@ use {
|
|||
syncqueue::SyncQueue,
|
||||
},
|
||||
video::{
|
||||
drm::{DrmError, DRM_MODE_ATOMIC_ALLOW_MODESET},
|
||||
drm::{DRM_MODE_ATOMIC_ALLOW_MODESET, DrmError},
|
||||
gbm::GbmError,
|
||||
},
|
||||
},
|
||||
|
|
@ -61,7 +61,7 @@ use {
|
|||
rc::Rc,
|
||||
},
|
||||
thiserror::Error,
|
||||
uapi::{c, OwnedFd},
|
||||
uapi::{OwnedFd, c},
|
||||
};
|
||||
|
||||
#[derive(Debug, Error)]
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@ use {
|
|||
crate::{
|
||||
backend::{BackendEvent, ConnectorEvent},
|
||||
backends::metal::{
|
||||
video::{FrontState, MetalDrmDeviceData, PendingDrmDevice},
|
||||
MetalBackend, MetalDevice, MetalError, MetalInputDevice,
|
||||
video::{FrontState, MetalDrmDeviceData, PendingDrmDevice},
|
||||
},
|
||||
dbus::{DbusError, TRUE},
|
||||
udev::UdevDevice,
|
||||
|
|
@ -20,7 +20,7 @@ use {
|
|||
},
|
||||
bstr::ByteSlice,
|
||||
std::{cell::Cell, rc::Rc},
|
||||
uapi::{c, OwnedFd},
|
||||
uapi::{OwnedFd, c},
|
||||
};
|
||||
|
||||
const DRM: &[u8] = b"drm";
|
||||
|
|
|
|||
|
|
@ -2,14 +2,14 @@ use {
|
|||
crate::{
|
||||
backend::Connector,
|
||||
backends::metal::{
|
||||
MetalError,
|
||||
video::{
|
||||
MetalConnector, MetalCrtc, MetalHardwareCursorChange, MetalPlane, RenderBuffer,
|
||||
},
|
||||
MetalError,
|
||||
},
|
||||
gfx_api::{
|
||||
create_render_pass, AcquireSync, BufferResv, GfxApiOpt, GfxRenderPass, GfxTexture,
|
||||
ReleaseSync, SyncFile,
|
||||
AcquireSync, BufferResv, GfxApiOpt, GfxRenderPass, GfxTexture, ReleaseSync, SyncFile,
|
||||
create_render_pass,
|
||||
},
|
||||
rect::Region,
|
||||
theme::Color,
|
||||
|
|
@ -20,8 +20,8 @@ use {
|
|||
video::{
|
||||
dmabuf::DmaBufId,
|
||||
drm::{
|
||||
DrmError, DrmFramebuffer, DRM_MODE_ATOMIC_NONBLOCK, DRM_MODE_PAGE_FLIP_ASYNC,
|
||||
DRM_MODE_PAGE_FLIP_EVENT,
|
||||
DRM_MODE_ATOMIC_NONBLOCK, DRM_MODE_PAGE_FLIP_ASYNC, DRM_MODE_PAGE_FLIP_EVENT,
|
||||
DrmError, DrmFramebuffer,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
|
@ -248,7 +248,9 @@ impl MetalConnector {
|
|||
if let Err(e) = res {
|
||||
reset_damage();
|
||||
if let MetalError::Commit(DrmError::Atomic(OsError(c::EACCES))) = e {
|
||||
log::debug!("Could not perform atomic commit, likely because we're no longer the DRM master");
|
||||
log::debug!(
|
||||
"Could not perform atomic commit, likely because we're no longer the DRM master"
|
||||
);
|
||||
return Ok(());
|
||||
}
|
||||
Err(e)
|
||||
|
|
|
|||
|
|
@ -8,18 +8,18 @@ use {
|
|||
HardwareCursorUpdate, Mode, MonitorInfo,
|
||||
},
|
||||
backends::metal::{
|
||||
present::{
|
||||
DirectScanoutCache, PresentFb, DEFAULT_POST_COMMIT_MARGIN,
|
||||
DEFAULT_PRE_COMMIT_MARGIN, POST_COMMIT_MARGIN_DELTA,
|
||||
},
|
||||
MetalBackend, MetalError,
|
||||
present::{
|
||||
DEFAULT_POST_COMMIT_MARGIN, DEFAULT_PRE_COMMIT_MARGIN, DirectScanoutCache,
|
||||
POST_COMMIT_MARGIN_DELTA, PresentFb,
|
||||
},
|
||||
},
|
||||
drm_feedback::DrmFeedback,
|
||||
edid::{CtaDataBlock, Descriptor, EdidExtension},
|
||||
format::{Format, ARGB8888, XRGB8888},
|
||||
format::{ARGB8888, Format, XRGB8888},
|
||||
gfx_api::{
|
||||
needs_render_usage, AcquireSync, GfxContext, GfxFramebuffer, GfxTexture, ReleaseSync,
|
||||
SyncFile,
|
||||
AcquireSync, GfxContext, GfxFramebuffer, GfxTexture, ReleaseSync, SyncFile,
|
||||
needs_render_usage,
|
||||
},
|
||||
ifs::{
|
||||
wl_output::OutputId,
|
||||
|
|
@ -35,22 +35,22 @@ use {
|
|||
numcell::NumCell, on_change::OnChange, opaque_cell::OpaqueCell, oserror::OsError,
|
||||
},
|
||||
video::{
|
||||
INVALID_MODIFIER, Modifier,
|
||||
dmabuf::DmaBufId,
|
||||
drm::{
|
||||
drm_mode_modeinfo, Change, ConnectorStatus, ConnectorType, DrmBlob, DrmConnector,
|
||||
DrmCrtc, DrmEncoder, DrmError, DrmEvent, DrmFramebuffer, DrmLease, DrmMaster,
|
||||
DrmModeInfo, DrmObject, DrmPlane, DrmProperty, DrmPropertyDefinition,
|
||||
DrmPropertyType, DrmVersion, PropBlob, DRM_CLIENT_CAP_ATOMIC,
|
||||
DRM_MODE_ATOMIC_ALLOW_MODESET,
|
||||
Change, ConnectorStatus, ConnectorType, DRM_CLIENT_CAP_ATOMIC,
|
||||
DRM_MODE_ATOMIC_ALLOW_MODESET, DrmBlob, DrmConnector, DrmCrtc, DrmEncoder,
|
||||
DrmError, DrmEvent, DrmFramebuffer, DrmLease, DrmMaster, DrmModeInfo, DrmObject,
|
||||
DrmPlane, DrmProperty, DrmPropertyDefinition, DrmPropertyType, DrmVersion,
|
||||
PropBlob, drm_mode_modeinfo,
|
||||
},
|
||||
gbm::{GbmBo, GbmDevice, GBM_BO_USE_LINEAR, GBM_BO_USE_RENDERING, GBM_BO_USE_SCANOUT},
|
||||
Modifier, INVALID_MODIFIER,
|
||||
gbm::{GBM_BO_USE_LINEAR, GBM_BO_USE_RENDERING, GBM_BO_USE_SCANOUT, GbmBo, GbmDevice},
|
||||
},
|
||||
},
|
||||
ahash::{AHashMap, AHashSet},
|
||||
arrayvec::ArrayVec,
|
||||
bstr::{BString, ByteSlice},
|
||||
indexmap::{indexset, IndexMap, IndexSet},
|
||||
indexmap::{IndexMap, IndexSet, indexset},
|
||||
isnt::std_1::collections::IsntHashMap2Ext,
|
||||
jay_config::video::GfxApi,
|
||||
std::{
|
||||
|
|
@ -64,8 +64,8 @@ use {
|
|||
rc::Rc,
|
||||
},
|
||||
uapi::{
|
||||
c::{self, dev_t},
|
||||
OwnedFd,
|
||||
c::{self, dev_t},
|
||||
},
|
||||
};
|
||||
|
||||
|
|
@ -213,7 +213,9 @@ impl BackendDrmDevice for MetalDrmDevice {
|
|||
}
|
||||
}
|
||||
_ => {
|
||||
log::error!("Connector is logically available for leasing, has a lease ID, and has no entry in leases_to_break");
|
||||
log::error!(
|
||||
"Connector is logically available for leasing, has a lease ID, and has no entry in leases_to_break"
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1477,7 +1479,7 @@ fn create_plane(plane: DrmPlane, master: &Rc<DrmMaster>) -> Result<MetalPlane, D
|
|||
_ => {
|
||||
return Err(DrmError::MissingProperty(
|
||||
"type".to_string().into_boxed_str(),
|
||||
))
|
||||
));
|
||||
}
|
||||
};
|
||||
let default_properties = create_default_properties(
|
||||
|
|
@ -2292,14 +2294,18 @@ impl MetalBackend {
|
|||
}
|
||||
if let Some(plane) = c.primary_plane.get() {
|
||||
if plane.crtc_id.value.get() != crtc.id {
|
||||
log::warn!("Cannot preserve connector whose primary plane is attached to a different crtc");
|
||||
log::warn!(
|
||||
"Cannot preserve connector whose primary plane is attached to a different crtc"
|
||||
);
|
||||
fail!(c.id);
|
||||
}
|
||||
}
|
||||
if let Some(plane) = c.cursor_plane.get() {
|
||||
let crtc_id = plane.crtc_id.value.get();
|
||||
if crtc_id.is_some() && crtc_id != crtc.id {
|
||||
log::warn!("Cannot preserve connector whose cursor plane is attached to a different crtc");
|
||||
log::warn!(
|
||||
"Cannot preserve connector whose cursor plane is attached to a different crtc"
|
||||
);
|
||||
fail!(c.id);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,10 +3,10 @@ use {
|
|||
allocator::BufferObject,
|
||||
async_engine::{Phase, SpawnedFuture},
|
||||
backend::{
|
||||
AxisSource, Backend, BackendDrmDevice, BackendEvent, Connector, ConnectorEvent,
|
||||
ConnectorId, ConnectorKernelId, DrmDeviceId, DrmEvent, InputDevice,
|
||||
AXIS_120, AxisSource, Backend, BackendDrmDevice, BackendEvent, Connector,
|
||||
ConnectorEvent, ConnectorId, ConnectorKernelId, DrmDeviceId, DrmEvent, InputDevice,
|
||||
InputDeviceAccelProfile, InputDeviceCapability, InputDeviceId, InputEvent, KeyState,
|
||||
Mode, MonitorInfo, ScrollAxis, TransformMatrix, AXIS_120,
|
||||
Mode, MonitorInfo, ScrollAxis, TransformMatrix,
|
||||
},
|
||||
fixed::Fixed,
|
||||
format::XRGB8888,
|
||||
|
|
@ -20,7 +20,7 @@ use {
|
|||
},
|
||||
video::{
|
||||
drm::{ConnectorType, Drm, DrmError, DrmVersion},
|
||||
gbm::{GbmBo, GbmDevice, GbmError, GBM_BO_USE_RENDERING},
|
||||
gbm::{GBM_BO_USE_RENDERING, GbmBo, GbmDevice, GbmError},
|
||||
},
|
||||
wire_xcon::{
|
||||
ChangeProperty, ChangeWindowAttributes, ConfigureNotify, CreateCursor, CreatePixmap,
|
||||
|
|
@ -33,6 +33,7 @@ use {
|
|||
XkbPerClientFlags, XkbUseExtension,
|
||||
},
|
||||
xcon::{
|
||||
Event, XEvent, Xcon, XconError,
|
||||
consts::{
|
||||
ATOM_STRING, ATOM_WM_CLASS, EVENT_MASK_EXPOSURE, EVENT_MASK_STRUCTURE_NOTIFY,
|
||||
EVENT_MASK_VISIBILITY_CHANGE, GRAB_MODE_ASYNC, GRAB_STATUS_SUCCESS,
|
||||
|
|
@ -46,7 +47,6 @@ use {
|
|||
XI_EVENT_MASK_TOUCH_BEGIN, XI_EVENT_MASK_TOUCH_END, XI_EVENT_MASK_TOUCH_UPDATE,
|
||||
XKB_PER_CLIENT_FLAG_DETECTABLE_AUTO_REPEAT,
|
||||
},
|
||||
Event, XEvent, Xcon, XconError,
|
||||
},
|
||||
},
|
||||
jay_config::video::GfxApi,
|
||||
|
|
|
|||
|
|
@ -21,11 +21,11 @@ use {
|
|||
xwayland::XwaylandArgs,
|
||||
},
|
||||
compositor::start_compositor,
|
||||
format::{ref_formats, Format},
|
||||
format::{Format, ref_formats},
|
||||
portal,
|
||||
},
|
||||
::log::Level,
|
||||
clap::{builder::PossibleValue, Args, Parser, Subcommand, ValueEnum, ValueHint},
|
||||
clap::{Args, Parser, Subcommand, ValueEnum, ValueHint, builder::PossibleValue},
|
||||
clap_complete::Shell,
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use {
|
||||
crate::{
|
||||
cli::{color::parse_color, duration::parse_duration, GlobalArgs},
|
||||
tools::tool_client::{with_tool_client, ToolClient},
|
||||
cli::{GlobalArgs, color::parse_color, duration::parse_duration},
|
||||
tools::tool_client::{ToolClient, with_tool_client},
|
||||
wire::jay_damage_tracking::{SetVisualizerColor, SetVisualizerDecay, SetVisualizerEnabled},
|
||||
},
|
||||
clap::{Args, Subcommand},
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
use {
|
||||
crate::{
|
||||
cli::{duration::parse_duration, GlobalArgs, IdleArgs},
|
||||
tools::tool_client::{with_tool_client, Handle, ToolClient},
|
||||
cli::{GlobalArgs, IdleArgs, duration::parse_duration},
|
||||
tools::tool_client::{Handle, ToolClient, with_tool_client},
|
||||
utils::{debug_fn::debug_fn, stack::Stack},
|
||||
wire::{jay_compositor, jay_idle, JayIdleId, WlSurfaceId},
|
||||
wire::{JayIdleId, WlSurfaceId, jay_compositor, jay_idle},
|
||||
},
|
||||
clap::{Args, Subcommand},
|
||||
std::{cell::Cell, rc::Rc},
|
||||
|
|
|
|||
|
|
@ -6,20 +6,20 @@ use {
|
|||
libinput::consts::{
|
||||
LIBINPUT_CONFIG_ACCEL_PROFILE_ADAPTIVE, LIBINPUT_CONFIG_ACCEL_PROFILE_FLAT,
|
||||
},
|
||||
tools::tool_client::{with_tool_client, Handle, ToolClient},
|
||||
tools::tool_client::{Handle, ToolClient, with_tool_client},
|
||||
utils::{errorfmt::ErrorFmt, string_ext::StringExt},
|
||||
wire::{jay_compositor, jay_input, JayInputId},
|
||||
wire::{JayInputId, jay_compositor, jay_input},
|
||||
},
|
||||
clap::{Args, Subcommand, ValueEnum, ValueHint},
|
||||
isnt::std_1::vec::IsntVecExt,
|
||||
std::{
|
||||
cell::RefCell,
|
||||
io::{stdin, stdout, Read, Write},
|
||||
io::{Read, Write, stdin, stdout},
|
||||
mem,
|
||||
ops::DerefMut,
|
||||
rc::Rc,
|
||||
},
|
||||
uapi::{c, OwnedFd},
|
||||
uapi::{OwnedFd, c},
|
||||
};
|
||||
|
||||
#[derive(Args, Debug)]
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use {
|
||||
crate::{
|
||||
cli::{GlobalArgs, LogArgs},
|
||||
tools::tool_client::{with_tool_client, Handle, ToolClient},
|
||||
tools::tool_client::{Handle, ToolClient, with_tool_client},
|
||||
utils::errorfmt::ErrorFmt,
|
||||
wire::{jay_compositor, jay_log_file},
|
||||
},
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use {
|
||||
crate::{
|
||||
cli::GlobalArgs,
|
||||
tools::tool_client::{with_tool_client, ToolClient},
|
||||
tools::tool_client::{ToolClient, with_tool_client},
|
||||
wire::jay_compositor::Quit,
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -3,9 +3,9 @@ use {
|
|||
cli::GlobalArgs,
|
||||
format::{Format, XRGB8888},
|
||||
scale::Scale,
|
||||
tools::tool_client::{with_tool_client, Handle, ToolClient},
|
||||
tools::tool_client::{Handle, ToolClient, with_tool_client},
|
||||
utils::{errorfmt::ErrorFmt, transform_ext::TransformExt},
|
||||
wire::{jay_compositor, jay_randr, JayRandrId},
|
||||
wire::{JayRandrId, jay_compositor, jay_randr},
|
||||
},
|
||||
clap::{Args, Subcommand, ValueEnum},
|
||||
isnt::std_1::vec::IsntVecExt,
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ use {
|
|||
cli::{GlobalArgs, ScreenshotArgs, ScreenshotFormat},
|
||||
format::XRGB8888,
|
||||
gfx_apis,
|
||||
tools::tool_client::{with_tool_client, Handle, ToolClient},
|
||||
tools::tool_client::{Handle, ToolClient, with_tool_client},
|
||||
udmabuf::{Udmabuf, UdmabufError},
|
||||
utils::{errorfmt::ErrorFmt, queue::AsyncQueue, windows::WindowsExt},
|
||||
video::{
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@ use {
|
|||
crate::{
|
||||
cli::{GlobalArgs, SeatTestArgs},
|
||||
fixed::Fixed,
|
||||
ifs::wl_seat::wl_pointer::{PendingScroll, CONTINUOUS, FINGER, WHEEL},
|
||||
tools::tool_client::{with_tool_client, Handle, ToolClient},
|
||||
ifs::wl_seat::wl_pointer::{CONTINUOUS, FINGER, PendingScroll, WHEEL},
|
||||
tools::tool_client::{Handle, ToolClient, with_tool_client},
|
||||
wire::{
|
||||
jay_compositor::{GetSeats, Seat, SeatEvents},
|
||||
jay_seat_events::{
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use {
|
||||
crate::{
|
||||
cli::{GlobalArgs, SetLogArgs},
|
||||
tools::tool_client::{with_tool_client, ToolClient},
|
||||
tools::tool_client::{ToolClient, with_tool_client},
|
||||
wire::jay_compositor::SetLogLevel,
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use {
|
||||
crate::{
|
||||
cli::GlobalArgs,
|
||||
tools::tool_client::{with_tool_client, ToolClient},
|
||||
tools::tool_client::{ToolClient, with_tool_client},
|
||||
wire::jay_compositor::Unlock,
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
use {
|
||||
crate::{
|
||||
cli::GlobalArgs,
|
||||
tools::tool_client::{with_tool_client, Handle, ToolClient},
|
||||
wire::{jay_compositor, jay_xwayland, JayXwaylandId},
|
||||
tools::tool_client::{Handle, ToolClient, with_tool_client},
|
||||
wire::{JayXwaylandId, jay_compositor, jay_xwayland},
|
||||
},
|
||||
clap::{Args, Subcommand, ValueEnum},
|
||||
jay_config::xwayland::XScalingMode,
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ use {
|
|||
ifs::{
|
||||
wl_display::WlDisplay,
|
||||
wl_registry::WlRegistry,
|
||||
wl_surface::{commit_timeline::CommitTimelines, WlSurface},
|
||||
wl_surface::{WlSurface, commit_timeline::CommitTimelines},
|
||||
},
|
||||
leaks::Tracker,
|
||||
object::{Interface, Object, ObjectId, WL_DISPLAY_ID},
|
||||
|
|
@ -18,7 +18,7 @@ use {
|
|||
errorfmt::ErrorFmt,
|
||||
numcell::NumCell,
|
||||
pending_serial::PendingSerial,
|
||||
pid_info::{get_pid_info, get_socket_creds, PidInfo},
|
||||
pid_info::{PidInfo, get_pid_info, get_socket_creds},
|
||||
},
|
||||
wire::WlRegistryId,
|
||||
},
|
||||
|
|
@ -32,7 +32,7 @@ use {
|
|||
ops::DerefMut,
|
||||
rc::Rc,
|
||||
},
|
||||
uapi::{c, OwnedFd},
|
||||
uapi::{OwnedFd, c},
|
||||
};
|
||||
pub use {
|
||||
error::{ClientError, ParserError},
|
||||
|
|
|
|||
|
|
@ -22,10 +22,10 @@ use {
|
|||
wl_output::WlOutput,
|
||||
wl_region::WlRegion,
|
||||
wl_registry::WlRegistry,
|
||||
wl_seat::{tablet::zwp_tablet_tool_v2::ZwpTabletToolV2, wl_pointer::WlPointer, WlSeat},
|
||||
wl_seat::{WlSeat, tablet::zwp_tablet_tool_v2::ZwpTabletToolV2, wl_pointer::WlPointer},
|
||||
wl_surface::{
|
||||
xdg_surface::{xdg_popup::XdgPopup, xdg_toplevel::XdgToplevel, XdgSurface},
|
||||
WlSurface,
|
||||
xdg_surface::{XdgSurface, xdg_popup::XdgPopup, xdg_toplevel::XdgToplevel},
|
||||
},
|
||||
workspace_manager::ext_workspace_group_handle_v1::ExtWorkspaceGroupHandleV1,
|
||||
wp_drm_lease_connector_v1::WpDrmLeaseConnectorV1,
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ use {
|
|||
vec_ext::VecExt,
|
||||
},
|
||||
},
|
||||
futures_util::{select, FutureExt},
|
||||
futures_util::{FutureExt, select},
|
||||
std::{collections::VecDeque, mem, rc::Rc, time::Duration},
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -12,12 +12,12 @@ use {
|
|||
ops::Deref,
|
||||
ptr,
|
||||
rc::Rc,
|
||||
sync::atomic::{compiler_fence, Ordering},
|
||||
sync::atomic::{Ordering, compiler_fence},
|
||||
},
|
||||
thiserror::Error,
|
||||
uapi::{
|
||||
c::{self, raise},
|
||||
OwnedFd,
|
||||
c::{self, raise},
|
||||
},
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ use {
|
|||
clientmem::{self, ClientMemError},
|
||||
config::ConfigProxy,
|
||||
cpu_worker::{CpuWorker, CpuWorkerError},
|
||||
damage::{visualize_damage, DamageVisualizer},
|
||||
damage::{DamageVisualizer, visualize_damage},
|
||||
dbus::Dbus,
|
||||
ei::ei_client::EiClients,
|
||||
forker,
|
||||
|
|
@ -22,7 +22,7 @@ use {
|
|||
ifs::{
|
||||
jay_screencast::{perform_screencast_realloc, perform_toplevel_screencasts},
|
||||
wl_output::{OutputId, PersistentOutputState, WlOutputGlobal},
|
||||
wl_surface::{zwp_input_popup_surface_v2::input_popup_positioning, NoneSurfaceExt},
|
||||
wl_surface::{NoneSurfaceExt, zwp_input_popup_surface_v2::input_popup_positioning},
|
||||
workspace_manager::workspace_manager_done,
|
||||
},
|
||||
io_uring::{IoUring, IoUringError},
|
||||
|
|
@ -37,9 +37,9 @@ use {
|
|||
tasks::{self, handle_const_40hz_latch, idle},
|
||||
tracy::enable_profiler,
|
||||
tree::{
|
||||
DisplayNode, NodeIds, OutputNode, TearingMode, VrrMode, WorkspaceNode,
|
||||
container_layout, container_render_positions, container_render_titles, float_layout,
|
||||
float_titles, output_render_data, placeholder_render_textures, DisplayNode, NodeIds,
|
||||
OutputNode, TearingMode, VrrMode, WorkspaceNode,
|
||||
float_titles, output_render_data, placeholder_render_textures,
|
||||
},
|
||||
user_session::import_environment,
|
||||
utils::{
|
||||
|
|
|
|||
|
|
@ -16,9 +16,8 @@ use {
|
|||
bincode::Options,
|
||||
jay_config::{
|
||||
_private::{
|
||||
bincode_ops,
|
||||
ConfigEntry, VERSION, bincode_ops,
|
||||
ipc::{InitMessage, ServerFeature, ServerMessage, V1InitMessage},
|
||||
ConfigEntry, VERSION,
|
||||
},
|
||||
input::{InputDevice, Seat, SwitchEvent},
|
||||
keyboard::{mods::Modifiers, syms::KeySym},
|
||||
|
|
|
|||
|
|
@ -16,8 +16,8 @@ use {
|
|||
state::{ConnectorData, DeviceHandlerData, DrmDevData, OutputData, State},
|
||||
theme::{Color, ThemeSized},
|
||||
tree::{
|
||||
move_ws_to_output, ContainerNode, ContainerSplit, FloatNode, Node, NodeVisitorBase,
|
||||
OutputNode, TearingMode, VrrMode, WsMoveConfig,
|
||||
ContainerNode, ContainerSplit, FloatNode, Node, NodeVisitorBase, OutputNode,
|
||||
TearingMode, VrrMode, WsMoveConfig, move_ws_to_output,
|
||||
},
|
||||
utils::{
|
||||
asyncevent::AsyncEvent,
|
||||
|
|
@ -33,19 +33,19 @@ use {
|
|||
bincode::Options,
|
||||
jay_config::{
|
||||
_private::{
|
||||
bincode_ops,
|
||||
PollableId, WireMode, bincode_ops,
|
||||
ipc::{ClientMessage, Response, ServerMessage, WorkspaceSource},
|
||||
PollableId, WireMode,
|
||||
},
|
||||
Axis, Direction, Workspace,
|
||||
input::{
|
||||
acceleration::{AccelProfile, ACCEL_PROFILE_ADAPTIVE, ACCEL_PROFILE_FLAT},
|
||||
capability::{
|
||||
Capability, CAP_GESTURE, CAP_KEYBOARD, CAP_POINTER, CAP_SWITCH, CAP_TABLET_PAD,
|
||||
CAP_TABLET_TOOL, CAP_TOUCH,
|
||||
},
|
||||
FocusFollowsMouseMode, InputDevice, Seat,
|
||||
acceleration::{ACCEL_PROFILE_ADAPTIVE, ACCEL_PROFILE_FLAT, AccelProfile},
|
||||
capability::{
|
||||
CAP_GESTURE, CAP_KEYBOARD, CAP_POINTER, CAP_SWITCH, CAP_TABLET_PAD,
|
||||
CAP_TABLET_TOOL, CAP_TOUCH, Capability,
|
||||
},
|
||||
keyboard::{mods::Modifiers, syms::KeySym, Keymap},
|
||||
},
|
||||
keyboard::{Keymap, mods::Modifiers, syms::KeySym},
|
||||
logging::LogLevel,
|
||||
theme::{colors::Colorable, sized::Resizable},
|
||||
timer::Timer as JayTimer,
|
||||
|
|
@ -54,13 +54,12 @@ use {
|
|||
Transform, VrrMode as ConfigVrrMode,
|
||||
},
|
||||
xwayland::XScalingMode,
|
||||
Axis, Direction, Workspace,
|
||||
},
|
||||
libloading::Library,
|
||||
log::Level,
|
||||
std::{cell::Cell, ops::Deref, rc::Rc, sync::Arc, time::Duration},
|
||||
thiserror::Error,
|
||||
uapi::{c, fcntl_dupfd_cloexec, OwnedFd},
|
||||
uapi::{OwnedFd, c, fcntl_dupfd_cloexec},
|
||||
};
|
||||
|
||||
pub(super) struct ConfigProxyHandler {
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ use {
|
|||
thread,
|
||||
},
|
||||
thiserror::Error,
|
||||
uapi::{c, OwnedFd},
|
||||
uapi::{OwnedFd, c},
|
||||
};
|
||||
|
||||
pub trait CpuJob {
|
||||
|
|
|
|||
|
|
@ -10,12 +10,12 @@ use {
|
|||
rc::Rc,
|
||||
slice,
|
||||
sync::{
|
||||
atomic::{AtomicBool, AtomicU64, Ordering::Relaxed},
|
||||
Arc,
|
||||
atomic::{AtomicBool, AtomicU64, Ordering::Relaxed},
|
||||
},
|
||||
},
|
||||
thiserror::Error,
|
||||
uapi::{c, Fd},
|
||||
uapi::{Fd, c},
|
||||
};
|
||||
|
||||
#[derive(Debug, Error)]
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ use {
|
|||
wheel::Wheel,
|
||||
},
|
||||
std::{any::Any, future::pending, rc::Rc, sync::Arc},
|
||||
uapi::{c::EFD_CLOEXEC, OwnedFd},
|
||||
uapi::{OwnedFd, c::EFD_CLOEXEC},
|
||||
};
|
||||
|
||||
struct Job {
|
||||
|
|
|
|||
|
|
@ -736,8 +736,17 @@ fn parser_cursor_file<R: BufRead + Seek>(
|
|||
let mut images = AHashMap::new();
|
||||
for position in positions {
|
||||
r.seek(SeekFrom::Start(position as u64))?;
|
||||
let [_chunk_header, _type_, _size, _version, width, height, xhot, yhot, delay] =
|
||||
read_u32_n(r)?;
|
||||
let [
|
||||
_chunk_header,
|
||||
_type_,
|
||||
_size,
|
||||
_version,
|
||||
width,
|
||||
height,
|
||||
xhot,
|
||||
yhot,
|
||||
delay,
|
||||
] = read_u32_n(r)?;
|
||||
let [width, height, xhot, yhot] = u32_to_i32([width, height, xhot, yhot])?;
|
||||
let mut image = XCursorImage {
|
||||
width,
|
||||
|
|
@ -760,7 +769,9 @@ fn parser_cursor_file<R: BufRead + Seek>(
|
|||
}
|
||||
let mut num = targets[0].positions.len();
|
||||
if num > 1 && targets.iter().any(|t| t.positions.len() != num) {
|
||||
log::warn!("Cursor file contains animated cursor but not all scales have the same number of images");
|
||||
log::warn!(
|
||||
"Cursor file contains animated cursor but not all scales have the same number of images"
|
||||
);
|
||||
num = 1;
|
||||
}
|
||||
let mut res = vec![];
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use {
|
||||
crate::{
|
||||
backend::HardwareCursorUpdate,
|
||||
cursor::{Cursor, KnownCursor, DEFAULT_CURSOR_SIZE},
|
||||
cursor::{Cursor, DEFAULT_CURSOR_SIZE, KnownCursor},
|
||||
fixed::Fixed,
|
||||
gfx_api::{AcquireSync, ReleaseSync},
|
||||
rect::Rect,
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ use {
|
|||
run_toplevel::RunToplevel,
|
||||
stack::Stack,
|
||||
vecstorage::VecStorage,
|
||||
xrd::{xrd, XRD},
|
||||
xrd::{XRD, xrd},
|
||||
},
|
||||
wire_dbus::{
|
||||
org,
|
||||
|
|
@ -858,8 +858,8 @@ impl MethodHandlerApi for PropertyGetAllHandlerProxy {
|
|||
pub mod prelude {
|
||||
pub use {
|
||||
super::{
|
||||
types::{Bool, DictEntry, ObjectPath, Variant},
|
||||
DbusError, DbusType, Formatter, Message, MethodCall, Parser, Property, Signal,
|
||||
types::{Bool, DictEntry, ObjectPath, Variant},
|
||||
},
|
||||
std::{borrow::Cow, rc::Rc},
|
||||
uapi::OwnedFd,
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use {
|
||||
crate::{
|
||||
dbus::{incoming::handle_incoming, outgoing::handle_outgoing, DbusError, DbusSocket},
|
||||
dbus::{DbusError, DbusSocket, incoming::handle_incoming, outgoing::handle_outgoing},
|
||||
utils::{buf::Buf, errorfmt::ErrorFmt, hex},
|
||||
},
|
||||
std::{ops::Deref, rc::Rc},
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ use {
|
|||
TY_SIGNATURE, TY_STRING, TY_UINT16, TY_UINT32, TY_UINT64, TY_UNIX_FD, TY_VARIANT,
|
||||
},
|
||||
crate::{
|
||||
dbus::{types::Variant, DbusError, DynamicType, Parser},
|
||||
dbus::{DbusError, DynamicType, Parser, types::Variant},
|
||||
utils::buf::DynamicBuf,
|
||||
},
|
||||
std::ops::Deref,
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use {
|
||||
crate::{
|
||||
dbus::{types::Variant, DbusType, Formatter},
|
||||
dbus::{DbusType, Formatter, types::Variant},
|
||||
utils::buf::DynamicBuf,
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use {
|
||||
crate::{
|
||||
async_engine::AsyncEngine,
|
||||
dbus::{auth::handle_auth, DbusError, DbusHolder, DbusSocket},
|
||||
dbus::{DbusError, DbusHolder, DbusSocket, auth::handle_auth},
|
||||
io_uring::IoUring,
|
||||
utils::{bufio::BufIo, errorfmt::ErrorFmt, numcell::NumCell, run_toplevel::RunToplevel},
|
||||
wire_dbus::org,
|
||||
|
|
|
|||
|
|
@ -5,9 +5,9 @@ use {
|
|||
},
|
||||
crate::{
|
||||
dbus::{
|
||||
CallError, DbusError, DbusSocket, Headers, MemberHandlerKey, Message, MethodHandlerApi,
|
||||
Parser, PropertyGetAllHandlerProxy, PropertyGetHandlerProxy, MSG_ERROR,
|
||||
MSG_METHOD_CALL, MSG_METHOD_RETURN, MSG_SIGNAL, NO_REPLY_EXPECTED,
|
||||
CallError, DbusError, DbusSocket, Headers, MSG_ERROR, MSG_METHOD_CALL,
|
||||
MSG_METHOD_RETURN, MSG_SIGNAL, MemberHandlerKey, Message, MethodHandlerApi,
|
||||
NO_REPLY_EXPECTED, Parser, PropertyGetAllHandlerProxy, PropertyGetHandlerProxy,
|
||||
},
|
||||
utils::{
|
||||
bitflags::BitflagsExt,
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use {
|
||||
crate::dbus::{
|
||||
types::{Bool, ObjectPath, Signature, Variant, FALSE, TRUE},
|
||||
DbusError, DbusType, DynamicType, Parser,
|
||||
types::{Bool, FALSE, ObjectPath, Signature, TRUE, Variant},
|
||||
},
|
||||
bstr::ByteSlice,
|
||||
std::{borrow::Cow, rc::Rc},
|
||||
|
|
|
|||
|
|
@ -1,15 +1,15 @@
|
|||
use {
|
||||
crate::{
|
||||
dbus::{
|
||||
AsyncProperty, AsyncReply, AsyncReplySlot, BUS_DEST, BUS_PATH, DbusError, DbusObject,
|
||||
DbusObjectData, DbusSocket, DbusType, ErrorMessage, Formatter, HDR_DESTINATION,
|
||||
HDR_ERROR_NAME, HDR_INTERFACE, HDR_MEMBER, HDR_PATH, HDR_REPLY_SERIAL, HDR_SIGNATURE,
|
||||
HDR_UNIX_FDS, Headers, InterfaceSignalHandlers, MSG_ERROR, MSG_METHOD_CALL,
|
||||
MSG_METHOD_RETURN, MSG_SIGNAL, Message, MethodCall, NO_REPLY_EXPECTED, Parser,
|
||||
Property, Reply, ReplyHandler, Signal, SignalHandler, SignalHandlerApi,
|
||||
SignalHandlerData,
|
||||
property::Get,
|
||||
types::{ObjectPath, Signature, Variant},
|
||||
AsyncProperty, AsyncReply, AsyncReplySlot, DbusError, DbusObject, DbusObjectData,
|
||||
DbusSocket, DbusType, ErrorMessage, Formatter, Headers, InterfaceSignalHandlers,
|
||||
Message, MethodCall, Parser, Property, Reply, ReplyHandler, Signal, SignalHandler,
|
||||
SignalHandlerApi, SignalHandlerData, BUS_DEST, BUS_PATH, HDR_DESTINATION,
|
||||
HDR_ERROR_NAME, HDR_INTERFACE, HDR_MEMBER, HDR_PATH, HDR_REPLY_SERIAL, HDR_SIGNATURE,
|
||||
HDR_UNIX_FDS, MSG_ERROR, MSG_METHOD_CALL, MSG_METHOD_RETURN, MSG_SIGNAL,
|
||||
NO_REPLY_EXPECTED,
|
||||
},
|
||||
utils::{bufio::BufIoMessage, errorfmt::ErrorFmt},
|
||||
wire_dbus::org,
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ use {
|
|||
byteorder::{NativeEndian, WriteBytesExt},
|
||||
std::{io::Write, rc::Rc},
|
||||
thiserror::Error,
|
||||
uapi::{c, OwnedFd},
|
||||
uapi::{OwnedFd, c},
|
||||
};
|
||||
|
||||
linear_ids!(DrmFeedbackIds, DrmFeedbackId);
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ use {
|
|||
},
|
||||
std::rc::Rc,
|
||||
thiserror::Error,
|
||||
uapi::{c, format_ustr, Errno, OwnedFd, Ustring},
|
||||
uapi::{Errno, OwnedFd, Ustring, c, format_ustr},
|
||||
};
|
||||
|
||||
#[derive(Debug, Error)]
|
||||
|
|
|
|||
|
|
@ -4,10 +4,10 @@ use {
|
|||
async_engine::SpawnedFuture,
|
||||
client::ClientId,
|
||||
ei::{
|
||||
EiContext, EiInterfaceVersion,
|
||||
ei_client::ei_objects::EiObjects,
|
||||
ei_ifs::{ei_connection::EiConnection, ei_handshake::EiHandshake},
|
||||
ei_object::{EiInterface, EiObject, EiObjectId},
|
||||
EiContext, EiInterfaceVersion,
|
||||
},
|
||||
ifs::wl_seat::WlSeatGlobal,
|
||||
leaks::Tracker,
|
||||
|
|
@ -19,7 +19,7 @@ use {
|
|||
debug_fn::debug_fn,
|
||||
errorfmt::ErrorFmt,
|
||||
numcell::NumCell,
|
||||
pid_info::{get_pid_info, get_socket_creds, PidInfo},
|
||||
pid_info::{PidInfo, get_pid_info, get_socket_creds},
|
||||
},
|
||||
wire_ei::EiInterfaceVersions,
|
||||
},
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ use {
|
|||
crate::{
|
||||
async_engine::Phase,
|
||||
ei::{
|
||||
ei_client::{ei_error::EiClientError, EiClient},
|
||||
ei_client::{EiClient, ei_error::EiClientError},
|
||||
ei_object::EiObjectId,
|
||||
},
|
||||
utils::{
|
||||
|
|
@ -11,7 +11,7 @@ use {
|
|||
vec_ext::VecExt,
|
||||
},
|
||||
},
|
||||
futures_util::{select, FutureExt},
|
||||
futures_util::{FutureExt, select},
|
||||
std::{collections::VecDeque, mem, rc::Rc, time::Duration},
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -8,8 +8,8 @@ use {
|
|||
},
|
||||
leaks::Tracker,
|
||||
wire_ei::{
|
||||
ei_button::{ClientButton, EiButtonRequestHandler, Release, ServerButton},
|
||||
EiButtonId,
|
||||
ei_button::{ClientButton, EiButtonRequestHandler, Release, ServerButton},
|
||||
},
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -6,8 +6,8 @@ use {
|
|||
},
|
||||
leaks::Tracker,
|
||||
wire_ei::{
|
||||
ei_callback::{Done, EiCallbackRequestHandler},
|
||||
EiCallbackId,
|
||||
ei_callback::{Done, EiCallbackRequestHandler},
|
||||
},
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -1,25 +1,25 @@
|
|||
use {
|
||||
crate::{
|
||||
ei::{
|
||||
EiContext,
|
||||
ei_client::{EiClient, EiClientError},
|
||||
ei_ifs::{
|
||||
ei_callback::EiCallback,
|
||||
ei_seat::{
|
||||
EiSeat, EI_CAP_BUTTON, EI_CAP_KEYBOARD, EI_CAP_POINTER,
|
||||
EI_CAP_POINTER_ABSOLUTE, EI_CAP_SCROLL, EI_CAP_TOUCHSCREEN,
|
||||
EI_CAP_BUTTON, EI_CAP_KEYBOARD, EI_CAP_POINTER, EI_CAP_POINTER_ABSOLUTE,
|
||||
EI_CAP_SCROLL, EI_CAP_TOUCHSCREEN, EiSeat,
|
||||
},
|
||||
},
|
||||
ei_object::{EiObject, EiObjectId, EiVersion},
|
||||
EiContext,
|
||||
},
|
||||
ifs::wl_seat::WlSeatGlobal,
|
||||
leaks::Tracker,
|
||||
wire_ei::{
|
||||
EiButton, EiConnectionId, EiKeyboard, EiPointer, EiPointerAbsolute, EiScroll,
|
||||
EiTouchscreen,
|
||||
ei_connection::{
|
||||
Disconnect, Disconnected, EiConnectionRequestHandler, InvalidObject, Seat,
|
||||
},
|
||||
EiButton, EiConnectionId, EiKeyboard, EiPointer, EiPointerAbsolute, EiScroll,
|
||||
EiTouchscreen,
|
||||
},
|
||||
},
|
||||
std::{cell::Cell, rc::Rc},
|
||||
|
|
|
|||
|
|
@ -13,12 +13,12 @@ use {
|
|||
scale::Scale,
|
||||
utils::{copyhashmap::CopyHashMap, syncqueue::SyncQueue},
|
||||
wire_ei::{
|
||||
EiDeviceId,
|
||||
ei_device::{
|
||||
ClientFrame, ClientStartEmulating, ClientStopEmulating, Destroyed, DeviceType,
|
||||
Done, EiDeviceRequestHandler, Interface, Paused, Region, RegionMappingId, Release,
|
||||
Resumed, ServerFrame, ServerStartEmulating,
|
||||
},
|
||||
EiDeviceId,
|
||||
},
|
||||
},
|
||||
std::{cell::Cell, rc::Rc},
|
||||
|
|
|
|||
|
|
@ -1,19 +1,19 @@
|
|||
use {
|
||||
crate::{
|
||||
ei::{
|
||||
EiContext,
|
||||
ei_client::{EiClient, EiClientError},
|
||||
ei_ifs::ei_connection::EiConnection,
|
||||
ei_object::{EiInterface, EiObject, EiVersion, EI_HANDSHAKE_ID},
|
||||
EiContext,
|
||||
ei_object::{EI_HANDSHAKE_ID, EiInterface, EiObject, EiVersion},
|
||||
},
|
||||
leaks::Tracker,
|
||||
wire_ei::{
|
||||
EiHandshake, EiHandshakeId,
|
||||
ei_handshake::{
|
||||
ClientHandshakeVersion, ClientInterfaceVersion, Connection, ContextType,
|
||||
EiHandshakeRequestHandler, Finish, Name, ServerHandshakeVersion,
|
||||
ServerInterfaceVersion,
|
||||
},
|
||||
EiHandshake, EiHandshakeId,
|
||||
},
|
||||
},
|
||||
std::{cell::Cell, rc::Rc},
|
||||
|
|
|
|||
|
|
@ -9,10 +9,10 @@ use {
|
|||
keyboard::KeyboardState,
|
||||
leaks::Tracker,
|
||||
wire_ei::{
|
||||
EiKeyboardId,
|
||||
ei_keyboard::{
|
||||
ClientKey, EiKeyboardRequestHandler, Keymap, Modifiers, Release, ServerKey,
|
||||
},
|
||||
EiKeyboardId,
|
||||
},
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -6,8 +6,8 @@ use {
|
|||
},
|
||||
leaks::Tracker,
|
||||
wire_ei::{
|
||||
ei_pingpong::{Done, EiPingpongRequestHandler},
|
||||
EiPingpongId,
|
||||
ei_pingpong::{Done, EiPingpongRequestHandler},
|
||||
},
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -8,10 +8,10 @@ use {
|
|||
fixed::Fixed,
|
||||
leaks::Tracker,
|
||||
wire_ei::{
|
||||
EiPointerId,
|
||||
ei_pointer::{
|
||||
ClientMotionRelative, EiPointerRequestHandler, Release, ServerMotionRelative,
|
||||
},
|
||||
EiPointerId,
|
||||
},
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -8,11 +8,11 @@ use {
|
|||
fixed::Fixed,
|
||||
leaks::Tracker,
|
||||
wire_ei::{
|
||||
EiPointerAbsoluteId,
|
||||
ei_pointer_absolute::{
|
||||
ClientMotionAbsolute, EiPointerAbsoluteRequestHandler, Release,
|
||||
ServerMotionAbsolute,
|
||||
},
|
||||
EiPointerAbsoluteId,
|
||||
},
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -8,11 +8,11 @@ use {
|
|||
fixed::Fixed,
|
||||
leaks::Tracker,
|
||||
wire_ei::{
|
||||
EiScrollId,
|
||||
ei_scroll::{
|
||||
ClientScroll, ClientScrollDiscrete, ClientScrollStop, EiScrollRequestHandler,
|
||||
Release, ServerScroll, ServerScrollDiscrete, ServerScrollStop,
|
||||
},
|
||||
EiScrollId,
|
||||
},
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -2,10 +2,11 @@ use {
|
|||
crate::{
|
||||
backend::KeyState,
|
||||
ei::{
|
||||
EiContext,
|
||||
ei_client::{EiClient, EiClientError},
|
||||
ei_ifs::{
|
||||
ei_button::EiButton,
|
||||
ei_device::{EiDevice, EiDeviceInterface, EI_DEVICE_TYPE_VIRTUAL},
|
||||
ei_device::{EI_DEVICE_TYPE_VIRTUAL, EiDevice, EiDeviceInterface},
|
||||
ei_keyboard::EiKeyboard,
|
||||
ei_pointer::EiPointer,
|
||||
ei_pointer_absolute::EiPointerAbsolute,
|
||||
|
|
@ -13,19 +14,18 @@ use {
|
|||
ei_touchscreen::EiTouchscreen,
|
||||
},
|
||||
ei_object::{EiInterface, EiObject, EiVersion},
|
||||
EiContext,
|
||||
},
|
||||
fixed::Fixed,
|
||||
ifs::wl_seat::{wl_pointer::PendingScroll, PhysicalKeyboardId, WlSeatGlobal},
|
||||
ifs::wl_seat::{PhysicalKeyboardId, WlSeatGlobal, wl_pointer::PendingScroll},
|
||||
keyboard::{DynKeyboardState, KeyboardState, KeyboardStateId},
|
||||
leaks::Tracker,
|
||||
tree::Node,
|
||||
utils::{array, bitflags::BitflagsExt, clonecell::CloneCell},
|
||||
wire_ei::{
|
||||
EiSeatId,
|
||||
ei_seat::{
|
||||
Bind, Capability, Destroyed, Device, Done, EiSeatRequestHandler, Name, Release,
|
||||
},
|
||||
EiSeatId,
|
||||
},
|
||||
},
|
||||
std::{cell::Cell, rc::Rc},
|
||||
|
|
|
|||
|
|
@ -9,11 +9,11 @@ use {
|
|||
leaks::Tracker,
|
||||
utils::clonecell::UnsafeCellCloneSafe,
|
||||
wire_ei::{
|
||||
EiTouchscreenId,
|
||||
ei_touchscreen::{
|
||||
ClientCancel, ClientDown, ClientMotion, ClientUp, EiTouchscreenRequestHandler,
|
||||
Release, ServerCancel, ServerDown, ServerMotion, ServerUp,
|
||||
},
|
||||
EiTouchscreenId,
|
||||
},
|
||||
},
|
||||
std::{collections::hash_map::Entry, rc::Rc},
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
use {
|
||||
crate::{
|
||||
ei::{
|
||||
ei_client::{EiClient, EiClientError},
|
||||
EiContext,
|
||||
ei_client::{EiClient, EiClientError},
|
||||
},
|
||||
utils::buffd::EiMsgParser,
|
||||
wire_ei::EiHandshakeId,
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ use {
|
|||
state::State,
|
||||
utils::{
|
||||
buffd::BufFdError,
|
||||
clone3::{fork_with_pidfd, Forked},
|
||||
clone3::{Forked, fork_with_pidfd},
|
||||
copyhashmap::CopyHashMap,
|
||||
errorfmt::ErrorFmt,
|
||||
numcell::NumCell,
|
||||
|
|
@ -33,7 +33,7 @@ use {
|
|||
task::{Poll, Waker},
|
||||
},
|
||||
thiserror::Error,
|
||||
uapi::{c, pipe2, Errno, Fd, IntoUstr, OwnedFd, UstrPtr},
|
||||
uapi::{Errno, Fd, IntoUstr, OwnedFd, UstrPtr, c, pipe2},
|
||||
};
|
||||
|
||||
pub struct ForkerProxy {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use {
|
||||
bincode::Options,
|
||||
serde::{de::DeserializeOwned, Serialize},
|
||||
serde::{Serialize, de::DeserializeOwned},
|
||||
std::{mem, rc::Rc},
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -1,13 +1,13 @@
|
|||
use {
|
||||
crate::{
|
||||
gfx_apis::gl::sys::{GLenum, GLint, GL_BGRA_EXT, GL_RGBA, GL_RGBA8, GL_UNSIGNED_BYTE},
|
||||
gfx_apis::gl::sys::{GL_BGRA_EXT, GL_RGBA, GL_RGBA8, GL_UNSIGNED_BYTE, GLenum, GLint},
|
||||
pipewire::pw_pod::{
|
||||
SPA_VIDEO_FORMAT_BGRx, SPA_VIDEO_FORMAT_RGBx, SPA_VIDEO_FORMAT_xBGR_210LE,
|
||||
SPA_VIDEO_FORMAT_xRGB_210LE, SpaVideoFormat, SPA_VIDEO_FORMAT_ABGR_210LE,
|
||||
SPA_VIDEO_FORMAT_ARGB_210LE, SPA_VIDEO_FORMAT_BGR, SPA_VIDEO_FORMAT_BGR15,
|
||||
SPA_VIDEO_FORMAT_BGR16, SPA_VIDEO_FORMAT_BGRA, SPA_VIDEO_FORMAT_GRAY8,
|
||||
SPA_VIDEO_FORMAT_RGB, SPA_VIDEO_FORMAT_RGB16, SPA_VIDEO_FORMAT_RGBA,
|
||||
SPA_VIDEO_FORMAT_UNKNOWN,
|
||||
SPA_VIDEO_FORMAT_ABGR_210LE, SPA_VIDEO_FORMAT_ARGB_210LE, SPA_VIDEO_FORMAT_BGR,
|
||||
SPA_VIDEO_FORMAT_BGR15, SPA_VIDEO_FORMAT_BGR16, SPA_VIDEO_FORMAT_BGRA,
|
||||
SPA_VIDEO_FORMAT_BGRx, SPA_VIDEO_FORMAT_GRAY8, SPA_VIDEO_FORMAT_RGB,
|
||||
SPA_VIDEO_FORMAT_RGB16, SPA_VIDEO_FORMAT_RGBA, SPA_VIDEO_FORMAT_RGBx,
|
||||
SPA_VIDEO_FORMAT_UNKNOWN, SPA_VIDEO_FORMAT_xBGR_210LE, SPA_VIDEO_FORMAT_xRGB_210LE,
|
||||
SpaVideoFormat,
|
||||
},
|
||||
utils::debug_fn::debug_fn,
|
||||
},
|
||||
|
|
|
|||
|
|
@ -7,13 +7,13 @@ use {
|
|||
fixed::Fixed,
|
||||
format::Format,
|
||||
rect::{Rect, Region},
|
||||
renderer::{renderer_base::RendererBase, Renderer},
|
||||
renderer::{Renderer, renderer_base::RendererBase},
|
||||
scale::Scale,
|
||||
state::State,
|
||||
theme::Color,
|
||||
tree::{Node, OutputNode},
|
||||
utils::{clonecell::UnsafeCellCloneSafe, transform_ext::TransformExt},
|
||||
video::{dmabuf::DmaBuf, drm::sync_obj::SyncObjCtx, Modifier},
|
||||
video::{Modifier, dmabuf::DmaBuf, drm::sync_obj::SyncObjCtx},
|
||||
},
|
||||
ahash::AHashMap,
|
||||
indexmap::{IndexMap, IndexSet},
|
||||
|
|
|
|||
|
|
@ -80,8 +80,8 @@ use {
|
|||
texture::Texture,
|
||||
},
|
||||
sys::{
|
||||
GL_BLEND, GL_FALSE, GL_FLOAT, GL_LINEAR, GL_TEXTURE0, GL_TEXTURE_MIN_FILTER,
|
||||
GL_TRIANGLES, GL_TRIANGLE_STRIP,
|
||||
GL_BLEND, GL_FALSE, GL_FLOAT, GL_LINEAR, GL_TEXTURE_MIN_FILTER, GL_TEXTURE0,
|
||||
GL_TRIANGLE_STRIP, GL_TRIANGLES,
|
||||
},
|
||||
},
|
||||
theme::Color,
|
||||
|
|
@ -339,7 +339,9 @@ fn render_texture(ctx: &GlRenderContext, tex: &CopyTexture) {
|
|||
true => match &ctx.tex_external {
|
||||
Some(p) => p,
|
||||
_ => {
|
||||
log::error!("Trying to render an external-only texture but context does not support the required extension");
|
||||
log::error!(
|
||||
"Trying to render an external-only texture but context does not support the required extension"
|
||||
);
|
||||
return;
|
||||
}
|
||||
},
|
||||
|
|
|
|||
|
|
@ -1,14 +1,14 @@
|
|||
use {
|
||||
crate::gfx_apis::gl::{
|
||||
RenderError,
|
||||
egl::sys::{
|
||||
EGLAttrib, EGLLabelKHR, EGLenum, EGLint, EGL_DEBUG_MSG_CRITICAL_KHR,
|
||||
EGL_DEBUG_MSG_ERROR_KHR, EGL_DEBUG_MSG_INFO_KHR, EGL_DEBUG_MSG_WARN_KHR, EGL_NONE,
|
||||
EGL_OPENGL_ES_API, EGL_TRUE,
|
||||
EGL_DEBUG_MSG_CRITICAL_KHR, EGL_DEBUG_MSG_ERROR_KHR, EGL_DEBUG_MSG_INFO_KHR,
|
||||
EGL_DEBUG_MSG_WARN_KHR, EGL_NONE, EGL_OPENGL_ES_API, EGL_TRUE, EGLAttrib, EGLLabelKHR,
|
||||
EGLenum, EGLint,
|
||||
},
|
||||
ext::{get_client_ext, ClientExt, EXT_PLATFORM_BASE, KHR_DEBUG, KHR_PLATFORM_GBM},
|
||||
ext::{ClientExt, EXT_PLATFORM_BASE, KHR_DEBUG, KHR_PLATFORM_GBM, get_client_ext},
|
||||
proc::ExtProc,
|
||||
sys::EGL,
|
||||
RenderError,
|
||||
},
|
||||
bstr::ByteSlice,
|
||||
log::Level,
|
||||
|
|
|
|||
|
|
@ -2,16 +2,16 @@ use {
|
|||
crate::{
|
||||
gfx_api::{GfxFormat, ResetStatus},
|
||||
gfx_apis::gl::{
|
||||
RenderError,
|
||||
egl::{
|
||||
display::EglDisplay,
|
||||
sys::{EGLContext, EGLSurface, EGL_FALSE, EGL_TRUE},
|
||||
sys::{EGL_FALSE, EGL_TRUE, EGLContext, EGLSurface},
|
||||
},
|
||||
ext::{GlExt, EXT_CREATE_CONTEXT_ROBUSTNESS},
|
||||
ext::{EXT_CREATE_CONTEXT_ROBUSTNESS, GlExt},
|
||||
sys::{
|
||||
GL_GUILTY_CONTEXT_RESET_ARB, GL_INNOCENT_CONTEXT_RESET_ARB,
|
||||
GL_UNKNOWN_CONTEXT_RESET_ARB,
|
||||
},
|
||||
RenderError,
|
||||
},
|
||||
},
|
||||
ahash::AHashMap,
|
||||
|
|
|
|||
|
|
@ -1,13 +1,14 @@
|
|||
use {
|
||||
crate::{
|
||||
format::{formats, Format},
|
||||
format::{Format, formats},
|
||||
gfx_api::{GfxFormat, GfxWriteModifier},
|
||||
gfx_apis::gl::{
|
||||
RenderError,
|
||||
egl::{
|
||||
PROCS,
|
||||
context::EglContext,
|
||||
image::EglImage,
|
||||
sys::{
|
||||
EGLClientBuffer, EGLConfig, EGLContext, EGLDisplay, EGLint,
|
||||
EGL_CONTEXT_CLIENT_VERSION, EGL_DMA_BUF_PLANE0_FD_EXT,
|
||||
EGL_DMA_BUF_PLANE0_MODIFIER_HI_EXT, EGL_DMA_BUF_PLANE0_MODIFIER_LO_EXT,
|
||||
EGL_DMA_BUF_PLANE0_OFFSET_EXT, EGL_DMA_BUF_PLANE0_PITCH_EXT,
|
||||
|
|
@ -20,24 +21,23 @@ use {
|
|||
EGL_DMA_BUF_PLANE3_MODIFIER_LO_EXT, EGL_DMA_BUF_PLANE3_OFFSET_EXT,
|
||||
EGL_DMA_BUF_PLANE3_PITCH_EXT, EGL_HEIGHT, EGL_IMAGE_PRESERVED_KHR,
|
||||
EGL_LINUX_DMA_BUF_EXT, EGL_LINUX_DRM_FOURCC_EXT, EGL_NONE, EGL_TRUE, EGL_WIDTH,
|
||||
EGLClientBuffer, EGLConfig, EGLContext, EGLDisplay, EGLint,
|
||||
},
|
||||
PROCS,
|
||||
},
|
||||
ext::{
|
||||
get_display_ext, get_gl_ext, DisplayExt, GlExt, ANDROID_NATIVE_FENCE_SYNC,
|
||||
EXT_CREATE_CONTEXT_ROBUSTNESS, EXT_IMAGE_DMA_BUF_IMPORT_MODIFIERS,
|
||||
GL_OES_EGL_IMAGE, GL_OES_EGL_IMAGE_EXTERNAL, KHR_FENCE_SYNC, KHR_IMAGE_BASE,
|
||||
KHR_NO_CONFIG_CONTEXT, KHR_SURFACELESS_CONTEXT, KHR_WAIT_SYNC,
|
||||
MESA_CONFIGLESS_CONTEXT,
|
||||
ANDROID_NATIVE_FENCE_SYNC, DisplayExt, EXT_CREATE_CONTEXT_ROBUSTNESS,
|
||||
EXT_IMAGE_DMA_BUF_IMPORT_MODIFIERS, GL_OES_EGL_IMAGE, GL_OES_EGL_IMAGE_EXTERNAL,
|
||||
GlExt, KHR_FENCE_SYNC, KHR_IMAGE_BASE, KHR_NO_CONFIG_CONTEXT,
|
||||
KHR_SURFACELESS_CONTEXT, KHR_WAIT_SYNC, MESA_CONFIGLESS_CONTEXT, get_display_ext,
|
||||
get_gl_ext,
|
||||
},
|
||||
proc::ExtProc,
|
||||
sys::{
|
||||
Egl, GlesV2, EGL, EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY_EXT,
|
||||
EGL_LOSE_CONTEXT_ON_RESET_EXT, EGL_PLATFORM_GBM_KHR, GLESV2,
|
||||
EGL, EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY_EXT,
|
||||
EGL_LOSE_CONTEXT_ON_RESET_EXT, EGL_PLATFORM_GBM_KHR, Egl, GLESV2, GlesV2,
|
||||
},
|
||||
RenderError,
|
||||
},
|
||||
video::{dmabuf::DmaBuf, drm::Drm, gbm::GbmDevice, Modifier, INVALID_MODIFIER},
|
||||
video::{INVALID_MODIFIER, Modifier, dmabuf::DmaBuf, drm::Drm, gbm::GbmDevice},
|
||||
},
|
||||
ahash::AHashMap,
|
||||
indexmap::{IndexMap, IndexSet},
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ use {
|
|||
crate::{
|
||||
gfx_apis::gl::egl::{
|
||||
display::EglDisplay,
|
||||
sys::{EGLImageKHR, EGL_FALSE},
|
||||
sys::{EGL_FALSE, EGLImageKHR},
|
||||
},
|
||||
video::dmabuf::DmaBuf,
|
||||
},
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
use {
|
||||
crate::gfx_apis::gl::{
|
||||
egl::sys::{EGLDisplay, EGL_EXTENSIONS},
|
||||
RenderError,
|
||||
egl::sys::{EGL_EXTENSIONS, EGLDisplay},
|
||||
gl::sys::GL_EXTENSIONS,
|
||||
sys::{EGL, GLESV2},
|
||||
RenderError,
|
||||
},
|
||||
ahash::AHashSet,
|
||||
bstr::ByteSlice,
|
||||
|
|
|
|||
|
|
@ -1,11 +1,11 @@
|
|||
use {
|
||||
crate::gfx_apis::gl::{
|
||||
RenderError,
|
||||
egl::context::EglContext,
|
||||
gl::{
|
||||
shader::GlShader,
|
||||
sys::{GLint, GLuint, GL_FALSE, GL_FRAGMENT_SHADER, GL_LINK_STATUS, GL_VERTEX_SHADER},
|
||||
sys::{GL_FALSE, GL_FRAGMENT_SHADER, GL_LINK_STATUS, GL_VERTEX_SHADER, GLint, GLuint},
|
||||
},
|
||||
RenderError,
|
||||
},
|
||||
std::{ffi::CStr, rc::Rc},
|
||||
};
|
||||
|
|
|
|||
|
|
@ -2,15 +2,15 @@ use {
|
|||
crate::{
|
||||
format::Format,
|
||||
gfx_apis::gl::{
|
||||
RenderError,
|
||||
egl::{context::EglContext, image::EglImage},
|
||||
gl::{
|
||||
frame_buffer::GlFrameBuffer,
|
||||
sys::{
|
||||
GLeglImageOES, GLuint, GL_COLOR_ATTACHMENT0, GL_FRAMEBUFFER,
|
||||
GL_FRAMEBUFFER_COMPLETE, GL_RENDERBUFFER,
|
||||
GL_COLOR_ATTACHMENT0, GL_FRAMEBUFFER, GL_FRAMEBUFFER_COMPLETE, GL_RENDERBUFFER,
|
||||
GLeglImageOES, GLuint,
|
||||
},
|
||||
},
|
||||
RenderError,
|
||||
},
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
use {
|
||||
crate::gfx_apis::gl::{
|
||||
egl::context::EglContext,
|
||||
gl::sys::{GLenum, GLuint, GL_COMPILE_STATUS, GL_FALSE},
|
||||
sys::GLint,
|
||||
RenderError,
|
||||
egl::context::EglContext,
|
||||
gl::sys::{GL_COMPILE_STATUS, GL_FALSE, GLenum, GLuint},
|
||||
sys::GLint,
|
||||
},
|
||||
std::rc::Rc,
|
||||
};
|
||||
|
|
|
|||
|
|
@ -2,14 +2,14 @@ use {
|
|||
crate::{
|
||||
format::Format,
|
||||
gfx_apis::gl::{
|
||||
RenderError,
|
||||
egl::{context::EglContext, image::EglImage},
|
||||
ext::GL_OES_EGL_IMAGE_EXTERNAL,
|
||||
gl::sys::{
|
||||
GLint, GLuint, GL_CLAMP_TO_EDGE, GL_TEXTURE_2D, GL_TEXTURE_WRAP_S,
|
||||
GL_TEXTURE_WRAP_T, GL_UNPACK_ROW_LENGTH_EXT,
|
||||
GL_CLAMP_TO_EDGE, GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_TEXTURE_WRAP_T,
|
||||
GL_UNPACK_ROW_LENGTH_EXT, GLint, GLuint,
|
||||
},
|
||||
sys::{GLeglImageOES, GLenum, GL_TEXTURE_EXTERNAL_OES},
|
||||
RenderError,
|
||||
sys::{GL_TEXTURE_EXTERNAL_OES, GLeglImageOES, GLenum},
|
||||
},
|
||||
},
|
||||
std::{cell::Cell, rc::Rc},
|
||||
|
|
|
|||
|
|
@ -8,24 +8,24 @@ use {
|
|||
GfxImage, GfxInternalFramebuffer, ResetStatus, ShmGfxTexture,
|
||||
},
|
||||
gfx_apis::gl::{
|
||||
GfxGlState, RenderError, Texture,
|
||||
egl::{context::EglContext, display::EglDisplay, image::EglImage},
|
||||
ext::GL_OES_EGL_IMAGE_EXTERNAL,
|
||||
gl::{
|
||||
program::GlProgram, render_buffer::GlRenderBuffer, sys::GLint, texture::GlTexture,
|
||||
},
|
||||
renderer::{framebuffer::Framebuffer, image::Image},
|
||||
GfxGlState, RenderError, Texture,
|
||||
},
|
||||
rect::Rect,
|
||||
video::{
|
||||
dmabuf::DmaBuf,
|
||||
drm::{sync_obj::SyncObjCtx, Drm},
|
||||
drm::{Drm, sync_obj::SyncObjCtx},
|
||||
gbm::GbmDevice,
|
||||
},
|
||||
},
|
||||
ahash::AHashMap,
|
||||
jay_config::video::GfxApi,
|
||||
linearize::{static_map, Linearize, StaticMap},
|
||||
linearize::{Linearize, StaticMap, static_map},
|
||||
std::{
|
||||
cell::{Cell, RefCell},
|
||||
ffi::CString,
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ use {
|
|||
SyncFile,
|
||||
},
|
||||
gfx_apis::gl::{
|
||||
RenderError,
|
||||
gl::{
|
||||
frame_buffer::GlFrameBuffer,
|
||||
sys::{GL_COLOR_BUFFER_BIT, GL_FRAMEBUFFER},
|
||||
|
|
@ -15,7 +16,6 @@ use {
|
|||
renderer::context::GlRenderContext,
|
||||
run_ops,
|
||||
sys::{GL_ONE, GL_ONE_MINUS_SRC_ALPHA},
|
||||
RenderError,
|
||||
},
|
||||
rect::Region,
|
||||
theme::Color,
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@ use {
|
|||
crate::{
|
||||
gfx_api::{GfxError, GfxFramebuffer, GfxImage, GfxTexture},
|
||||
gfx_apis::gl::{
|
||||
egl::image::EglImage, gl::texture::GlTexture, Framebuffer, GlRenderContext,
|
||||
RenderError, Texture,
|
||||
Framebuffer, GlRenderContext, RenderError, Texture, egl::image::EglImage,
|
||||
gl::texture::GlTexture,
|
||||
},
|
||||
},
|
||||
std::rc::Rc,
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
use {
|
||||
crate::{
|
||||
gfx_apis::gl::{
|
||||
RenderError,
|
||||
egl::context::EglContext,
|
||||
sys::{
|
||||
EGLBoolean, EGLSyncKHR, EGL_NONE, EGL_SYNC_NATIVE_FENCE_ANDROID,
|
||||
EGL_SYNC_NATIVE_FENCE_FD_ANDROID, EGL_TRUE,
|
||||
EGL_NONE, EGL_SYNC_NATIVE_FENCE_ANDROID, EGL_SYNC_NATIVE_FENCE_FD_ANDROID,
|
||||
EGL_TRUE, EGLBoolean, EGLSyncKHR,
|
||||
},
|
||||
RenderError,
|
||||
},
|
||||
utils::errorfmt::ErrorFmt,
|
||||
},
|
||||
|
|
|
|||
|
|
@ -6,13 +6,13 @@ use {
|
|||
PendingShmTransfer, ShmGfxTexture, ShmMemory,
|
||||
},
|
||||
gfx_apis::gl::{
|
||||
RenderError,
|
||||
gl::texture::GlTexture,
|
||||
renderer::context::GlRenderContext,
|
||||
sys::{
|
||||
GLint, GL_CLAMP_TO_EDGE, GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_TEXTURE_WRAP_T,
|
||||
GL_UNPACK_ROW_LENGTH_EXT,
|
||||
GL_CLAMP_TO_EDGE, GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_TEXTURE_WRAP_T,
|
||||
GL_UNPACK_ROW_LENGTH_EXT, GLint,
|
||||
},
|
||||
RenderError,
|
||||
},
|
||||
rect::Region,
|
||||
video::dmabuf::DmaBuf,
|
||||
|
|
|
|||
|
|
@ -21,12 +21,12 @@ use {
|
|||
crate::{
|
||||
allocator::{Allocator, AllocatorError},
|
||||
async_engine::AsyncEngine,
|
||||
cpu_worker::{jobs::read_write::ReadWriteJobError, CpuWorker},
|
||||
cpu_worker::{CpuWorker, jobs::read_write::ReadWriteJobError},
|
||||
format::Format,
|
||||
gfx_api::{
|
||||
AsyncShmGfxTexture, GfxContext, GfxError, GfxFormat, GfxImage, GfxInternalFramebuffer,
|
||||
GfxStagingBuffer, ResetStatus, ShmGfxTexture, StagingBufferUsecase, STAGING_DOWNLOAD,
|
||||
STAGING_UPLOAD,
|
||||
GfxStagingBuffer, ResetStatus, STAGING_DOWNLOAD, STAGING_UPLOAD, ShmGfxTexture,
|
||||
StagingBufferUsecase,
|
||||
},
|
||||
gfx_apis::vulkan::{
|
||||
image::VulkanImageMemory, instance::VulkanInstance, renderer::VulkanRenderer,
|
||||
|
|
@ -36,12 +36,12 @@ use {
|
|||
utils::oserror::OsError,
|
||||
video::{
|
||||
dmabuf::DmaBuf,
|
||||
drm::{sync_obj::SyncObjCtx, Drm, DrmError},
|
||||
drm::{Drm, DrmError, sync_obj::SyncObjCtx},
|
||||
gbm::GbmError,
|
||||
},
|
||||
},
|
||||
ahash::AHashMap,
|
||||
ash::{vk, LoadingError},
|
||||
ash::{LoadingError, vk},
|
||||
gpu_alloc::{AllocationError, MapError},
|
||||
jay_config::video::GfxApi,
|
||||
log::Level,
|
||||
|
|
|
|||
|
|
@ -2,13 +2,13 @@ use {
|
|||
crate::{
|
||||
cpu_worker::{AsyncCpuWork, CpuJob, CpuWork, CpuWorker},
|
||||
gfx_apis::vulkan::{
|
||||
device::VulkanDevice, instance::API_VERSION, renderer::VulkanRenderer, VulkanError,
|
||||
VulkanError, device::VulkanDevice, instance::API_VERSION, renderer::VulkanRenderer,
|
||||
},
|
||||
utils::{numcell::NumCell, ptr_ext::MutPtrExt},
|
||||
},
|
||||
ash::{
|
||||
vk::{DeviceMemory, DeviceSize, MappedMemoryRange, MemoryRequirements},
|
||||
Device,
|
||||
vk::{DeviceMemory, DeviceSize, MappedMemoryRange, MemoryRequirements},
|
||||
},
|
||||
gpu_alloc::{Config, GpuAllocator, MemoryBlock, MemoryPropertyFlags, Request, UsageFlags},
|
||||
gpu_alloc_ash::AshMemoryDevice,
|
||||
|
|
|
|||
|
|
@ -1,20 +1,20 @@
|
|||
use {
|
||||
crate::{
|
||||
allocator::{
|
||||
Allocator, AllocatorError, BufferObject, BufferUsage, MappedBuffer, BO_USE_RENDERING,
|
||||
BO_USE_WRITE,
|
||||
Allocator, AllocatorError, BO_USE_RENDERING, BO_USE_WRITE, BufferObject, BufferUsage,
|
||||
MappedBuffer,
|
||||
},
|
||||
format::Format,
|
||||
gfx_apis::vulkan::{
|
||||
allocator::VulkanAllocator, command::VulkanCommandBuffer, device::VulkanDevice,
|
||||
format::VulkanFormat, renderer::image_barrier, staging::VulkanStagingBuffer,
|
||||
VulkanError,
|
||||
VulkanError, allocator::VulkanAllocator, command::VulkanCommandBuffer,
|
||||
device::VulkanDevice, format::VulkanFormat, renderer::image_barrier,
|
||||
staging::VulkanStagingBuffer,
|
||||
},
|
||||
utils::{errorfmt::ErrorFmt, on_drop::OnDrop},
|
||||
video::{
|
||||
Modifier,
|
||||
dmabuf::{DmaBuf, DmaBufIds, DmaBufPlane, PlaneVec},
|
||||
drm::Drm,
|
||||
Modifier,
|
||||
},
|
||||
},
|
||||
arrayvec::ArrayVec,
|
||||
|
|
@ -30,8 +30,8 @@ use {
|
|||
ImageSubresource, ImageSubresourceLayers, ImageTiling, ImageType, ImageUsageFlags,
|
||||
ImportMemoryFdInfoKHR, MemoryAllocateInfo, MemoryDedicatedAllocateInfo,
|
||||
MemoryFdPropertiesKHR, MemoryGetFdInfoKHR, MemoryPropertyFlags, MemoryRequirements2,
|
||||
PipelineStageFlags2, SampleCountFlags, SharingMode, SubmitInfo2, SubresourceLayout,
|
||||
QUEUE_FAMILY_FOREIGN_EXT,
|
||||
PipelineStageFlags2, QUEUE_FAMILY_FOREIGN_EXT, SampleCountFlags, SharingMode, SubmitInfo2,
|
||||
SubresourceLayout,
|
||||
},
|
||||
std::{rc::Rc, slice},
|
||||
uapi::OwnedFd,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use {
|
||||
crate::gfx_apis::vulkan::{device::VulkanDevice, renderer::CachedCommandBuffers, VulkanError},
|
||||
crate::gfx_apis::vulkan::{VulkanError, device::VulkanDevice, renderer::CachedCommandBuffers},
|
||||
ash::vk::{
|
||||
CommandBuffer, CommandBufferAllocateInfo, CommandBufferLevel, CommandPool,
|
||||
CommandPoolCreateFlags, CommandPoolCreateInfo,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use {
|
||||
crate::gfx_apis::vulkan::{device::VulkanDevice, sampler::VulkanSampler, VulkanError},
|
||||
crate::gfx_apis::vulkan::{VulkanError, device::VulkanDevice, sampler::VulkanSampler},
|
||||
arrayvec::ArrayVec,
|
||||
ash::vk::{
|
||||
DescriptorSetLayout, DescriptorSetLayoutBinding, DescriptorSetLayoutCreateFlags,
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue