Skip to content

Commit 7d8130a

Browse files
Revert "Merge pull request #352 from erikdarlingdata/dev"
This reverts commit 4202ad7, reversing changes made to 7c9d981.
1 parent 4202ad7 commit 7d8130a

33 files changed

Lines changed: 257 additions & 1827 deletions

Dashboard/Controls/MemoryContent.xaml.cs

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -82,14 +82,6 @@ public MemoryContent()
8282
SetupChartContextMenus();
8383
Loaded += OnLoaded;
8484

85-
// Apply dark theme immediately so charts don't flash white before data loads
86-
TabHelpers.ApplyDarkModeToChart(MemoryStatsOverviewChart);
87-
TabHelpers.ApplyDarkModeToChart(MemoryGrantSizingChart);
88-
TabHelpers.ApplyDarkModeToChart(MemoryGrantActivityChart);
89-
TabHelpers.ApplyDarkModeToChart(MemoryClerksChart);
90-
TabHelpers.ApplyDarkModeToChart(PlanCacheChart);
91-
TabHelpers.ApplyDarkModeToChart(MemoryPressureEventsChart);
92-
9385
_memoryStatsOverviewHover = new Helpers.ChartHoverHelper(MemoryStatsOverviewChart, "MB");
9486
_memoryGrantSizingHover = new Helpers.ChartHoverHelper(MemoryGrantSizingChart, "MB");
9587
_memoryGrantActivityHover = new Helpers.ChartHoverHelper(MemoryGrantActivityChart, "count");

Dashboard/Controls/PlanViewerControl.xaml

Lines changed: 14 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,13 @@
2727
<Separator Margin="12,4"/>
2828
<Button Content="Save .sqlplan" Click="SavePlan_Click" Height="28" Padding="8,0"
2929
ToolTip="Save plan as .sqlplan file"/>
30-
<Separator x:Name="StatementsButtonSeparator" Margin="12,4" Visibility="Collapsed"/>
31-
<Button x:Name="StatementsButton" Content="Statements" Click="ToggleStatements_Click"
32-
Height="28" Padding="8,0" Visibility="Collapsed"
33-
ToolTip="Show/hide statement list"/>
30+
<Separator Margin="12,4"/>
31+
<TextBlock x:Name="StatementLabel" Text="Statement:" VerticalAlignment="Center"
32+
Foreground="{DynamicResource ForegroundMutedBrush}" Margin="0,0,6,0"
33+
Visibility="Collapsed"/>
34+
<ComboBox x:Name="StatementSelector" MinWidth="200" Height="28"
35+
SelectionChanged="StatementSelector_Changed"
36+
Visibility="Collapsed"/>
3437
</StackPanel>
3538
<TextBlock x:Name="CostText" DockPanel.Dock="Right" VerticalAlignment="Center"
3639
HorizontalAlignment="Right"
@@ -89,76 +92,20 @@
8992
Padding="8,4"/>
9093
</Expander>
9194

92-
<!-- Statements Panel + Plan Canvas + Properties Panel -->
95+
<!-- Plan Canvas + Properties Panel -->
9396
<Grid Grid.Row="4">
9497
<Grid.ColumnDefinitions>
95-
<!-- Col 0: Statements Panel (hidden by default) -->
96-
<ColumnDefinition x:Name="StatementsColumn" Width="0"/>
97-
<!-- Col 1: Statements Splitter (hidden by default) -->
98-
<ColumnDefinition x:Name="StatementsSplitterColumn" Width="0"/>
99-
<!-- Col 2: Plan Canvas -->
10098
<ColumnDefinition Width="*"/>
101-
<!-- Col 3: Properties Splitter (hidden by default) -->
10299
<ColumnDefinition Width="Auto"/>
103-
<!-- Col 4: Properties Panel (hidden by default) -->
104100
<ColumnDefinition x:Name="PropertiesColumn" Width="0"/>
105101
</Grid.ColumnDefinitions>
106102

