add menu options

This commit is contained in:
Jakub Trllo 2022-08-31 11:44:26 +02:00
parent d912431833
commit ebcd34a29b

View file

@ -22,6 +22,10 @@ from openpype.pipeline import (
AVALON_CONTAINER_ID,
)
from openpype.pipeline.workfile import BuildWorkfile
from openpype.pipeline.workfile.build_template import (
build_workfile_template,
update_workfile_template
)
from openpype.tools.utils import host_tools
from .command import viewer_update_and_undo_stop
@ -36,6 +40,9 @@ from .lib import (
set_avalon_knob_data,
read_avalon_data,
)
from .lib_template_builder import (
create_placeholder, update_placeholder
)
log = Logger.get_logger(__name__)
@ -203,6 +210,24 @@ def _install_menu():
lambda: BuildWorkfile().process()
)
menu_template = menu.addMenu("Template Builder") # creating template menu
menu_template.addCommand(
"Build Workfile from template",
lambda: build_workfile_template()
)
menu_template.addCommand(
"Update Workfile",
lambda: update_workfile_template()
)
menu_template.addSeparator()
menu_template.addCommand(
"Create Place Holder",
lambda: create_placeholder()
)
menu_template.addCommand(
"Update Place Holder",
lambda: update_placeholder()
)
menu.addSeparator()
menu.addCommand(
"Experimental tools...",