Skip to content
This repository has been archived by the owner on Dec 21, 2024. It is now read-only.

Commit

Permalink
Revert changes to the style of the button dropdown, and the TextBox...
Browse files Browse the repository at this point in the history
now updates whenever text changes rather than when focus changes
  • Loading branch information
StrangeRanger committed Mar 10, 2024
1 parent d9db81f commit 5bfff17
Showing 1 changed file with 24 additions and 47 deletions.
71 changes: 24 additions & 47 deletions ActiveDirectoryQuerier/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,9 @@
<!-- ROW 0 START -->
<Grid Margin="0,0,0,49" Grid.Row="0">
<Grid.ColumnDefinitions>
<ColumnDefinition x:Name="Command" Width="*" />
<ColumnDefinition x:Name="Parameter" Width="*" />
<ColumnDefinition x:Name="Parameter_Values" Width="*" />
<ColumnDefinition Width="*" />
<ColumnDefinition Width="*" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="*" />
Expand Down Expand Up @@ -120,9 +120,7 @@
VerticalAlignment="Center"
Margin="5"
ItemsSource="{Binding PossibleParameters}"
SelectedItem="{Binding SelectedParameter}"
Grid.Row="0"
Grid.Column="1" />
SelectedItem="{Binding SelectedParameter}" />
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
Expand All @@ -138,60 +136,39 @@
HorizontalAlignment="Left"
VerticalAlignment="Center"
Margin="5"
Text="{Binding SelectedParameterValue}" />
Text="{Binding SelectedParameterValue, UpdateSourceTrigger=PropertyChanged}" />
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
<!-- END of Dynamic ComboxBoxes for parameters and values-->

<!-- START of Button ComboBox -->
<ComboBox Margin="0,4,0,6" Height="Auto" Grid.Row="2" Grid.Column="0"
HorizontalAlignment="Center" MinWidth="160" Width="Auto">
<Button Content="Add New Command Slot"
Command="{Binding AddCommandComboBoxRelay}"
Background="Transparent"
BorderBrush="Transparent" />
<Button Content="Add New Parameter Slot"
Command="{Binding AddParameterComboBoxRelay}"
Background="Transparent"
BorderBrush="Transparent" />
<Button Content="Remove Parameter Slot"
Command="{Binding RemoveParameterComboBoxRelay}"
Background="Transparent"
BorderBrush="Transparent" />
<Button Content="Save Query" Command="{Binding SaveCustomQueriesRelay}"
Background="Transparent"
BorderBrush="Transparent" />
<Button Content="Execute" Command="{Binding ExecuteCommandRelay}"
Background="Transparent"
BorderBrush="Transparent" />
<Button Content="Execute to CSV" Command="{Binding OutputToCsvFileRelay}"
Background="Transparent"
BorderBrush="Transparent" />
<Button Content="Execute to Text" Command="{Binding OutputToTextFileRelay}"
Background="Transparent"
BorderBrush="Transparent" />
<Button Content="Export Console Output"
Command="{Binding ExportConsoleOutputRelay}"
Background="Transparent"
BorderBrush="Transparent" />
<Button Content="Clear Console Output" Command="{Binding ClearConsoleOutputRelay}"
Background="Transparent"
BorderBrush="Transparent" />
<Button Content="Clear Query" Command="{Binding ClearQueryBuilderRelay}"
Background="Transparent"
BorderBrush="Transparent" />
</ComboBox>
<Menu Margin="0,4,0,6" Height="Auto" Grid.Row="2" Grid.Column="0"
HorizontalAlignment="Center" MinWidth="160" Width="Auto">
<MenuItem Header="Options" MinWidth="160" Height="Auto" Width="Auto">
<MenuItem Header="Add New Command Slot"
Command="{Binding AddCommandComboBoxRelay}" />
<MenuItem Header="Add New Parameter Slot"
Command="{Binding AddParameterComboBoxRelay}" />
<MenuItem Header="Remove Parameter Slot"
Command="{Binding RemoveParameterComboBoxRelay}" />
<MenuItem Header="Save Query" Command="{Binding SaveCustomQueriesRelay}" />
<MenuItem Header="Execute" Command="{Binding ExecuteCommandRelay}" />
<MenuItem Header="Execute to CSV" Command="{Binding OutputToCsvFileRelay}" />
<MenuItem Header="Execute to Text" Command="{Binding OutputToTextFileRelay}" />
<MenuItem Header="Export Console Output"
Command="{Binding ExportConsoleOutputRelay}" />
<MenuItem Header="Clear Console Output" Command="{Binding ClearConsoleOutputRelay}" />
<MenuItem Header="Clear Query" Command="{Binding ClearQueryBuilderRelay}" />
</MenuItem>
</Menu>
<!-- END of Button ComboBox-->
<CheckBox Grid.Row="2" Grid.Column="0" Content="Editing" HorizontalAlignment="Left"
Margin="10,6,10,0"
VerticalAlignment="Top" IsChecked="{Binding EditingEnabled}" Height="15"
Width="57" />
</Grid>
<!-- ROW 0 END -->

<!-- TODO: Figure out why I can't get the console to be resizable to the min height! -->
<!-- TODO: Pieter refer here for the console output... try replicate for tab three -->
<!-- GRID ROW 1 START -->
<!-- TextBox as Console Output -->
<TextBox Grid.Row="1" Text="{Binding PowerShellOutput.ConsoleOutput}"
Expand Down

0 comments on commit 5bfff17

Please # to comment.