Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/addons/send2ue/core/utilities.py
Original file line number Diff line number Diff line change
Expand Up @@ -1131,6 +1131,9 @@ def setup_project(*args):
if not os.environ.get('SEND2UE_HIDE_PIPELINE_MENU'):
header_menu.add_pipeline_menu()

# create the quick access button
if addon.preferences.quick_access_button:
header_menu.add_quick_access_button()

def draw_error_message(self, context):
"""
Expand Down
5 changes: 5 additions & 0 deletions src/addons/send2ue/properties.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ class Send2UeAddonProperties:
default=True,
description=f"This automatically creates the pre-defined collection (Export)"
)
quick_access_button: bpy.props.BoolProperty(
name="Enable quick access push button",
default=False,
description="Adds a Push Assets button next to the Pipeline menu"
)
# ------------- Remote Execution settings ------------------
rpc_response_timeout: bpy.props.IntProperty(
name="RPC Response Timeout",
Expand Down
2 changes: 2 additions & 0 deletions src/addons/send2ue/ui/addon_preferences.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,8 @@ def draw(self, context):
:param context: The context of this interface.
"""
row = self.layout.row()
row.prop(self, 'quick_access_button')
row = self.layout.row()
row.prop(self, 'automatically_create_collections')
row = self.layout.row()
row.label(text='RPC Response Timeout')
Expand Down
14 changes: 14 additions & 0 deletions src/addons/send2ue/ui/header_menu.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,20 @@ class TOPBAR_MT_Pipeline(bpy.types.Menu):
def draw(self, context):
pass

def quick_access(self, context):
self.layout.operator('wm.send2ue')

def add_quick_access_button():
try:
bpy.types.TOPBAR_MT_editor_menus.remove(quick_access)
finally:
bpy.types.TOPBAR_MT_editor_menus.append(quick_access)

def remove_quick_access_button():
try:
bpy.types.TOPBAR_MT_editor_menus.remove(quick_access)
finally:
pass

def pipeline_menu(self, context):
"""
Expand Down