Revert "Fix T62436: New added Torus won't appear in Local View"
This reverts commit 9054b39b27
.
Using the region data to find the screen & space-data doesn't make sense
since local-view is space-data there is no reason to pass in a region
argument, then lookup the space-data.
There was no way to remove an object or check it's local view state
as there was in 2.7x.
This can be made closer to 2.7x API and simplified.
This commit is contained in:
@@ -133,11 +133,6 @@ def object_data_add(context, obdata, operator=None, name=None):
|
||||
obj_new.select_set(True)
|
||||
obj_new.matrix_world = add_object_align_init(context, operator)
|
||||
|
||||
space_data = context.space_data
|
||||
if space_data.type == 'VIEW_3D':
|
||||
if space_data.local_view:
|
||||
space_data.region_3d.local_view_add(obj_new)
|
||||
|
||||
if obj_act and obj_act.mode == 'EDIT' and obj_act.type == obj_new.type:
|
||||
bpy.ops.mesh.select_all(action='DESELECT')
|
||||
obj_act.select_set(True)
|
||||
|
Reference in New Issue
Block a user