Update SCTK to 0.18.0
The update is pretty minor, however we support now `WindowEvent::Occluded` when xdg-shell v6 is available. It also adds support for `Window::show_window_menu`. Fixes #2927.
This commit is contained in:
parent
844269d017
commit
b7e3649e8b
15 changed files with 224 additions and 165 deletions
|
|
@ -32,7 +32,7 @@ use std::{
|
|||
ops::Deref,
|
||||
os::{
|
||||
raw::*,
|
||||
unix::io::{AsRawFd, RawFd},
|
||||
unix::io::{AsRawFd, BorrowedFd},
|
||||
},
|
||||
ptr,
|
||||
rc::Rc,
|
||||
|
|
@ -82,7 +82,7 @@ use crate::{
|
|||
const ALL_DEVICES: u16 = 0;
|
||||
const ALL_MASTER_DEVICES: u16 = 1;
|
||||
|
||||
type X11Source = Generic<RawFd>;
|
||||
type X11Source = Generic<BorrowedFd<'static>>;
|
||||
|
||||
struct WakeSender<T> {
|
||||
sender: Sender<T>,
|
||||
|
|
@ -268,7 +268,8 @@ impl<T: 'static> EventLoop<T> {
|
|||
|
||||
// Create the X11 event dispatcher.
|
||||
let source = X11Source::new(
|
||||
xconn.xcb_connection().as_raw_fd(),
|
||||
// SAFETY: xcb owns the FD and outlives the source.
|
||||
unsafe { BorrowedFd::borrow_raw(xconn.xcb_connection().as_raw_fd()) },
|
||||
calloop::Interest::READ,
|
||||
calloop::Mode::Level,
|
||||
);
|
||||
|
|
|
|||
|
|
@ -1636,6 +1636,9 @@ impl UnownedWindow {
|
|||
self.drag_initiate(util::MOVERESIZE_MOVE)
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn show_window_menu(&self, _position: Position) {}
|
||||
|
||||
/// Resizes the window while it is being dragged.
|
||||
pub fn drag_resize_window(&self, direction: ResizeDirection) -> Result<(), ExternalError> {
|
||||
self.drag_initiate(match direction {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue