Extension Event Hooks

The editor will trigger certain event hooks on various operations, all editor hooks start with onEditor prefix. Ideally you will just do simple operations in your event callbacks, so not to trigger an infinite loop of events. Try not to call editor API functions in your extension event hook.

Naming conventions for the events (examples):

  • onEditorSomethingCreated - called after the thing was created
  • onEditorSomethingDelete - not deleted, because it is called before the thing is actually deleted
  • onEditorSomethingChanged - called after the thing changed
  • onEditorSomethingChange - called before the thing is about to change

Available editor hooks

  • onEditorAuthChanged(user, chosenDomain)
    Called when the authorization status changed, with user and domain info

  • onEditorObjectSelectionChanged()
    Called when object selection changed

  • onEditorInspectorHeaderGui(inspectorInfo)
    Called when the inspector draws the header part of itself. inspectorInfo contains data about the inspector instance. See Customizing Inspector

Work in progress, more will be added.

Last modified: 7/12/2021 19:55
On this page:

Any further questions?

Join our discord