mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-26 13:52:15 +01:00
BigRoy's comments
This commit is contained in:
parent
792e92ca44
commit
ed7b321f64
2 changed files with 14 additions and 11 deletions
|
|
@ -776,6 +776,16 @@ def publisher_show_and_publish(comment=""):
|
|||
def self_publish():
|
||||
"""Self publish from ROP nodes."""
|
||||
|
||||
result, comment = hou.ui.readInput(
|
||||
"Add Publish Comment",
|
||||
buttons=("Publish", "Cancel"),
|
||||
title="Publish comment",
|
||||
close_choice=1
|
||||
)
|
||||
|
||||
if result:
|
||||
return
|
||||
|
||||
current_node = hou.node(".").path()
|
||||
|
||||
host = registered_host()
|
||||
|
|
@ -792,18 +802,11 @@ def self_publish():
|
|||
|
||||
context.save_changes()
|
||||
|
||||
result, comment = hou.ui.readInput(
|
||||
"Add Publish Note",
|
||||
buttons=("Ok", "Cancel"),
|
||||
title="Publish Note",
|
||||
close_choice=1
|
||||
)
|
||||
|
||||
publisher_show_and_publish(comment)
|
||||
|
||||
|
||||
def add_self_publish_button(node):
|
||||
"""Adds a self publish button in the rop node."""
|
||||
"""Adds a self publish button to the rop node."""
|
||||
|
||||
label = os.environ.get("AVALON_LABEL") or "OpenPype"
|
||||
|
||||
|
|
|
|||
|
|
@ -168,7 +168,7 @@ class HoudiniCreator(NewCreator, HoudiniCreatorBase):
|
|||
"""Base class for most of the Houdini creator plugins."""
|
||||
selected_nodes = []
|
||||
settings_name = None
|
||||
_add_self_publish_button = False
|
||||
add_publish_button = False
|
||||
|
||||
def create(self, subset_name, instance_data, pre_create_data):
|
||||
try:
|
||||
|
|
@ -196,7 +196,7 @@ class HoudiniCreator(NewCreator, HoudiniCreatorBase):
|
|||
self._add_instance_to_context(instance)
|
||||
imprint(instance_node, instance.data_to_store())
|
||||
|
||||
if self._add_self_publish_button:
|
||||
if self.add_publish_button:
|
||||
add_self_publish_button(instance_node)
|
||||
|
||||
return instance
|
||||
|
|
@ -305,7 +305,7 @@ class HoudiniCreator(NewCreator, HoudiniCreatorBase):
|
|||
"""Method called on initialization of plugin to apply settings."""
|
||||
|
||||
# Apply General Settings
|
||||
self._add_self_publish_button = \
|
||||
self.add_publish_button = \
|
||||
project_settings["houdini"]["general"]["add_self_publish_button"]
|
||||
|
||||
# Apply Creator Settings
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue