mirror of
https://github.com/zed-industries/zed.git
synced 2024-12-31 01:24:31 +03:00
Fix off by one error in click ranges
This commit is contained in:
parent
8358efbd6c
commit
269df10a16
@ -221,7 +221,8 @@ impl EditorElement {
|
||||
position_to_display_point(e.position, text_bounds, &position_map);
|
||||
if let Some(point) = point {
|
||||
for (range, callback) in click_ranges.iter() {
|
||||
if range.contains(&point) {
|
||||
// Range -> RangeInclusive
|
||||
if range.contains(&point) || range.end == point {
|
||||
callback(&e, range, &position_map.snapshot, cx)
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user