parent
e3b593efbd
commit
c4083b9b63
28 changed files with 103 additions and 104 deletions
|
@ -655,11 +655,11 @@ pub fn show_link_definition(
|
|||
pub(crate) fn find_url(
|
||||
buffer: &Entity<language::Buffer>,
|
||||
position: text::Anchor,
|
||||
mut cx: AsyncWindowContext,
|
||||
cx: AsyncWindowContext,
|
||||
) -> Option<(Range<text::Anchor>, String)> {
|
||||
const LIMIT: usize = 2048;
|
||||
|
||||
let Ok(snapshot) = buffer.read_with(&mut cx, |buffer, _| buffer.snapshot()) else {
|
||||
let Ok(snapshot) = buffer.read_with(&cx, |buffer, _| buffer.snapshot()) else {
|
||||
return None;
|
||||
};
|
||||
|
||||
|
@ -717,11 +717,11 @@ pub(crate) fn find_url(
|
|||
pub(crate) fn find_url_from_range(
|
||||
buffer: &Entity<language::Buffer>,
|
||||
range: Range<text::Anchor>,
|
||||
mut cx: AsyncWindowContext,
|
||||
cx: AsyncWindowContext,
|
||||
) -> Option<String> {
|
||||
const LIMIT: usize = 2048;
|
||||
|
||||
let Ok(snapshot) = buffer.read_with(&mut cx, |buffer, _| buffer.snapshot()) else {
|
||||
let Ok(snapshot) = buffer.read_with(&cx, |buffer, _| buffer.snapshot()) else {
|
||||
return None;
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue