Skip to content
Open
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
9 changes: 5 additions & 4 deletions Loginator/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
xmlns:controls="clr-namespace:Loginator.Controls"
DataContext="{Binding LoginatorViewModel, Source={StaticResource Locator}}"
WindowStartupLocation="CenterScreen"
Title="Loginator" Height="600" Width="900" MinHeight="600" MinWidth="900">
Title="Loginator" Height="600" Width="920" MinHeight="600" MinWidth="920">
<Grid Margin="2">
<Grid.RowDefinitions>
<RowDefinition Height="24" />
Expand All @@ -29,9 +29,10 @@
<Button Content="Search" Width="60" Margin="2,0,0,0" Command="{Binding UpdateSearchCriteriaCommand}"></Button>
<CheckBox Content="Invert" IsChecked="{Binding IsInverted}" Margin="2,2,0,0"></CheckBox>
<Grid>
<Button Content="Configure..." Width="80" Margin="0,0,249,0" Command="{Binding OpenConfigurationCommand}" HorizontalAlignment="Right"></Button>
<Button Content="Clear Logs" Width="80" Margin="0,0,166,0" Command="{Binding ClearLogsCommand}" HorizontalAlignment="Right"></Button>
<Button Content="Clear All" Width="80" Margin="0,0,83,0" Command="{Binding ClearAllCommand}" HorizontalAlignment="Right"></Button>
<Button Content="Configure..." Width="80" Margin="0,0,332,0" Command="{Binding OpenConfigurationCommand}" HorizontalAlignment="Right"></Button>
<Button Content="Clear Logs" Width="80" Margin="0,0, 249,0" Command="{Binding ClearLogsCommand}" HorizontalAlignment="Right"></Button>
<Button Content="Clear All" Width="80" Margin="0,0,166,0" Command="{Binding ClearAllCommand}" HorizontalAlignment="Right"></Button>
<Button Content="Unselect All" Width="80" Margin="0,0,83,0" Command="{Binding UnselectAllCommand}" HorizontalAlignment="Right"></Button>
<ComboBox ItemsSource="{Binding Path=LogLevels}" DisplayMemberPath="Name" SelectedValue="{Binding SelectedInitialLogLevel}" Width="70" Margin="2,0,2,0" HorizontalAlignment="Right"/>
</Grid>

Expand Down
4 changes: 2 additions & 2 deletions Loginator/Version.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
versionCode=8
versionName=1.6.0
versionCode=9
versionName=1.6.1
31 changes: 31 additions & 0 deletions Loginator/ViewModels/LoginatorViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,20 @@ public ICommand ClearAllCommand {
return clearAllCommand;
}
}

private ICommand unselectAllCommand;
public ICommand UnselectAllCommand
{
get
{
if (unselectAllCommand == null)
{
unselectAllCommand = new RelayCommand<LoginatorViewModel>(UnselectAll, CanUnselectAll);
}
return unselectAllCommand;
}
}

private bool CanClearAll(LoginatorViewModel loginator) {
return true;
}
Expand All @@ -383,6 +397,23 @@ public void ClearAll(LoginatorViewModel loginator) {
});
}

private bool CanUnselectAll(LoginatorViewModel loginator)
{
return true;
}
public void UnselectAll(LoginatorViewModel loginator)
{
DispatcherHelper.CheckBeginInvokeOnUI(() => {
lock (ViewModelConstants.SYNC_OBJECT)
{
foreach (var application in this.Applications)
{
application.IsActive = false;
}
}
});
}

private ICommand updateNumberOfLogsPerLevelCommand;
public ICommand UpdateNumberOfLogsPerLevelCommand {
get {
Expand Down