MCPcopy Create free account
hub / github.com/Kethku/Pando / draw

Method draw

aspen/src/components/window_buttons.rs:141–156  ·  view source on GitHub ↗
(&self, cx: &mut DrawContext)

Source from the content-addressed store, hash-verified

139 }
140
141 fn draw(&self, cx: &mut DrawContext) {
142 cx.set_fill_brush(Brush::Solid(self.title_background));
143
144 let region = cx.region();
145 cx.fill(&region);
146
147 cx.mouse_region(region).on_down({
148 move |cx| {
149 cx.drag_window();
150 }
151 });
152
153 self.close.draw(cx);
154 self.maximize.draw(cx);
155 self.minimize.draw(cx);
156 }
157
158 fn children(&self) -> Vec<Token> {
159 vec![

Callers

nothing calls this directly

Calls 6

set_fill_brushMethod · 0.80
regionMethod · 0.80
fillMethod · 0.80
on_downMethod · 0.80
mouse_regionMethod · 0.80
drag_windowMethod · 0.80

Tested by

no test coverage detected