fix editable expression strings, fix command evaluation, etc.

This commit is contained in:
Ryan Fleury committed 2025-04-24 09:52:29 -07:00
1 parent a35e483629
commit a6c9a1bd2a
4 files changed
+19 -31

No files matched your search

+6 -6
View File
@@ -3219,15 +3219,15 @@ rd_view_ui(Rng2F32 rect)
if(cell_info.flags & RD_WatchCellFlag_CanEdit)
{
any_edits_started = 1;
String8 string = cell->edit_string;
if(string.size == 0)
String8 string = {0};
if(cell_info.flags & RD_WatchCellFlag_NoEval)
{
string = cell->eval.string;
}
else
{
string = dr_string_from_fstrs(scratch.arena, &cell_info.eval_fstrs);
}
if(string.size == 0)
{
string = dr_string_from_fstrs(scratch.arena, &cell_info.expr_fstrs);
}
string.size = Min(string.size, sizeof(ewv->dummy_text_edit_state.input_buffer));
RD_WatchPt pt = {row->block->key, row->key, rd_id_from_watch_cell(cell)};
U64 hash = ev_hash_from_key(pt.key);