1
0
mirror of git://projects.qi-hardware.com/eda-tools.git synced 2024-11-22 20:53:44 +02:00

eeshow/gui.c (struct gui_sheet): record ctx, to allow for simpler callbacks

This commit is contained in:
Werner Almesberger 2016-08-10 20:20:51 -03:00
parent cf2ca585f5
commit 97de1dda47

View File

@ -45,6 +45,7 @@ struct gui_ctx;
struct gui_sheet {
const struct sheet *sch;
struct gui_ctx *ctx; /* back link */
struct cro_ctx *gfx_ctx;
int w, h; /* in eeschema coordinates */
@ -939,6 +940,7 @@ static struct gui_sheet *get_sheets(struct gui_ctx *ctx,
for (sheet = sheets; sheet; sheet = sheet->next) {
new = alloc_type(struct gui_sheet);
new->sch = sheet;
new->ctx = ctx;
new->rendered = 0;
*next = new;