Changeset View
Changeset View
Standalone View
Standalone View
source/blender/blenkernel/BKE_screen.h
| Show First 20 Lines • Show All 136 Lines • ▼ Show 20 Lines | typedef struct ARegionType { | ||||
| int regionid; /* unique identifier within this space, defines RGN_TYPE_xxxx */ | int regionid; /* unique identifier within this space, defines RGN_TYPE_xxxx */ | ||||
| /* add handlers, stuff you only do once or on area/region type/size changes */ | /* add handlers, stuff you only do once or on area/region type/size changes */ | ||||
| void (*init)(struct wmWindowManager *wm, struct ARegion *region); | void (*init)(struct wmWindowManager *wm, struct ARegion *region); | ||||
| /* exit is called when the region is hidden or removed */ | /* exit is called when the region is hidden or removed */ | ||||
| void (*exit)(struct wmWindowManager *wm, struct ARegion *region); | void (*exit)(struct wmWindowManager *wm, struct ARegion *region); | ||||
| /* draw entirely, view changes should be handled here */ | /* draw entirely, view changes should be handled here */ | ||||
| void (*draw)(const struct bContext *C, struct ARegion *region); | void (*draw)(const struct bContext *C, struct ARegion *region); | ||||
| /* Handler to draw directly after the region is drawn to display. */ | |||||
| void (*draw_display)(const struct bContext *C, struct ARegion *region); | |||||
brecht: This could be named `draw_overlay`, for consistent terminology with `region->do_draw_overlay`… | |||||
jbakkerAuthorUnsubmitted Done Inline ActionsThe region->do_draw_overlay isn't connected with draw_overlay but with draw_paint_cursor. IMO we should rename do_draw_overlay to do_draw_paint_cursor for more consistency in a separate commit. jbakker: The `region->do_draw_overlay` isn't connected with `draw_overlay` but with `draw_paint_cursor`. | |||||
brechtUnsubmitted Not Done Inline ActionsSounds good. brecht: Sounds good. | |||||
| /* optional, compute button layout before drawing for dynamic size */ | /* optional, compute button layout before drawing for dynamic size */ | ||||
| void (*layout)(const struct bContext *C, struct ARegion *region); | void (*layout)(const struct bContext *C, struct ARegion *region); | ||||
| /* snap the size of the region (can be NULL for no snapping). */ | /* snap the size of the region (can be NULL for no snapping). */ | ||||
| int (*snap_size)(const struct ARegion *region, int size, int axis); | int (*snap_size)(const struct ARegion *region, int size, int axis); | ||||
| /* contextual changes should be handled here */ | /* contextual changes should be handled here */ | ||||
| void (*listener)(struct wmWindow *win, | void (*listener)(struct wmWindow *win, | ||||
| struct ScrArea *area, | struct ScrArea *area, | ||||
| struct ARegion *region, | struct ARegion *region, | ||||
| ▲ Show 20 Lines • Show All 280 Lines • Show Last 20 Lines | |||||
This could be named draw_overlay, for consistent terminology with region->do_draw_overlay which has the same purpose.
This term of course has a different meaning in the 3D viewport, but maybe that's ok.