Update to latest Smithay version

This commit is contained in:
Ian Douglas Scott 2024-06-18 19:23:16 -07:00 committed by Victoria Brekenfeld
parent c91d3fe77b
commit f2342f56c1
17 changed files with 228 additions and 123 deletions

View file

@ -473,7 +473,7 @@ impl PointerGrab<State> for MenuGrab {
&mut self,
state: &mut State,
handle: &mut PointerInnerHandle<'_, State>,
_focus: Option<(PointerFocusTarget, Point<i32, Logical>)>,
_focus: Option<(PointerFocusTarget, Point<f64, Logical>)>,
event: &MotionEvent,
) {
{
@ -520,7 +520,7 @@ impl PointerGrab<State> for MenuGrab {
&mut self,
state: &mut State,
handle: &mut PointerInnerHandle<'_, State>,
_focus: Option<(PointerFocusTarget, Point<i32, Logical>)>,
_focus: Option<(PointerFocusTarget, Point<f64, Logical>)>,
event: &RelativeMotionEvent,
) {
// While the grab is active, no client has pointer focus

View file

@ -31,14 +31,14 @@ pub enum GrabStartData {
}
impl GrabStartData {
pub fn focus(&self) -> Option<&(PointerFocusTarget, Point<i32, Logical>)> {
pub fn focus(&self) -> Option<&(PointerFocusTarget, Point<f64, Logical>)> {
match self {
Self::Touch(touch) => touch.focus.as_ref(),
Self::Pointer(pointer) => pointer.focus.as_ref(),
}
}
pub fn set_focus(&mut self, focus: Option<(PointerFocusTarget, Point<i32, Logical>)>) {
pub fn set_focus(&mut self, focus: Option<(PointerFocusTarget, Point<f64, Logical>)>) {
match self {
Self::Touch(touch) => touch.focus = focus,
Self::Pointer(pointer) => pointer.focus = focus,
@ -167,7 +167,7 @@ impl PointerGrab<State> for ResizeGrab {
&mut self,
data: &mut State,
handle: &mut PointerInnerHandle<'_, State>,
focus: Option<(PointerFocusTarget, Point<i32, Logical>)>,
focus: Option<(PointerFocusTarget, Point<f64, Logical>)>,
event: &MotionEvent,
) {
match self {
@ -180,7 +180,7 @@ impl PointerGrab<State> for ResizeGrab {
&mut self,
data: &mut State,
handle: &mut PointerInnerHandle<'_, State>,
focus: Option<(PointerFocusTarget, Point<i32, Logical>)>,
focus: Option<(PointerFocusTarget, Point<f64, Logical>)>,
event: &RelativeMotionEvent,
) {
match self {
@ -336,7 +336,7 @@ impl TouchGrab<State> for ResizeGrab {
&mut self,
data: &mut State,
handle: &mut TouchInnerHandle<'_, State>,
focus: Option<(PointerFocusTarget, Point<i32, Logical>)>,
focus: Option<(PointerFocusTarget, Point<f64, Logical>)>,
event: &DownEvent,
seq: Serial,
) {
@ -363,7 +363,7 @@ impl TouchGrab<State> for ResizeGrab {
&mut self,
data: &mut State,
handle: &mut TouchInnerHandle<'_, State>,
focus: Option<(PointerFocusTarget, Point<i32, Logical>)>,
focus: Option<(PointerFocusTarget, Point<f64, Logical>)>,
event: &TouchMotionEvent,
seq: Serial,
) {

View file

@ -445,7 +445,7 @@ impl PointerGrab<State> for MoveGrab {
&mut self,
state: &mut State,
handle: &mut PointerInnerHandle<'_, State>,
_focus: Option<(PointerFocusTarget, Point<i32, Logical>)>,
_focus: Option<(PointerFocusTarget, Point<f64, Logical>)>,
event: &MotionEvent,
) {
self.update_location(state, event.location);
@ -461,7 +461,7 @@ impl PointerGrab<State> for MoveGrab {
&mut self,
state: &mut State,
handle: &mut PointerInnerHandle<'_, State>,
_focus: Option<(PointerFocusTarget, Point<i32, Logical>)>,
_focus: Option<(PointerFocusTarget, Point<f64, Logical>)>,
event: &RelativeMotionEvent,
) {
// While the grab is active, no client has pointer focus
@ -589,7 +589,7 @@ impl TouchGrab<State> for MoveGrab {
&mut self,
data: &mut State,
handle: &mut TouchInnerHandle<'_, State>,
_focus: Option<(PointerFocusTarget, Point<i32, Logical>)>,
_focus: Option<(PointerFocusTarget, Point<f64, Logical>)>,
event: &touch::DownEvent,
seq: Serial,
) {
@ -614,7 +614,7 @@ impl TouchGrab<State> for MoveGrab {
&mut self,
data: &mut State,
handle: &mut TouchInnerHandle<'_, State>,
_focus: Option<(PointerFocusTarget, Point<i32, Logical>)>,
_focus: Option<(PointerFocusTarget, Point<f64, Logical>)>,
event: &touch::MotionEvent,
seq: Serial,
) {
@ -858,7 +858,7 @@ impl Drop for MoveGrab {
state,
Some((
target,
position.as_logical() - window.geometry().loc + offset,
position.as_logical().to_f64() - window.geometry().loc.to_f64() + offset,
)),
&MotionEvent {
location: pointer.current_location(),