PyAPI: Use 'None' arg to clear header text

This commit is contained in:
2018-10-30 16:16:41 +11:00
parent f711c44b8d
commit f907eb4268
5 changed files with 9 additions and 7 deletions

View File

@@ -29,12 +29,12 @@ class ViewOperator(bpy.types.Operator):
context.area.header_text_set("Offset %.4f %.4f %.4f" % tuple(self.offset))
elif event.type == 'LEFTMOUSE':
context.area.header_text_set("")
context.area.header_text_set(None)
return {'FINISHED'}
elif event.type in {'RIGHTMOUSE', 'ESC'}:
rv3d.view_location = self._initial_location
context.area.header_text_set("")
context.area.header_text_set(None)
return {'CANCELLED'}
return {'RUNNING_MODAL'}