Skip to content

Commit b0c1a16

Browse files
committed
Merge branch 'dev/nkendallbar/logic-small-fixes' into 'main'
Misc Small Fixes for Remix Logic System See merge request lightspeedrtx/lightspeed-kit!1047
2 parents 9bf1f92 + 2b99769 commit b0c1a16

File tree

11 files changed

+56
-4
lines changed

11 files changed

+56
-4
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2424
- REMIX-4778: Added logic graph create/edit functionality to properties panels and graph editor
2525
- REMIX-4739: Add support for specific icons for the different logic node categories
2626
- REMIX-4576: Added icon support for prims tab
27+
- Small improvements for Remix Logic: added delete button, hid unused ui, stage manager refresh filtering
2728

2829
### Changed
2930
- Update hdremix and omni_core_materials to ext-822f7b6-main

source/extensions/lightspeed.trex.logic.widget/config/extension.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
title = "Remix Logic Graph Editor"
33
description = "Component editor window for Remix Component Graphs"
4-
version = "1.1.0"
4+
version = "1.1.1"
55
authors = ["Chris Grebeldinger <[email protected]>", "Dean Edmonds <[email protected]>", "Nicolas Kendall-Bar <[email protected]>"]
66
repository = "https://gitlab-master.nvidia.com/lightspeedrtx/lightspeed-kit/-/tree/main/source/extensions/lightspeed.trex.logic.widget"
77
keywords = ["graph", "logic", "component", "remix", "ui"]

source/extensions/lightspeed.trex.logic.widget/docs/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ This document records all notable changes to the **lightspeed.trex.logic.widget*
44

55
The format is based on [Keep a Changelog](https://keepachangelog.com). The project adheres to [Semantic Versioning](https://semver.org).
66

7+
## [1.1.1]
8+
### Removed
9+
- Removed Variables panel and Edit toolbar button from Logic Graph widget
10+
711
## [1.1.0]
812
### Added
913
- Added create and edit logic graph functionality with dialog support

source/extensions/lightspeed.trex.logic.widget/lightspeed/trex/logic/widget/graph_widget.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,14 @@ def is_graph_editable(self, graph: og.Graph) -> bool:
121121
# Temporary fix for 2022.1 build
122122
return True
123123

124+
def on_build_catalog(self):
125+
"""Override: Build only the catalog for the graph widget, without the variables widget or any tabs."""
126+
with ui.VStack(spacing=4):
127+
self._catalog_frame = ui.Frame()
128+
with self._catalog_frame:
129+
# Skip OmniGraphWidget's on_build_catalog to avoid building the variables widget
130+
super(OmniGraphWidget, self).on_build_catalog() # noqa: PLE1003
131+
124132
def on_build_startup(self):
125133
"""Overridden from base to customize startup panel UI"""
126134
with ui.ZStack():

source/extensions/lightspeed.trex.logic.widget/lightspeed/trex/logic/widget/graph_window.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,13 @@ def on_build_window(self):
3232
filter_fn=self._filter_fn,
3333
)
3434

35+
# Hack: Remove the Edit Graph button from the toolbar
36+
# (reasons: confusing with edit graph option, exposes omnigraph specific preference settings and
37+
# cleanup variables menu option)
38+
toolbar_items = self._main_widget._GraphEditorCoreWidget__toolbar_items # noqa: protected-access
39+
toolbar_items = [i for i in toolbar_items if i["name"] != "Edit"]
40+
self._main_widget.set_toolbar_items(toolbar_items)
41+
3542
def get_graph_widget(self) -> RemixLogicGraphWidget:
3643
"""Get the graph widget"""
3744
return self._main_widget

source/extensions/lightspeed.trex.properties_pane.logic.widget/config/extension.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[package]
2-
version = "1.1.0"
2+
version = "1.2.0"
33
authors = ["Nicolas Kendall-Bar <[email protected]>"]
44
title = "Remix Logic Properties Widget"
55
description = "Properties panel for RemixLogic prim types"

source/extensions/lightspeed.trex.properties_pane.logic.widget/docs/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
# Changelog
22
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
33

4+
## [1.2.0]
5+
### Added
6+
- Added Delete button for logic graphs in properties panel
7+
48
## [1.1.0]
59
### Added
610
- Added create and edit logic graph buttons to properties panel

source/extensions/lightspeed.trex.properties_pane.logic.widget/lightspeed/trex/properties_pane/logic/widget/setup_ui.py

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
import omni.graph.core as og
2525
import omni.graph.tools.ogn as ogn
2626
import omni.kit
27+
import omni.kit.commands
2728
import omni.ui as ui
2829
import omni.usd
2930
from lightspeed.common.constants import OMNI_GRAPH_NODE_TYPE, GlobalEventNames
@@ -161,7 +162,7 @@ def _build_root_frame(self) -> None:
161162
for graph in existing_graphs:
162163
with ui.HStack(height=ui.Pixel(24), spacing=0):
163164
relative_path = self._get_relative_path(graph.GetPath(), self._valid_target_paths)
164-
ui.Label(f"Existing Graph: {relative_path}", elided_text=True, name="PropertiesWidgetLabel")
165+
ui.Label(f"{relative_path}", elided_text=True, name="PropertiesWidgetLabel")
165166
ui.Spacer(width=0)
166167
ui.Button(
167168
"Edit",
@@ -170,6 +171,14 @@ def _build_root_frame(self) -> None:
170171
enabled=True,
171172
width=ui.Pixel(80),
172173
)
174+
ui.Spacer(width=0)
175+
ui.Button(
176+
"Delete",
177+
clicked_fn=partial(self._delete_logic_graph, graph),
178+
tooltip=f"Delete the logic graph: {graph.GetPath()}",
179+
enabled=True,
180+
width=ui.Pixel(80),
181+
)
173182

174183
if self._paths and self._show_node_properties:
175184
# A logic node is selected, so show node info and the property widget
@@ -444,6 +453,13 @@ def _edit_logic_graph(self, graph: Usd.Prim) -> None:
444453
"""Edit the given logic graph."""
445454
self._event_manager.call_global_custom_event(GlobalEventNames.LOGIC_GRAPH_EDIT_REQUEST.value, graph)
446455

456+
def _delete_logic_graph(self, graph: Usd.Prim) -> None:
457+
"""Delete the given logic graph."""
458+
omni.kit.commands.execute("DeletePrimsCommand", paths=[str(graph.GetPath())])
459+
# Rebuild the UI to reflect the changes in the existing logic graphs
460+
if self._root_frame:
461+
self._root_frame.rebuild()
462+
447463
@property
448464
def property_model(self):
449465
return self._property_model

source/extensions/omni.flux.stage_manager.plugin.interaction.usd/config/extension.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
# Semantic Versionning is used: https://semver.org/
3-
version = "2.4.0"
3+
version = "2.5.0"
44

55
# Lists people or organizations that are considered the "authors" of the package.
66
authors = ["Pierre-Olivier Trottier <[email protected]>"]

source/extensions/omni.flux.stage_manager.plugin.interaction.usd/docs/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
# Changelog
22
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
33

4+
## [2.5.0]
5+
### Added
6+
- Added `ignore_property_prefix_events` to filter stage manager refresh for "ui:" prefixed properties by default
7+
48
## [2.4.0]
59
### Added
610
- Added `DeleteRestoreActionWidgetPlugin`

0 commit comments

Comments
 (0)