Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Eisel <julian@blender.org>2020-03-06 18:56:42 +0300
committerJulian Eisel <julian@blender.org>2020-03-06 19:19:23 +0300
commitb2ee1770d4c31078518f4ec9edd5196a41345162 (patch)
tree6b7f6ff9057322245fc3b3407bece3f1c0cb3eb5 /source/blender/editors/space_outliner/outliner_tree.c
parentb825a95ec311a169d33fe21e28418f11a516c82f (diff)
Cleanup: Rename ARegion variables from ar to region
The old convention was easy to confuse with ScrArea. Part of https://developer.blender.org/T74432. This is mostly a batch rename with some manual fixing. Only single word variable names are changed, no prefixed/suffixed names. Brecht van Lommel and Campbell Barton both gave me a green light for this convention change. Also ran clan clang format on affected files.
Diffstat (limited to 'source/blender/editors/space_outliner/outliner_tree.c')
-rw-r--r--source/blender/editors/space_outliner/outliner_tree.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/source/blender/editors/space_outliner/outliner_tree.c b/source/blender/editors/space_outliner/outliner_tree.c
index 4f896424f08..b8cbb6bb0e3 100644
--- a/source/blender/editors/space_outliner/outliner_tree.c
+++ b/source/blender/editors/space_outliner/outliner_tree.c
@@ -1842,13 +1842,13 @@ typedef struct OutlinerTreeElementFocus {
* Caller is expected to handle redrawing of ARegion.
*/
static void outliner_restore_scrolling_position(SpaceOutliner *soops,
- ARegion *ar,
+ ARegion *region,
OutlinerTreeElementFocus *focus)
{
- View2D *v2d = &ar->v2d;
+ View2D *v2d = &region->v2d;
if (focus->tselem != NULL) {
- outliner_set_coordinates(ar, soops);
+ outliner_set_coordinates(region, soops);
TreeElement *te_new = outliner_find_tree_element(&soops->tree, focus->tselem);
@@ -1970,15 +1970,15 @@ static TreeElement *outliner_find_first_desired_element_at_y(const SpaceOutliner
* original position as before filtering.
*/
static void outliner_store_scrolling_position(SpaceOutliner *soops,
- ARegion *ar,
+ ARegion *region,
OutlinerTreeElementFocus *focus)
{
TreeElement *te;
- float limit = ar->v2d.cur.ymin;
+ float limit = region->v2d.cur.ymin;
- outliner_set_coordinates(ar, soops);
+ outliner_set_coordinates(region, soops);
- te = outliner_find_first_desired_element_at_y(soops, ar->v2d.cur.ymax, limit);
+ te = outliner_find_first_desired_element_at_y(soops, region->v2d.cur.ymax, limit);
if (te != NULL) {
focus->tselem = TREESTORE(te);
@@ -2264,7 +2264,7 @@ static void outliner_filter_tree(SpaceOutliner *soops, ViewLayer *view_layer)
/* Main entry point for building the tree data-structure that the outliner represents */
// TODO: split each mode into its own function?
void outliner_build_tree(
- Main *mainvar, Scene *scene, ViewLayer *view_layer, SpaceOutliner *soops, ARegion *ar)
+ Main *mainvar, Scene *scene, ViewLayer *view_layer, SpaceOutliner *soops, ARegion *region)
{
TreeElement *te = NULL, *ten;
TreeStoreElem *tselem;
@@ -2286,12 +2286,12 @@ void outliner_build_tree(
BKE_outliner_treehash_rebuild_from_treestore(soops->treehash, soops->treestore);
}
- if (ar->do_draw & RGN_DRAW_NO_REBUILD) {
+ if (region->do_draw & RGN_DRAW_NO_REBUILD) {
return;
}
OutlinerTreeElementFocus focus;
- outliner_store_scrolling_position(soops, ar, &focus);
+ outliner_store_scrolling_position(soops, region, &focus);
outliner_free_tree(&soops->tree);
outliner_storage_cleanup(soops);
@@ -2445,7 +2445,7 @@ void outliner_build_tree(
}
outliner_filter_tree(soops, view_layer);
- outliner_restore_scrolling_position(soops, ar, &focus);
+ outliner_restore_scrolling_position(soops, region, &focus);
BKE_main_id_clear_newpoins(mainvar);
}