Skip to content

Commit 3207b22

Browse files
arttu-peltonenEvergreen
authored andcommitted
Render Graph Viewer UI fixes
1 parent b911cd2 commit 3207b22

File tree

4 files changed

+17
-16
lines changed

4 files changed

+17
-16
lines changed

Packages/com.unity.render-pipelines.core/Editor/RenderGraph/RenderGraphViewer.SidePanel.cs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -68,11 +68,7 @@ void InitializeSidePanel()
6868
rootVisualElement.RegisterCallback<GeometryChangedEvent>(_ =>
6969
{
7070
SaveSplitViewFixedPaneHeight(); // Window resized - save the current pane height
71-
72-
// TwoPaneSplitView also updates draglineanchor offset using the same event, conflicting with what we
73-
// do here. Deferring our panel height update to next frame solves a bug with dragline "jumping" when
74-
// window is resized down vertically and the lower panel is already at minimum height.
75-
rootVisualElement.schedule.Execute(UpdatePanelHeights);
71+
UpdatePanelHeights();
7672
});
7773

7874
var contentSplitView = rootVisualElement.Q<TwoPaneSplitView>(Names.kContentContainer);

Packages/com.unity.render-pipelines.core/Editor/RenderGraph/RenderGraphViewer.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,6 @@ class PassElementInfo
312312
public readonly List<ResourceRWBlock> resourceBlocks = new();
313313

314314
public VisualElement leftGridLine;
315-
public VisualElement rightGridLine;
316315

317316
public bool hasPassCompatibilityTooltip;
318317
public bool isPassCompatibleToMerge;
@@ -1190,7 +1189,7 @@ bool IsResourceVisible(RenderGraph.DebugData.ResourceData resource, RenderGraphR
11901189

11911190
if (!m_ResourceFilterEnabled)
11921191
return true;
1193-
1192+
11941193
if (resource.imported && !m_ResourceFilter.HasFlag(ResourceFilter.ImportedResources))
11951194
return false;
11961195
if (type == RenderGraphResourceType.Texture && !m_ResourceFilter.HasFlag(ResourceFilter.Textures))

Packages/com.unity.render-pipelines.core/Editor/StyleSheets/RenderGraphViewer.uss

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@
4545
background-color: var(--side-panel-background-color);
4646
}
4747

48+
#panel-container #unity-dragline-anchor {
49+
opacity: 0;
50+
}
51+
4852
/* Header */
4953
#header-container {
5054
flex-direction: row;
@@ -65,10 +69,17 @@
6569
justify-content: flex-end;
6670
flex-grow: 1;
6771
background-color: var(--unity-colors-toolbar-background);
72+
overflow: hidden;
6873
}
6974

7075
#search-field {
7176
max-width: 200px;
77+
margin-left: 6px;
78+
height: 17px;
79+
width: 200px;
80+
min-width: 50px;
81+
flex-shrink: 1;
82+
align-self: center;
7283
}
7384

7485
#header-container .unity-base-popup-field__label {
@@ -112,16 +123,19 @@
112123
#pass-filter-field {
113124
height: var(--header-container-height);
114125
min-width: 86px;
126+
flex-shrink: 0;
115127
}
116128

117129
#view-options-field {
118130
height: var(--header-container-height);
119131
min-width: 111px;
132+
flex-shrink: 0;
120133
}
121134

122135
#resource-filter-field {
123136
height: var(--header-container-height);
124137
min-width: 111px;
138+
flex-shrink: 0;
125139
}
126140

127141
#header-container DropdownField .unity-base-popup-field__text {
@@ -562,14 +576,6 @@ ScrollView TextElement {
562576
flex-shrink: 0;
563577
}
564578

565-
.panel-search-field {
566-
margin-left: 6px;
567-
height: 16px;
568-
max-width: 350px;
569-
min-width: 200px;
570-
align-self: center;
571-
}
572-
573579
/* Resource List panel only */
574580

575581
.panel-resource-list__item {

Packages/com.unity.render-pipelines.core/Editor/UXML/RenderGraphViewer.uxml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
<r:ToggleDropdown name="view-options-field" />
1212
</ui:VisualElement>
1313
<ui:VisualElement name="header-container-right">
14-
<uie:ToolbarSearchField name="search-field" class="panel-search-field"/>
14+
<uie:ToolbarSearchField name="search-field"/>
1515
</ui:VisualElement>
1616
</ui:VisualElement>
1717
<ui:TwoPaneSplitView name="content-container" orientation="Horizontal">

0 commit comments

Comments
 (0)