Add tooltip to language selector

This commit is contained in:
Joseph T. Lyons 2023-09-08 12:41:32 -04:00
parent 87472a9de6
commit f4a9d3f269

View file

@ -52,6 +52,7 @@ impl View for ActiveBufferLanguage {
} else {
"Unknown".to_string()
};
let theme = theme::current(cx).clone();
MouseEventHandler::new::<Self, _>(0, cx, |state, cx| {
let theme = &theme::current(cx).workspace.status_bar;
@ -68,6 +69,7 @@ impl View for ActiveBufferLanguage {
});
}
})
.with_tooltip::<Self>(0, "Select Language", None, theme.tooltip.clone(), cx)
.into_any()
} else {
Empty::new().into_any()