cleanup
This commit is contained in:
parent
066d22bfb7
commit
a5e45c7439
1 changed files with 3 additions and 14 deletions
17
__init__.py
17
__init__.py
|
@ -315,7 +315,9 @@ class FONT3D_PT_TextPropertiesPanel(bpy.types.Panel):
|
|||
|
||||
props = self.get_active_text_properties()
|
||||
|
||||
if type(props) == type(None):
|
||||
if type(props) == type(None) or type(props.text_object) == type(None):
|
||||
# this should not happen
|
||||
print("debug: this should not happen")
|
||||
layout.label(text="AAAAH")
|
||||
return
|
||||
|
||||
|
@ -544,19 +546,6 @@ class FONT3D_OT_SaveFontToFile(bpy.types.Operator):
|
|||
was_selection.append(obj)
|
||||
was_active_object = bpy.context.view_layer.objects.active
|
||||
|
||||
# create restore function
|
||||
# def restore():
|
||||
# bpy.ops.object.select_all(action="DESELECT")
|
||||
# for obj in was_selection:
|
||||
# obj.select_set(True)
|
||||
# bpy.context.view_layer.objects.active = was_active_object
|
||||
# if not was_fontcollection_linked:
|
||||
# scene.collection.children.unlink(fontcollection)
|
||||
|
||||
# # show fontcollection
|
||||
# if not was_fontcollection_linked:
|
||||
# scene.collection.children.link(fontcollection)
|
||||
|
||||
bpy.ops.object.select_all(action="DESELECT")
|
||||
|
||||
# get save data
|
||||
|
|
Loading…
Reference in a new issue