107-
<!-- Statements Panel -->
108-
<Border x:Name="StatementsPanel" Grid.Column="0"
109-
Background="{DynamicResource BackgroundDarkBrush}"
110-
BorderBrush="{DynamicResource BorderBrush}" BorderThickness="0,0,1,0"
111-
Visibility="Collapsed">
112-
<DockPanel>
113-
<!-- Header -->
114-
<Border DockPanel.Dock="Top" Padding="10,8"
115-
Background="{DynamicResource BackgroundBrush}"
116-
BorderBrush="{DynamicResource BorderBrush}" BorderThickness="0,0,0,1">
117-
<DockPanel>
118-
<Button DockPanel.Dock="Right" Content="&#x2715;" Click="CloseStatements_Click"
119-
Width="24" Height="24" Padding="0" FontSize="12"
120-
VerticalAlignment="Center" ToolTip="Close Statements"
121-
Background="Transparent" BorderThickness="0"
122-
Foreground="{DynamicResource ForegroundMutedBrush}"/>
123-
<TextBlock x:Name="StatementsHeader" Text="Statements"
124-
FontWeight="SemiBold" FontSize="13"
125-
Foreground="{DynamicResource ForegroundBrush}"
126-
VerticalAlignment="Center"/>
127-
</DockPanel>
128-
</Border>
129-
130-
<!-- Statement Grid -->
131-
<DataGrid x:Name="StatementsGrid"
132-
AutoGenerateColumns="False"
133-
CanUserSortColumns="True"
134-
CanUserReorderColumns="False"
135-
CanUserResizeColumns="True"
136-
IsReadOnly="True"
137-
SelectionMode="Single"
138-
GridLinesVisibility="Horizontal"
139-
HeadersVisibility="Column"
140-
SelectionChanged="StatementsGrid_SelectionChanged"
141-
FontSize="11"
142-
Background="{DynamicResource BackgroundDarkBrush}"
143-
BorderThickness="0"/>
144-
</DockPanel>
145-
</Border>
146-
147-
<!-- Statements Splitter -->
148-
<GridSplitter x:Name="StatementsSplitter" Grid.Column="1" Width="5"
149-
HorizontalAlignment="Center" VerticalAlignment="Stretch"
150-
Background="{DynamicResource BorderBrush}"
151-
Visibility="Collapsed"/>
152-
153103
<!-- Plan Canvas -->
154-
<ScrollViewer Grid.Column="2" x:Name="PlanScrollViewer"
104+
<ScrollViewer Grid.Column="0" x:Name="PlanScrollViewer"
155105
HorizontalScrollBarVisibility="Auto"
156106
VerticalScrollBarVisibility="Auto"
157107
Background="{DynamicResource BackgroundBrush}"
158-
PreviewMouseWheel="PlanScrollViewer_PreviewMouseWheel"
159-
PreviewMouseLeftButtonDown="PlanScrollViewer_PreviewMouseLeftButtonDown"
160-
PreviewMouseMove="PlanScrollViewer_PreviewMouseMove"
161-
PreviewMouseLeftButtonUp="PlanScrollViewer_PreviewMouseLeftButtonUp">
108+
PreviewMouseWheel="PlanScrollViewer_PreviewMouseWheel">
162109
<Canvas x:Name="PlanCanvas" ClipToBounds="False">
163110
<Canvas.LayoutTransform>
164111
<ScaleTransform x:Name="ZoomTransform" ScaleX="1" ScaleY="1"/>
@@ -167,22 +114,22 @@
167114
</ScrollViewer>
168115

169116
<!-- Empty State -->
170-
<StackPanel x:Name="EmptyState" Grid.Column="2" VerticalAlignment="Center" HorizontalAlignment="Center">
117+
<StackPanel x:Name="EmptyState" Grid.Column="0" VerticalAlignment="Center" HorizontalAlignment="Center">
171118
<TextBlock Text="No Plan Loaded" FontSize="20" FontWeight="Light"
172119
Foreground="{DynamicResource ForegroundMutedBrush}" HorizontalAlignment="Center"/>
173120
<TextBlock Text="Right-click a query row and choose 'View Plan' to display an execution plan here"
174121
FontSize="13" Foreground="{DynamicResource ForegroundMutedBrush}"
175122
HorizontalAlignment="Center" Margin="0,8,0,0"/>
176123
</StackPanel>
177124

178-
<!-- Properties Splitter -->
179-
<GridSplitter x:Name="PropertiesSplitter" Grid.Column="3" Width="5"
125+
<!-- GridSplitter -->
126+
<GridSplitter x:Name="PropertiesSplitter" Grid.Column="1" Width="5"
180127
HorizontalAlignment="Center" VerticalAlignment="Stretch"
181128
Background="{DynamicResource BorderBrush}"
182129
Visibility="Collapsed"/>
183130

184131
<!-- Properties Panel -->
185-
<Border x:Name="PropertiesPanel" Grid.Column="4"
132+
<Border x:Name="PropertiesPanel" Grid.Column="2"
186133
Background="{DynamicResource BackgroundDarkBrush}"
187134
BorderBrush="{DynamicResource BorderBrush}" BorderThickness="1,0,0,0"
188135
Visibility="Collapsed">

0 commit comments

Comments
 (0)