Add an animation to the LSP checking indicator (#9463)
Spinner go spinny. Extra thanks to @kvark for helping me with the shaders. https://github.com/zed-industries/zed/assets/2280405/9d5f4f4e-0d43-44d2-a089-5d69939938e9 Release Notes: - Added a spinning animation to the LSP checking indicator --------- Co-authored-by: Dzmitry Malyshau <kvark@fastmail.com>
This commit is contained in:
parent
56bd96bc64
commit
fd0071f2af
16 changed files with 708 additions and 32 deletions
|
@ -35,8 +35,8 @@ use crate::{
|
|||
GlyphId, Hsla, ImageData, InputHandler, IsZero, KeyContext, KeyEvent, LayoutId,
|
||||
LineLayoutIndex, MonochromeSprite, MouseEvent, PaintQuad, Path, Pixels, PlatformInputHandler,
|
||||
Point, PolychromeSprite, Quad, RenderGlyphParams, RenderImageParams, RenderSvgParams, Scene,
|
||||
Shadow, SharedString, Size, StrikethroughStyle, Style, TextStyleRefinement, Underline,
|
||||
UnderlineStyle, Window, WindowContext, SUBPIXEL_VARIANTS,
|
||||
Shadow, SharedString, Size, StrikethroughStyle, Style, TextStyleRefinement,
|
||||
TransformationMatrix, Underline, UnderlineStyle, Window, WindowContext, SUBPIXEL_VARIANTS,
|
||||
};
|
||||
|
||||
pub(crate) type AnyMouseListener =
|
||||
|
@ -1007,6 +1007,7 @@ impl<'a> ElementContext<'a> {
|
|||
content_mask,
|
||||
color,
|
||||
tile,
|
||||
transformation: TransformationMatrix::unit(),
|
||||
});
|
||||
}
|
||||
Ok(())
|
||||
|
@ -1072,6 +1073,7 @@ impl<'a> ElementContext<'a> {
|
|||
&mut self,
|
||||
bounds: Bounds<Pixels>,
|
||||
path: SharedString,
|
||||
transformation: TransformationMatrix,
|
||||
color: Hsla,
|
||||
) -> Result<()> {
|
||||
let scale_factor = self.scale_factor();
|
||||
|
@ -1103,6 +1105,7 @@ impl<'a> ElementContext<'a> {
|
|||
content_mask,
|
||||
color,
|
||||
tile,
|
||||
transformation,
|
||||
});
|
||||
|
||||
Ok(())
|
||||
|
@ -1266,6 +1269,11 @@ impl<'a> ElementContext<'a> {
|
|||
self.window.next_frame.dispatch_tree.set_view_id(view_id);
|
||||
}
|
||||
|
||||
/// Get the last view id for the current element
|
||||
pub fn parent_view_id(&mut self) -> Option<EntityId> {
|
||||
self.window.next_frame.dispatch_tree.parent_view_id()
|
||||
}
|
||||
|
||||
/// Sets an input handler, such as [`ElementInputHandler`][element_input_handler], which interfaces with the
|
||||
/// platform to receive textual input with proper integration with concerns such
|
||||
/// as IME interactions. This handler will be active for the upcoming frame until the following frame is
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue