fix cursor mismatch on fractional scaling single screen

Signed-off-by: Sahil Yeole <sahilyeole93@gmail.com>
This commit is contained in:
Sahil Yeole 2023-11-22 23:53:43 +05:30
parent 948db1451f
commit b41a73f08d

View File

@ -175,7 +175,12 @@ pub(super) async fn check_init() -> ResultType<()> {
.trim_end_matches(",") .trim_end_matches(",")
.parse() .parse()
.unwrap_or(origin.1 + height as i32); .unwrap_or(origin.1 + height as i32);
(w, h) if w < origin.0 + width as i32 || h < origin.1 + height as i32 {
(origin.0 + width as i32, origin.1 + height as i32)
}
else{
(w, h)
}
} }
_ => (origin.0 + width as i32, origin.1 + height as i32), _ => (origin.0 + width as i32, origin.1 + height as i32),
}; };