Index: trunk/src/event.c =================================================================== --- trunk/src/event.c (revision 25419) +++ trunk/src/event.c (revision 25420) @@ -40,6 +40,7 @@ "pcbev_save_post", "pcbev_load_pre", "pcbev_load_post", + "pcbeb_new_tool", "pcbev_board_changed", "pcbev_board_meta_changed", "pcbev_route_styles_changed", Index: trunk/src/event.h =================================================================== --- trunk/src/event.h (revision 25419) +++ trunk/src/event.h (revision 25420) @@ -39,6 +39,8 @@ PCB_EVENT_LOAD_PRE, /* called before loading a new design */ PCB_EVENT_LOAD_POST, /* called after loading a new design, whether it was successful or not */ + PCB_EVENT_TOOL_REG, /* called after a new tool has been registered; arg is (pcb_tool_t *) of the new tool */ + PCB_EVENT_BOARD_CHANGED, /* called after the board being edited got _replaced_ (used to be the PCBChanged action) */ PCB_EVENT_BOARD_META_CHANGED, /* called if the metadata of the board has changed */ PCB_EVENT_ROUTE_STYLES_CHANGED, /* called after any route style change (used to be the RouteStylesChanged action) */ Index: trunk/src/tool.c =================================================================== --- trunk/src/tool.c (revision 25419) +++ trunk/src/tool.c (revision 25420) @@ -79,6 +79,7 @@ vtp0_append(&pcb_tools, (void *)tool); if (pcb_gui != NULL) pcb_gui->reg_mouse_cursor(NULL, id, tool->cursor.name, tool->cursor.pixel, tool->cursor.mask); + pcb_event(&PCB->hidlib, PCB_EVENT_TOOL_REG, "p", tool); return 0; }