diff options
author | Monique Dewanchand <mdewanchand> | 2022-09-01 11:00:53 +0300 |
---|---|---|
committer | Monique <mdewanchand@atmind.nl> | 2022-09-01 11:22:43 +0300 |
commit | 17501c146edc4af8a5e04565dc4d0b30ed5c5323 (patch) | |
tree | 73fe3334ff45b67d45fa1b5a5ae7ff06ec990a5a /source/blender/editors/mesh | |
parent | f9c249917dbf9c450abf52df1f60b3d587bc106a (diff) |
Cleanup: Remove/replace View Layer macros.
This patch is a cleanup required before refactoring the view layer syncing
process {T73411}.
* Remove FIRSTBASE.
* Remove LASTBASE.
* Remove BASACT.
* Remove OBEDIT_FROM_WORKSPACE.
* Replace OBACT with BKE_view_layer_active_object.
* Replace OBEDIT_FROM_VIEW_LAYER with BKE_view_layer_edit_object.
Reviewed By: mont29
Maniphest Tasks: T73411
Differential Revision: https://developer.blender.org/D15799
Diffstat (limited to 'source/blender/editors/mesh')
-rw-r--r-- | source/blender/editors/mesh/editmesh_path.c | 2 | ||||
-rw-r--r-- | source/blender/editors/mesh/editmesh_undo.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/mesh/editmesh_path.c b/source/blender/editors/mesh/editmesh_path.c index f2e7150e791..6f2f43b844e 100644 --- a/source/blender/editors/mesh/editmesh_path.c +++ b/source/blender/editors/mesh/editmesh_path.c @@ -679,7 +679,7 @@ static int edbm_shortest_path_pick_invoke(bContext *C, wmOperator *op, const wmE em_setup_viewcontext(C, &vc); copy_v2_v2_int(vc.mval, event->mval); - Base *basact = BASACT(vc.view_layer); + Base *basact = vc.view_layer->basact; BMEditMesh *em = vc.em; view3d_operator_needs_opengl(C); diff --git a/source/blender/editors/mesh/editmesh_undo.c b/source/blender/editors/mesh/editmesh_undo.c index af8084e16c4..15e28381cb6 100644 --- a/source/blender/editors/mesh/editmesh_undo.c +++ b/source/blender/editors/mesh/editmesh_undo.c @@ -736,7 +736,7 @@ static void undomesh_free_data(UndoMesh *um) static Object *editmesh_object_from_context(bContext *C) { ViewLayer *view_layer = CTX_data_view_layer(C); - Object *obedit = OBEDIT_FROM_VIEW_LAYER(view_layer); + Object *obedit = BKE_view_layer_edit_object_get(view_layer); if (obedit && obedit->type == OB_MESH) { Mesh *me = obedit->data; if (me->edit_mesh != NULL) { |