Restructure inlay highlights data for proper access

This commit is contained in:
Kirill Bulatov 2023-09-14 23:05:22 +03:00
parent 9b43acfc88
commit 8ae3f79235
4 changed files with 35 additions and 36 deletions

View file

@ -8020,12 +8020,12 @@ impl Editor {
pub fn highlight_inlays<T: 'static>(
&mut self,
ranges: Vec<InlayHighlight>,
highlights: Vec<InlayHighlight>,
style: HighlightStyle,
cx: &mut ViewContext<Self>,
) {
self.display_map.update(cx, |map, _| {
map.highlight_inlays(TypeId::of::<T>(), ranges, style)
map.highlight_inlays(TypeId::of::<T>(), highlights, style)
});
cx.notify();
}