mirror of
https://github.com/zed-industries/zed.git
synced 2024-12-28 07:02:27 +03:00
💄
This commit is contained in:
parent
f50b51bdad
commit
bb721a08f5
@ -27,8 +27,9 @@ impl ActiveBufferLanguage {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fn update_language(&mut self, editor: ViewHandle<Editor>, cx: &mut ViewContext<Self>) {
|
fn update_language(&mut self, editor: ViewHandle<Editor>, cx: &mut ViewContext<Self>) {
|
||||||
let editor = editor.read(cx);
|
|
||||||
self.active_language.take();
|
self.active_language.take();
|
||||||
|
|
||||||
|
let editor = editor.read(cx);
|
||||||
if let Some((_, buffer, _)) = editor.active_excerpt(cx) {
|
if let Some((_, buffer, _)) = editor.active_excerpt(cx) {
|
||||||
if let Some(language) = buffer.read(cx).language() {
|
if let Some(language) = buffer.read(cx).language() {
|
||||||
self.active_language = Some(language.name());
|
self.active_language = Some(language.name());
|
||||||
|
Loading…
Reference in New Issue
Block a user