diff options
author | Julian Eisel <eiseljulian@gmail.com> | 2015-11-28 19:14:45 +0300 |
---|---|---|
committer | Julian Eisel <eiseljulian@gmail.com> | 2015-11-28 19:22:44 +0300 |
commit | 175110ec8753a94bc265beb47ff3767e65a82ecc (patch) | |
tree | 5995385d14a7ce7d43797c510c4f270ed55c393a /source/blender/editors/space_sequencer | |
parent | 51f996836c1bd6484905b224c46f497c7faf66a2 (diff) |
Cleanup: 'area' vs 'region'
Apparently this is the result of some sloppiness during 2.5 project and since then it confused people who were trying to understand the area-region relation (myself included).
Sorry if this causes merge conflicts for anyone, but at some point we really had to do it :/
Diffstat (limited to 'source/blender/editors/space_sequencer')
-rw-r--r-- | source/blender/editors/space_sequencer/space_sequencer.c | 56 |
1 files changed, 28 insertions, 28 deletions
diff --git a/source/blender/editors/space_sequencer/space_sequencer.c b/source/blender/editors/space_sequencer/space_sequencer.c index 5b3061bd513..fce40f8ca59 100644 --- a/source/blender/editors/space_sequencer/space_sequencer.c +++ b/source/blender/editors/space_sequencer/space_sequencer.c @@ -136,9 +136,9 @@ static SpaceLink *sequencer_new(const bContext *C) ar->alignment = RGN_ALIGN_RIGHT; ar->flag = RGN_FLAG_HIDDEN; - /* preview area */ + /* preview region */ /* NOTE: if you change values here, also change them in sequencer_init_preview_region */ - ar = MEM_callocN(sizeof(ARegion), "preview area for sequencer"); + ar = MEM_callocN(sizeof(ARegion), "preview region for sequencer"); BLI_addtail(&sseq->regionbase, ar); ar->regiontype = RGN_TYPE_PREVIEW; ar->alignment = RGN_ALIGN_TOP; @@ -160,8 +160,8 @@ static SpaceLink *sequencer_new(const bContext *C) ar->v2d.keeptot = V2D_KEEPTOT_FREE; - /* main area */ - ar = MEM_callocN(sizeof(ARegion), "main area for sequencer"); + /* main region */ + ar = MEM_callocN(sizeof(ARegion), "main region for sequencer"); BLI_addtail(&sseq->regionbase, ar); ar->regiontype = RGN_TYPE_WINDOW; @@ -283,7 +283,7 @@ static void sequencer_refresh(const bContext *C, ScrArea *sa) /* Get available height (without DPI correction). */ const float height = (sa->winy - ED_area_headersize()) / UI_DPI_FAC; - /* We reuse hidden area's size, allows to find same layout as before if we just switch + /* We reuse hidden region's size, allows to find same layout as before if we just switch * between one 'full window' view and the combined one. This gets lost if we switch to both * 'full window' views before, though... Better than nothing. */ if (ar_main->flag & RGN_FLAG_HIDDEN) { @@ -457,7 +457,7 @@ static int sequencer_context(const bContext *C, const char *member, bContextData /* *********************** sequencer (main) region ************************ */ /* add handlers, stuff you only do once or on area/region changes */ -static void sequencer_main_area_init(wmWindowManager *wm, ARegion *ar) +static void sequencer_main_region_init(wmWindowManager *wm, ARegion *ar) { wmKeyMap *keymap; ListBase *lb; @@ -482,13 +482,13 @@ static void sequencer_main_area_init(wmWindowManager *wm, ARegion *ar) WM_event_add_dropbox_handler(&ar->handlers, lb); } -static void sequencer_main_area_draw(const bContext *C, ARegion *ar) +static void sequencer_main_region_draw(const bContext *C, ARegion *ar) { /* NLE - strip editing timeline interface */ draw_timeline_seq(C, ar); } -static void sequencer_main_area_listener(bScreen *UNUSED(sc), ScrArea *UNUSED(sa), ARegion *ar, wmNotifier *wmn) +static void sequencer_main_region_listener(bScreen *UNUSED(sc), ScrArea *UNUSED(sa), ARegion *ar, wmNotifier *wmn) { /* context changes */ switch (wmn->category) { @@ -528,18 +528,18 @@ static void sequencer_main_area_listener(bScreen *UNUSED(sc), ScrArea *UNUSED(sa /* *********************** header region ************************ */ /* add handlers, stuff you only do once or on area/region changes */ -static void sequencer_header_area_init(wmWindowManager *UNUSED(wm), ARegion *ar) +static void sequencer_header_region_init(wmWindowManager *UNUSED(wm), ARegion *ar) { ED_region_header_init(ar); } -static void sequencer_header_area_draw(const bContext *C, ARegion *ar) +static void sequencer_header_region_draw(const bContext *C, ARegion *ar) { ED_region_header(C, ar); } /* *********************** preview region ************************ */ -static void sequencer_preview_area_init(wmWindowManager *wm, ARegion *ar) +static void sequencer_preview_region_init(wmWindowManager *wm, ARegion *ar) { wmKeyMap *keymap; @@ -558,7 +558,7 @@ static void sequencer_preview_area_init(wmWindowManager *wm, ARegion *ar) WM_event_add_keymap_handler_bb(&ar->handlers, keymap, &ar->v2d.mask, &ar->winrct); } -static void sequencer_preview_area_draw(const bContext *C, ARegion *ar) +static void sequencer_preview_region_draw(const bContext *C, ARegion *ar) { ScrArea *sa = CTX_wm_area(C); SpaceSeq *sseq = sa->spacedata.first; @@ -594,7 +594,7 @@ static void sequencer_preview_area_draw(const bContext *C, ARegion *ar) } } -static void sequencer_preview_area_listener(bScreen *UNUSED(sc), ScrArea *UNUSED(sa), ARegion *ar, wmNotifier *wmn) +static void sequencer_preview_region_listener(bScreen *UNUSED(sc), ScrArea *UNUSED(sa), ARegion *ar, wmNotifier *wmn) { /* context changes */ switch (wmn->category) { @@ -645,7 +645,7 @@ static void sequencer_preview_area_listener(bScreen *UNUSED(sc), ScrArea *UNUSED /* *********************** buttons region ************************ */ /* add handlers, stuff you only do once or on area/region changes */ -static void sequencer_buttons_area_init(wmWindowManager *wm, ARegion *ar) +static void sequencer_buttons_region_init(wmWindowManager *wm, ARegion *ar) { wmKeyMap *keymap; @@ -655,12 +655,12 @@ static void sequencer_buttons_area_init(wmWindowManager *wm, ARegion *ar) ED_region_panels_init(wm, ar); } -static void sequencer_buttons_area_draw(const bContext *C, ARegion *ar) +static void sequencer_buttons_region_draw(const bContext *C, ARegion *ar) { ED_region_panels(C, ar, NULL, -1, true); } -static void sequencer_buttons_area_listener(bScreen *UNUSED(sc), ScrArea *UNUSED(sa), ARegion *ar, wmNotifier *wmn) +static void sequencer_buttons_region_listener(bScreen *UNUSED(sc), ScrArea *UNUSED(sa), ARegion *ar, wmNotifier *wmn) { /* context changes */ switch (wmn->category) { @@ -712,9 +712,9 @@ void ED_spacetype_sequencer(void) /* regions: main window */ art = MEM_callocN(sizeof(ARegionType), "spacetype sequencer region"); art->regionid = RGN_TYPE_WINDOW; - art->init = sequencer_main_area_init; - art->draw = sequencer_main_area_draw; - art->listener = sequencer_main_area_listener; + art->init = sequencer_main_region_init; + art->draw = sequencer_main_region_draw; + art->listener = sequencer_main_region_listener; art->keymapflag = ED_KEYMAP_VIEW2D | ED_KEYMAP_MARKERS | ED_KEYMAP_FRAMES | ED_KEYMAP_ANIMATION; BLI_addhead(&st->regiontypes, art); @@ -722,9 +722,9 @@ void ED_spacetype_sequencer(void) /* preview */ art = MEM_callocN(sizeof(ARegionType), "spacetype sequencer region"); art->regionid = RGN_TYPE_PREVIEW; - art->init = sequencer_preview_area_init; - art->draw = sequencer_preview_area_draw; - art->listener = sequencer_preview_area_listener; + art->init = sequencer_preview_region_init; + art->draw = sequencer_preview_region_draw; + art->listener = sequencer_preview_region_listener; art->keymapflag = ED_KEYMAP_VIEW2D | ED_KEYMAP_FRAMES | ED_KEYMAP_GPENCIL; BLI_addhead(&st->regiontypes, art); @@ -733,9 +733,9 @@ void ED_spacetype_sequencer(void) art->regionid = RGN_TYPE_UI; art->prefsizex = 220; // XXX art->keymapflag = ED_KEYMAP_UI | ED_KEYMAP_FRAMES; - art->listener = sequencer_buttons_area_listener; - art->init = sequencer_buttons_area_init; - art->draw = sequencer_buttons_area_draw; + art->listener = sequencer_buttons_region_listener; + art->init = sequencer_buttons_region_init; + art->draw = sequencer_buttons_region_draw; BLI_addhead(&st->regiontypes, art); sequencer_buttons_register(art); @@ -746,9 +746,9 @@ void ED_spacetype_sequencer(void) art->prefsizey = HEADERY; art->keymapflag = ED_KEYMAP_UI | ED_KEYMAP_VIEW2D | ED_KEYMAP_FRAMES | ED_KEYMAP_HEADER; - art->init = sequencer_header_area_init; - art->draw = sequencer_header_area_draw; - art->listener = sequencer_main_area_listener; + art->init = sequencer_header_region_init; + art->draw = sequencer_header_region_draw; + art->listener = sequencer_main_region_listener; BLI_addhead(&st->regiontypes, art); |