mirror of
https://github.com/zed-industries/zed.git
synced 2024-12-25 01:34:02 +00:00
remove mouse position from render params
This commit is contained in:
parent
f5795ffc6f
commit
4520227e98
2 changed files with 0 additions and 9 deletions
|
@ -21,7 +21,6 @@ use std::{
|
|||
use anyhow::{anyhow, Context, Result};
|
||||
use lazy_static::lazy_static;
|
||||
use parking_lot::Mutex;
|
||||
use pathfinder_geometry::vector::Vector2F;
|
||||
use postage::oneshot;
|
||||
use smallvec::SmallVec;
|
||||
use smol::prelude::*;
|
||||
|
@ -940,7 +939,6 @@ impl MutableAppContext {
|
|||
window_id,
|
||||
view_id,
|
||||
titlebar_height,
|
||||
mouse_position: Default::default(),
|
||||
hovered_region_ids: Default::default(),
|
||||
clicked_region_ids: None,
|
||||
refreshing: false,
|
||||
|
@ -3897,7 +3895,6 @@ pub struct RenderParams {
|
|||
pub window_id: usize,
|
||||
pub view_id: usize,
|
||||
pub titlebar_height: f32,
|
||||
pub mouse_position: Vector2F,
|
||||
pub hovered_region_ids: HashSet<MouseRegionId>,
|
||||
pub clicked_region_ids: Option<(HashSet<MouseRegionId>, MouseButton)>,
|
||||
pub refreshing: bool,
|
||||
|
|
|
@ -90,7 +90,6 @@ impl Presenter {
|
|||
window_id: self.window_id,
|
||||
view_id: *view_id,
|
||||
titlebar_height: self.titlebar_height,
|
||||
mouse_position: self.mouse_position.clone(),
|
||||
hovered_region_ids: self.hovered_region_ids.clone(),
|
||||
clicked_region_ids: self
|
||||
.clicked_button
|
||||
|
@ -117,7 +116,6 @@ impl Presenter {
|
|||
window_id: self.window_id,
|
||||
view_id: *view_id,
|
||||
titlebar_height: self.titlebar_height,
|
||||
mouse_position: self.mouse_position.clone(),
|
||||
hovered_region_ids: self.hovered_region_ids.clone(),
|
||||
clicked_region_ids: self
|
||||
.clicked_button
|
||||
|
@ -233,10 +231,6 @@ impl Presenter {
|
|||
let mut mouse_events = SmallVec::<[_; 2]>::new();
|
||||
let mut notified_views: HashSet<usize> = Default::default();
|
||||
|
||||
if let Some(mouse_position) = event.position() {
|
||||
self.mouse_position = mouse_position;
|
||||
}
|
||||
|
||||
// 1. Handle platform event. Keyboard events get dispatched immediately, while mouse events
|
||||
// get mapped into the mouse-specific MouseEvent type.
|
||||
// -> These are usually small: [Mouse Down] or [Mouse up, Click] or [Mouse Moved, Mouse Dragged?]
|
||||
|
|
Loading…
Reference in a new issue