ludic.ui: a screen's nodes and envs are pooled and used again - two generations a screen, reset in place, their own lists emptied not replaced; a tree is good until its screen is built twice more (benchmark 256 -> 110 KB a frame)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
83200a453b
commit
d1c9359e96
19 changed files with 307 additions and 83 deletions
|
|
@ -3,10 +3,10 @@
|
|||
# it where it was taken; a press on the track jumps the thumb's middle to the pointer and holds it there.
|
||||
# the bar's parts, styled as descendants of the box, and where they are at this offset
|
||||
function sb_geo(ui_st: mut UiState, n: UiNode, off: float, room: float, most: float) -> void {
|
||||
let bar = ct_part(n, "ui-scrollbar", "")
|
||||
let bar = ct_part(ui_st, n, "ui-scrollbar", "")
|
||||
bar.tag = "div"
|
||||
bar.parent = n
|
||||
push(bar.children, ct_part(n, "ui-thumb", ""))
|
||||
push(bar.children, ct_part(ui_st, n, "ui-thumb", ""))
|
||||
cs_tree(ui_st, bar)
|
||||
ui_st.sb_bar = bar
|
||||
ui_st.sb_w = ui_px(ui_st, 6.0)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue