Skip to content

Commit 13f4fdb

Browse files
committed
Task Manager ui tweaks (#63)
1 parent 49dafd9 commit 13f4fdb

File tree

9 files changed

+462
-169
lines changed

9 files changed

+462
-169
lines changed

CHANGELOG.md

+6-1
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,27 @@ All notable changes to this project will be documented in this file.
44

55
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
66

7-
## [UNRELEASED]
7+
## [Unreleased]
88

99
## [1.5.1.11] - 2019-07-19
10+
1011
### Added
1112

1213
- Ability to continue on error for task manager tasks (#68)
1314
- Ability to skip restart warning for Steam library related tasks (#69)
15+
- Icons!
1416

1517
### Changed
1618

1719
- Library Creation dialog is replaced with a flyout panel which clears the path for supporting more library types. (#63 #65)
20+
- Unified Task Manager's List View for Steam & Origin games for easier editing in future.
21+
- Tweaked Task Manager UI a little bit
1822

1923
### Fixed
2024

2125
- "Remove from SLM" Context Menu Item not working with created Origin libraries
2226
- Checking for library existence for SLM libraries not working as intended.
27+
- Showing Steam failover images for Origin games in List View if the image is not loaded correctly.
2328

2429
## [1.5.1.10] - 2019-07-17
2530

Source/Steam Library Manager/Definitions/App.cs

+9-9
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,7 @@ await Main.FormAccessor.AppView.AppPanel.Dispatcher.Invoke(async delegate
441441
{
442442
if (await Main.FormAccessor.ShowMessageAsync(Functions.SLM.Translate(nameof(Properties.Resources.RemoveMovedFiles)), Framework.StringFormat.Format(Functions.SLM.Translate(nameof(Properties.Resources.CompressArchive_FileNotFoundEx)), new { AppName, ExceptionMessage = ex.Message }), MessageDialogStyle.AffirmativeAndNegative).ConfigureAwait(false) == MessageDialogResult.Affirmative)
443443
{
444-
Functions.FileSystem.RemoveGivenFiles(copiedFiles, createdDirectories, currentTask);
444+
Functions.FileSystem.RemoveGivenFilesAsync(copiedFiles, createdDirectories, currentTask);
445445
}
446446
}, System.Windows.Threading.DispatcherPriority.Normal).ConfigureAwait(false);
447447

@@ -547,7 +547,7 @@ await Main.FormAccessor.AppView.AppPanel.Dispatcher.Invoke(async delegate
547547
{
548548
if (await Main.FormAccessor.ShowMessageAsync(Functions.SLM.Translate(nameof(Properties.Resources.RemoveMovedFiles)), Framework.StringFormat.Format(Functions.SLM.Translate(nameof(Properties.Resources.PathTooLongException)), new { AppName, ExceptionMessage = ex.Message }), MessageDialogStyle.AffirmativeAndNegative).ConfigureAwait(false) == MessageDialogResult.Affirmative)
549549
{
550-
Functions.FileSystem.RemoveGivenFiles(copiedFiles, createdDirectories, currentTask);
550+
Functions.FileSystem.RemoveGivenFilesAsync(copiedFiles, createdDirectories, currentTask);
551551
}
552552
}, System.Windows.Threading.DispatcherPriority.Normal);
553553

@@ -568,7 +568,7 @@ await Main.FormAccessor.AppView.AppPanel.Dispatcher.Invoke(async delegate
568568
{
569569
if (await Main.FormAccessor.ShowMessageAsync(Functions.SLM.Translate(nameof(Properties.Resources.RemoveMovedFiles)), Framework.StringFormat.Format(Functions.SLM.Translate(nameof(Properties.Resources.FileSystemRelatedError_DeleteMovedFiles)), new { AppName, ExceptionMessage = ex.Message }), MessageDialogStyle.AffirmativeAndNegative).ConfigureAwait(false) == MessageDialogResult.Affirmative)
570570
{
571-
Functions.FileSystem.RemoveGivenFiles(copiedFiles, createdDirectories, currentTask);
571+
Functions.FileSystem.RemoveGivenFilesAsync(copiedFiles, createdDirectories, currentTask);
572572
}
573573
}, System.Windows.Threading.DispatcherPriority.Normal);
574574

@@ -581,7 +581,7 @@ await Main.FormAccessor.AppView.AppPanel.Dispatcher.Invoke(async delegate
581581
{
582582
if (await Main.FormAccessor.ShowMessageAsync(Functions.SLM.Translate(nameof(Properties.Resources.RemoveMovedFiles)), Framework.StringFormat.Format(Functions.SLM.Translate(nameof(Properties.Resources.FilePermissionRelatedError_DeleteFiles)), new { AppName, ExceptionMessage = ex.Message }), MessageDialogStyle.AffirmativeAndNegative).ConfigureAwait(false) == MessageDialogResult.Affirmative)
583583
{
584-
Functions.FileSystem.RemoveGivenFiles(copiedFiles, createdDirectories, currentTask);
584+
Functions.FileSystem.RemoveGivenFilesAsync(copiedFiles, createdDirectories, currentTask);
585585
}
586586
}, System.Windows.Threading.DispatcherPriority.Normal);
587587
}
@@ -638,7 +638,7 @@ await Main.FormAccessor.AppView.AppPanel.Dispatcher.Invoke(async delegate
638638
{
639639
if (await Main.FormAccessor.ShowMessageAsync(Functions.SLM.Translate(nameof(Properties.Resources.RemoveMovedFiles)), Framework.StringFormat.Format(Functions.SLM.Translate(nameof(Properties.Resources.PathTooLongException)), new { AppName, ExceptionMessage = ex.Message }), MessageDialogStyle.AffirmativeAndNegative).ConfigureAwait(false) == MessageDialogResult.Affirmative)
640640
{
641-
Functions.FileSystem.RemoveGivenFiles(copiedFiles, createdDirectories, currentTask);
641+
Functions.FileSystem.RemoveGivenFilesAsync(copiedFiles, createdDirectories, currentTask);
642642
}
643643
}, System.Windows.Threading.DispatcherPriority.Normal);
644644

@@ -659,7 +659,7 @@ await Main.FormAccessor.AppView.AppPanel.Dispatcher.Invoke(async delegate
659659
{
660660
if (await Main.FormAccessor.ShowMessageAsync(Functions.SLM.Translate(nameof(Properties.Resources.RemoveMovedFiles)), Framework.StringFormat.Format(Functions.SLM.Translate(nameof(Properties.Resources.FileSystemRelatedError_DeleteMovedFiles)), new { AppName, ExceptionMessage = ex.Message }), MessageDialogStyle.AffirmativeAndNegative).ConfigureAwait(false) == MessageDialogResult.Affirmative)
661661
{
662-
Functions.FileSystem.RemoveGivenFiles(copiedFiles, createdDirectories, currentTask);
662+
Functions.FileSystem.RemoveGivenFilesAsync(copiedFiles, createdDirectories, currentTask);
663663
}
664664
}, System.Windows.Threading.DispatcherPriority.Normal);
665665

@@ -672,7 +672,7 @@ await Main.FormAccessor.AppView.AppPanel.Dispatcher.Invoke(async delegate
672672
{
673673
if (await Main.FormAccessor.ShowMessageAsync(Functions.SLM.Translate(nameof(Properties.Resources.RemoveMovedFiles)), Framework.StringFormat.Format(Functions.SLM.Translate(nameof(Properties.Resources.FilePermissionRelatedError_DeleteFiles)), new { AppName, ExceptionMessage = ex.Message }), MessageDialogStyle.AffirmativeAndNegative).ConfigureAwait(false) == MessageDialogResult.Affirmative)
674674
{
675-
Functions.FileSystem.RemoveGivenFiles(copiedFiles, createdDirectories, currentTask);
675+
Functions.FileSystem.RemoveGivenFilesAsync(copiedFiles, createdDirectories, currentTask);
676676
}
677677
}, System.Windows.Threading.DispatcherPriority.Normal);
678678
}
@@ -703,7 +703,7 @@ await Main.FormAccessor.AppView.AppPanel.Dispatcher.Invoke(async delegate
703703
{
704704
if (await Main.FormAccessor.ShowMessageAsync(Functions.SLM.Translate(nameof(Properties.Resources.RemoveMovedFiles)), Framework.StringFormat.Format(Functions.SLM.Translate(nameof(Properties.Resources.TaskCancelled_RemoveFiles)), new { AppName }), MessageDialogStyle.AffirmativeAndNegative).ConfigureAwait(false) == MessageDialogResult.Affirmative)
705705
{
706-
Functions.FileSystem.RemoveGivenFiles(copiedFiles, createdDirectories, currentTask);
706+
Functions.FileSystem.RemoveGivenFilesAsync(copiedFiles, createdDirectories, currentTask);
707707
}
708708
}, System.Windows.Threading.DispatcherPriority.Normal).ConfigureAwait(false);
709709

@@ -725,7 +725,7 @@ await Main.FormAccessor.AppView.AppPanel.Dispatcher.Invoke(async delegate
725725
{
726726
if (await Main.FormAccessor.ShowMessageAsync(Functions.SLM.Translate(nameof(Properties.Resources.RemoveMovedFiles)), Framework.StringFormat.Format(Functions.SLM.Translate(nameof(Properties.Resources.AnyException_RemoveFiles)), new { AppName, ExceptionMessage = ex.Message }), MessageDialogStyle.AffirmativeAndNegative).ConfigureAwait(false) == MessageDialogResult.Affirmative)
727727
{
728-
Functions.FileSystem.RemoveGivenFiles(copiedFiles, createdDirectories, currentTask);
728+
Functions.FileSystem.RemoveGivenFilesAsync(copiedFiles, createdDirectories, currentTask);
729729
}
730730
}, System.Windows.Threading.DispatcherPriority.Normal).ConfigureAwait(false);
731731

Source/Steam Library Manager/Definitions/List.cs

+3-3
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,9 @@ public class TaskInfo : INotifyPropertyChanged
3232
public bool Compact { get; set; } = true;
3333
public bool ForceCompact { get; set; }
3434

35-
public bool ErrorHappened, Active;
35+
public bool ErrorHappened { get; set; }
36+
public bool Active { get; set; }
37+
public bool Completed { get; set; }
3638
public bool Compress { get; set; } = Properties.Settings.Default.Global_Compress;
3739
public bool RemoveOldFiles { get; set; } = Properties.Settings.Default.Global_RemoveOldFiles;
3840
public bool ReportFileMovement { get; set; } = Properties.Settings.Default.Global_ReportFileMovement;
@@ -75,8 +77,6 @@ public double ProgressBarPerc
7577
}
7678
}
7779

