diff options
| author | Victoria Plitt <Victoria.Plitt@twine-s.com> | 2019-09-03 09:51:32 +0300 |
|---|---|---|
| committer | Victoria Plitt <Victoria.Plitt@twine-s.com> | 2019-09-03 09:51:32 +0300 |
| commit | 50b4615b65c7c4566637993868d24c9de939c8bb (patch) | |
| tree | fc3d54a3bb5dbc053275bf20cb15596f944ea9c5 /Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI | |
| parent | d07b62cf2e014da6f7c7226ce7ff017542161708 (diff) | |
| download | Tango-50b4615b65c7c4566637993868d24c9de939c8bb.tar.gz Tango-50b4615b65c7c4566637993868d24c9de939c8bb.zip | |
Hardware version comparison, change colors according to themes
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI')
2 files changed, 7 insertions, 7 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Notifications/DefaultNotificationProvider.cs b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Notifications/DefaultNotificationProvider.cs index 7c56115e3..52a861930 100644 --- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Notifications/DefaultNotificationProvider.cs +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Notifications/DefaultNotificationProvider.cs @@ -430,7 +430,7 @@ namespace Tango.MachineStudio.UI.Notifications /// <param name="message">The message.</param> public void ShowError(string message) { - ShowMessageBox(PackIconKind.AlertOctagon, Brushes.Red, message, false); + ShowMessageBox(PackIconKind.AlertOctagon, (SolidColorBrush)Application.Current.Resources["RedBrush100"], message, false); } /// <summary> @@ -439,7 +439,7 @@ namespace Tango.MachineStudio.UI.Notifications /// <param name="message">The message.</param> public void ShowInfo(string message) { - ShowMessageBox(PackIconKind.CommentAlertOutline, Brushes.Black, message, false); + ShowMessageBox(PackIconKind.CommentAlertOutline, (SolidColorBrush)Application.Current.Resources["Dialog.Foreground"], message, false); } /// <summary> @@ -449,7 +449,7 @@ namespace Tango.MachineStudio.UI.Notifications /// <returns></returns> public bool ShowQuestion(string message) { - return ShowMessageBox(PackIconKind.CommentQuestionOutline, Brushes.Black, message, true).Value; + return ShowMessageBox(PackIconKind.CommentQuestionOutline, (SolidColorBrush)Application.Current.Resources["Dialog.Foreground"], message, true).Value; } /// <summary> @@ -458,7 +458,7 @@ namespace Tango.MachineStudio.UI.Notifications /// <param name="message">The message.</param> public void ShowWarning(string message) { - ShowMessageBox(PackIconKind.AlertOutline, Brushes.DarkOrange, message, false); + ShowMessageBox(PackIconKind.AlertOutline, (SolidColorBrush)Application.Current.Resources["OrangeUploadBrush"], message, false); } /// <summary> @@ -468,7 +468,7 @@ namespace Tango.MachineStudio.UI.Notifications /// <returns></returns> public bool ShowErrorQuestion(string message) { - return ShowMessageBox(PackIconKind.CommentAlertOutline, Brushes.DarkOrange, message, true).Value; + return ShowMessageBox(PackIconKind.CommentAlertOutline, (SolidColorBrush)Application.Current.Resources["OrangeUploadBrush"], message, true).Value; } /// <summary> @@ -568,7 +568,7 @@ namespace Tango.MachineStudio.UI.Notifications Owner = Application.Current.MainWindow, Message = message, IconKind = PackIconKind.Pencil, - IconColor = Brushes.DimGray, + IconColor = (SolidColorBrush)Application.Current.Resources["DimGrayBrush"], Hint = hint, Response = defaultResponse }; diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Notifications/MessageBoxWindow.xaml b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Notifications/MessageBoxWindow.xaml index e037e3630..988e3c21f 100644 --- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Notifications/MessageBoxWindow.xaml +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/Notifications/MessageBoxWindow.xaml @@ -30,7 +30,7 @@ </StackPanel> <Grid> <StackPanel Orientation="Horizontal" VerticalAlignment="Top" Margin="0 30 0 0"> - <materialDesign:PackIcon Kind="{Binding RelativeSource={RelativeSource AncestorType=Window},Path=IconKind}" VerticalAlignment="Top" Width="50" Height="50" Foreground="{StaticResource Dialog.Foreground}" /> + <materialDesign:PackIcon Kind="{Binding RelativeSource={RelativeSource AncestorType=Window},Path=IconKind}" VerticalAlignment="Top" Width="50" Height="50" Foreground="{Binding RelativeSource={RelativeSource AncestorType=Window},Path=IconColor}" /> <TextBlock Padding="0 10 0 0" TextWrapping="Wrap" Margin="10 0 0 0" VerticalAlignment="Top" FontSize="14" Text="{Binding RelativeSource={RelativeSource AncestorType=Window},Path=Message}" Width="400" Foreground="{StaticResource Dialog.Foreground}"></TextBlock> </StackPanel> </Grid> |
