mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-08-06 13:58:40 +00:00
adjust entity rows in watch views to use single-click for select, double-click for their primary operation, and add in operation for breakpoints/watch-pins
This commit is contained in:
@@ -2638,8 +2638,7 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
|
|||||||
UI_BoxFlag_DrawBackground|
|
UI_BoxFlag_DrawBackground|
|
||||||
UI_BoxFlag_DrawSideLeft|
|
UI_BoxFlag_DrawSideLeft|
|
||||||
UI_BoxFlag_DrawBorder|
|
UI_BoxFlag_DrawBorder|
|
||||||
UI_BoxFlag_DrawHotEffects|
|
UI_BoxFlag_DrawHotEffects,
|
||||||
UI_BoxFlag_DrawActiveEffects,
|
|
||||||
"###entity_%p_%p", entity, ctrl_entity);
|
"###entity_%p_%p", entity, ctrl_entity);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
@@ -2674,7 +2673,13 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
|
|||||||
{
|
{
|
||||||
rd_drag_begin(slot);
|
rd_drag_begin(slot);
|
||||||
}
|
}
|
||||||
if(ui_clicked(sig))
|
if(ui_pressed(sig))
|
||||||
|
{
|
||||||
|
RD_WatchViewPoint cell_pt = {1, row->block->key, row->key};
|
||||||
|
ewv->next_cursor = ewv->next_mark = cell_pt;
|
||||||
|
pressed = 1;
|
||||||
|
}
|
||||||
|
if(ui_double_clicked(sig))
|
||||||
{
|
{
|
||||||
if(entity->kind == RD_EntityKind_Target)
|
if(entity->kind == RD_EntityKind_Target)
|
||||||
{
|
{
|
||||||
@@ -2686,6 +2691,15 @@ rd_watch_view_build(RD_WatchViewState *ewv, RD_WatchViewFlags flags, String8 roo
|
|||||||
{
|
{
|
||||||
rd_cmd(RD_CmdKind_SelectThread, .thread = ctrl_entity->handle);
|
rd_cmd(RD_CmdKind_SelectThread, .thread = ctrl_entity->handle);
|
||||||
}
|
}
|
||||||
|
if(entity->kind == RD_EntityKind_Breakpoint ||
|
||||||
|
entity->kind == RD_EntityKind_WatchPin)
|
||||||
|
{
|
||||||
|
RD_Entity *loc = rd_entity_child_from_kind(entity, RD_EntityKind_Location);
|
||||||
|
rd_cmd(RD_CmdKind_FindCodeLocation,
|
||||||
|
.file_path = (loc->flags & RD_EntityFlag_HasTextPoint) ? loc->string : str8_zero(),
|
||||||
|
.cursor = loc->text_point,
|
||||||
|
.vaddr = loc->vaddr);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user