78-
public bool Completed { get; set; }
79-
8080
public event PropertyChangedEventHandler PropertyChanged;
8181

8282
protected void OnPropertyChanged(string info) => PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(info));

Source/Steam Library Manager/Forms/AppView.xaml

+11-1
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,17 @@
9393
<ContextMenu ItemsSource="{Binding ContextMenuElements}" BorderThickness="0" />
9494
</Grid.ContextMenu>
9595
<Grid Width="64px" Height="32px" Margin="5" HorizontalAlignment="Left">
96-
<CachedImage:Image Stretch="Fill" ImageUrl="{Binding GameHeaderImage}" />
96+
<CachedImage:Image Stretch="Fill" ImageUrl="{Binding GameHeaderImage}">
97+
<CachedImage:Image.Style>
98+
<Style TargetType="CachedImage:Image">
99+
<Style.Triggers>
100+
<DataTrigger Binding="{Binding Library.Type}" Value="Origin">
101+
<Setter Property="Tag" Value="origin" />
102+
</DataTrigger>
103+
</Style.Triggers>
104+
</Style>
105+
</CachedImage:Image.Style>
106+
</CachedImage:Image>
97107
</Grid>
98108
<Grid>
99109
<TextBlock Text="{Binding AppName}" Padding="74,5,0,0" TextWrapping="Wrap" />

0 commit comments

Comments
 (0)