From 534b9673cd6c056fdc056cbb838516e14266b630 Mon Sep 17 00:00:00 2001 From: Davide Giacometti Date: Thu, 9 Nov 2023 13:22:35 +0100 Subject: [PATCH 1/7] [Tests]Increase WebView2 loading timeout (#29760) --- .../MarkdownPreviewHandlerTest.cs | 2 +- .../UnitTests-SvgPreviewHandler/SvgPreviewControlTests.cs | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/modules/previewpane/UnitTests-MarkdownPreviewHandler/MarkdownPreviewHandlerTest.cs b/src/modules/previewpane/UnitTests-MarkdownPreviewHandler/MarkdownPreviewHandlerTest.cs index 33dfeb29cc..773bfe65b4 100644 --- a/src/modules/previewpane/UnitTests-MarkdownPreviewHandler/MarkdownPreviewHandlerTest.cs +++ b/src/modules/previewpane/UnitTests-MarkdownPreviewHandler/MarkdownPreviewHandlerTest.cs @@ -17,7 +17,7 @@ namespace MarkdownPreviewHandlerUnitTests public class MarkdownPreviewHandlerTest { // A long timeout is needed. WebView2 can take a long time to load the first time in some CI systems. - private static readonly int HardTimeoutInMilliseconds = 30000; + private static readonly int HardTimeoutInMilliseconds = 60000; private static readonly int SleepTimeInMilliseconds = 200; [TestMethod] diff --git a/src/modules/previewpane/UnitTests-SvgPreviewHandler/SvgPreviewControlTests.cs b/src/modules/previewpane/UnitTests-SvgPreviewHandler/SvgPreviewControlTests.cs index d6a6f911ff..2636970e31 100644 --- a/src/modules/previewpane/UnitTests-SvgPreviewHandler/SvgPreviewControlTests.cs +++ b/src/modules/previewpane/UnitTests-SvgPreviewHandler/SvgPreviewControlTests.cs @@ -4,9 +4,7 @@ using System; using System.Drawing; -using System.Runtime.InteropServices; using System.Runtime.InteropServices.ComTypes; -using System.Text; using System.Threading; using System.Windows.Forms; using Microsoft.PowerToys.PreviewHandler.Svg; @@ -22,7 +20,7 @@ namespace SvgPreviewHandlerUnitTests public class SvgPreviewControlTests { // A long timeout is needed. WebView2 can take a long time to load the first time in some CI systems. - private static readonly int HardTimeoutInMilliseconds = 30000; + private static readonly int HardTimeoutInMilliseconds = 60000; private static readonly int SleepTimeInMilliseconds = 200; [TestMethod] From 912d7ec060beffa8d9c21ef91928826e0a912541 Mon Sep 17 00:00:00 2001 From: gokcekantarci <115616017+gokcekantarci@users.noreply.github.com> Date: Thu, 9 Nov 2023 17:18:00 +0300 Subject: [PATCH 2/7] [PTRun][Program]Fix crashes getting images for .lnk files (#29237) * [PTRun] Refactor GetHBitmap to handle external DLL failures in a separate task. * Revert "[PTRun] Refactor GetHBitmap to handle external DLL failures in a separate task." This reverts commit 159c5744b8ea19c24d330d9ff9504d239eb0acfd. * [PTRun] GetBitmapSource function has been added for file extensions that cause crashes. * [PTRun] Spell Check update. * [PTRun] Renamed function and variable name. * [PTRun] ShellLinkHelper moved to Wox.Infrastructure for common use. --- .../Storage/Win32ProgramRepositoryTest.cs | 2 +- .../IShellLinkHelper.cs | 2 +- .../Image/WindowsThumbnailProvider.cs | 29 +++++++++++++++++-- .../ShellLinkHelper.cs | 7 ++--- 4 files changed, 32 insertions(+), 8 deletions(-) rename src/modules/launcher/{Plugins/Microsoft.Plugin.Program/Programs => Wox.Infrastructure}/IShellLinkHelper.cs (90%) rename src/modules/launcher/{Plugins/Microsoft.Plugin.Program/Programs => Wox.Infrastructure}/ShellLinkHelper.cs (97%) diff --git a/src/modules/launcher/Plugins/Microsoft.Plugin.Program.UnitTests/Storage/Win32ProgramRepositoryTest.cs b/src/modules/launcher/Plugins/Microsoft.Plugin.Program.UnitTests/Storage/Win32ProgramRepositoryTest.cs index 0d4aafb094..4cb1b0510f 100644 --- a/src/modules/launcher/Plugins/Microsoft.Plugin.Program.UnitTests/Storage/Win32ProgramRepositoryTest.cs +++ b/src/modules/launcher/Plugins/Microsoft.Plugin.Program.UnitTests/Storage/Win32ProgramRepositoryTest.cs @@ -7,10 +7,10 @@ using System.Diagnostics; using System.IO; using System.IO.Abstractions; using System.Linq; -using Microsoft.Plugin.Program.Programs; using Microsoft.Plugin.Program.Storage; using Microsoft.VisualStudio.TestTools.UnitTesting; using Moq; +using Wox.Infrastructure; using Wox.Infrastructure.FileSystemHelper; using Wox.Infrastructure.Storage; using Win32Program = Microsoft.Plugin.Program.Programs.Win32Program; diff --git a/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/IShellLinkHelper.cs b/src/modules/launcher/Wox.Infrastructure/IShellLinkHelper.cs similarity index 90% rename from src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/IShellLinkHelper.cs rename to src/modules/launcher/Wox.Infrastructure/IShellLinkHelper.cs index 45b7e64083..6422e108ce 100644 --- a/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/IShellLinkHelper.cs +++ b/src/modules/launcher/Wox.Infrastructure/IShellLinkHelper.cs @@ -2,7 +2,7 @@ // The Microsoft Corporation licenses this file to you under the MIT license. // See the LICENSE file in the project root for more information. -namespace Microsoft.Plugin.Program.Programs +namespace Wox.Infrastructure { public interface IShellLinkHelper { diff --git a/src/modules/launcher/Wox.Infrastructure/Image/WindowsThumbnailProvider.cs b/src/modules/launcher/Wox.Infrastructure/Image/WindowsThumbnailProvider.cs index bcd645d1a4..4dd9481678 100644 --- a/src/modules/launcher/Wox.Infrastructure/Image/WindowsThumbnailProvider.cs +++ b/src/modules/launcher/Wox.Infrastructure/Image/WindowsThumbnailProvider.cs @@ -82,7 +82,19 @@ namespace Wox.Infrastructure.Image public static BitmapSource GetThumbnail(string fileName, int width, int height, ThumbnailOptions options) { - IntPtr hBitmap = GetHBitmap(Path.GetFullPath(fileName), width, height, options); + IntPtr hBitmap = IntPtr.Zero; + if (Path.GetExtension(fileName).Equals(".lnk", StringComparison.OrdinalIgnoreCase)) + { + // If the file has a '.lnk' extension, it is a shortcut file. Use the shellLinkHelper to retrieve the actual target file path from the shortcut. + IShellLinkHelper shellLinkHelper = new ShellLinkHelper(); + + string targetFilePath = shellLinkHelper.RetrieveTargetPath(fileName); + hBitmap = ExtractIconToHBitmap(targetFilePath); + } + else + { + hBitmap = GetHBitmap(Path.GetFullPath(fileName), width, height, options); + } try { @@ -119,7 +131,7 @@ namespace Wox.Infrastructure.Image HResult hr = ((IShellItemImageFactory)nativeShellItem).GetImage(nativeSize, options, out hBitmap); - // if extracting image thumbnail and failed, extract shell icon + // if extracting image thumbnail and failed, extract shell icon if (options == ThumbnailOptions.ThumbnailOnly && hr == HResult.ExtractionFailed) { hr = ((IShellItemImageFactory)nativeShellItem).GetImage(nativeSize, ThumbnailOptions.IconOnly, out hBitmap); @@ -146,6 +158,19 @@ namespace Wox.Infrastructure.Image } } + public static IntPtr ExtractIconToHBitmap(string fileName) + { + // Extracts the icon associated with the file + using (System.Drawing.Icon thumbnailIcon = System.Drawing.Icon.ExtractAssociatedIcon(fileName)) + { + // Convert to Bitmap + using (System.Drawing.Bitmap bitmap = thumbnailIcon.ToBitmap()) + { + return bitmap.GetHbitmap(); + } + } + } + private static bool logReportedAdobeReaderDetected; // Keep track if Adobe Reader detection has been logged yet. private static bool logReportedErrorInDetectingAdobeReader; // Keep track if we reported an exception while trying to detect Adobe Reader yet. private static bool adobeReaderDetectionLastResult; // The last result when Adobe Reader detection has read the registry. diff --git a/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/ShellLinkHelper.cs b/src/modules/launcher/Wox.Infrastructure/ShellLinkHelper.cs similarity index 97% rename from src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/ShellLinkHelper.cs rename to src/modules/launcher/Wox.Infrastructure/ShellLinkHelper.cs index a664e7fc69..2dd2b24096 100644 --- a/src/modules/launcher/Plugins/Microsoft.Plugin.Program/Programs/ShellLinkHelper.cs +++ b/src/modules/launcher/Wox.Infrastructure/ShellLinkHelper.cs @@ -7,10 +7,9 @@ using System.Runtime.InteropServices; using System.Runtime.InteropServices.ComTypes; using System.Text; using Accessibility; -using Microsoft.Plugin.Program.Logger; using Wox.Plugin.Logger; -namespace Microsoft.Plugin.Program.Programs +namespace Wox.Infrastructure { public class ShellLinkHelper : IShellLinkHelper { @@ -142,7 +141,7 @@ namespace Microsoft.Plugin.Program.Programs } catch (System.IO.FileNotFoundException ex) { - ProgramLogger.Exception("Path could not be retrieved", ex, GetType(), path); + Log.Exception("Path could not be retrieved", ex, GetType(), path); return string.Empty; } @@ -165,7 +164,7 @@ namespace Microsoft.Plugin.Program.Programs ((IShellLinkW)link).GetDescription(buffer, MAX_PATH); Description = buffer.ToString(); } - catch (Exception e) + catch (System.Exception e) { Log.Exception($"Failed to fetch description for {target}, {e.Message}", e, GetType()); Description = string.Empty; From 9620d265aed0071499cef1ebc0783c4d3daf4ee5 Mon Sep 17 00:00:00 2001 From: Laszlo Nemeth <57342539+donlaci@users.noreply.github.com> Date: Thu, 9 Nov 2023 15:43:28 +0100 Subject: [PATCH 3/7] [Settings][Dashboard]Switch to settings page on module clicked (#29554) * Settings Dashboard: Adding feature switch to settings page if module panel clicked. * fixing xaml styling * Refactoring, creating common methods GetModuleAccentColor and GetModulePageType * Correct button style to be invisible. Add the same functionality to the disabled modules. * fixing XAML styling --- .../Settings.UI/Helpers/ModuleHelper.cs | 66 +++++ .../SettingsXAML/Views/DashboardPage.xaml | 252 ++++++++++-------- .../SettingsXAML/Views/DashboardPage.xaml.cs | 5 + .../ViewModels/DashboardViewModel.cs | 52 ++-- 4 files changed, 225 insertions(+), 150 deletions(-) diff --git a/src/settings-ui/Settings.UI/Helpers/ModuleHelper.cs b/src/settings-ui/Settings.UI/Helpers/ModuleHelper.cs index b78c118b49..25d5fb4f59 100644 --- a/src/settings-ui/Settings.UI/Helpers/ModuleHelper.cs +++ b/src/settings-ui/Settings.UI/Helpers/ModuleHelper.cs @@ -5,6 +5,8 @@ using global::PowerToys.GPOWrapper; using ManagedCommon; using Microsoft.PowerToys.Settings.UI.Library; +using Microsoft.PowerToys.Settings.UI.Views; +using Windows.UI; namespace Microsoft.PowerToys.Settings.UI.Helpers { @@ -129,5 +131,69 @@ namespace Microsoft.PowerToys.Settings.UI.Helpers default: return GpoRuleConfigured.Unavailable; } } + + public static Color GetModuleAccentColor(ModuleType moduleType) + { + return moduleType switch + { + ModuleType.AlwaysOnTop => Color.FromArgb(255, 74, 196, 242), // #4ac4f2 + ModuleType.Awake => Color.FromArgb(255, 40, 177, 233), // #28b1e9 + ModuleType.ColorPicker => Color.FromArgb(255, 7, 129, 211), // #0781d3 + ModuleType.CropAndLock => Color.FromArgb(255, 32, 166, 228), // #20a6e4 + ModuleType.EnvironmentVariables => Color.FromArgb(255, 16, 132, 208), // #1084d0 + ModuleType.FancyZones => Color.FromArgb(255, 65, 209, 247), // #41d1f7 + ModuleType.FileLocksmith => Color.FromArgb(255, 245, 161, 20), // #f5a114 + ModuleType.FindMyMouse => Color.FromArgb(255, 104, 109, 112), // #686d70 + ModuleType.Hosts => Color.FromArgb(255, 16, 132, 208), // #1084d0 + ModuleType.ImageResizer => Color.FromArgb(255, 85, 207, 248), // #55cff8 + ModuleType.KeyboardManager => Color.FromArgb(255, 224, 231, 238), // #e0e7ee + ModuleType.MouseHighlighter => Color.FromArgb(255, 17, 126, 199), // #117ec7 + ModuleType.MouseJump => Color.FromArgb(255, 240, 240, 239), // #f0f0ef + ModuleType.MousePointerCrosshairs => Color.FromArgb(255, 25, 115, 182), // #1973b6 + ModuleType.MouseWithoutBorders => Color.FromArgb(255, 31, 164, 227), // #1fa4e3 + ModuleType.PastePlain => Color.FromArgb(255, 243, 156, 16), // #f39c10 + ModuleType.Peek => Color.FromArgb(255, 255, 214, 103), // #ffd667 + ModuleType.PowerRename => Color.FromArgb(255, 43, 186, 243), // #2bbaf3 + ModuleType.PowerLauncher => Color.FromArgb(255, 51, 191, 240), // #33bff0 + ModuleType.PowerAccent => Color.FromArgb(255, 84, 89, 92), // #54595c + ModuleType.RegistryPreview => Color.FromArgb(255, 17, 80, 138), // #11508a + ModuleType.MeasureTool => Color.FromArgb(255, 135, 144, 153), // #879099 + ModuleType.ShortcutGuide => Color.FromArgb(255, 193, 202, 209), // #c1cad1 + ModuleType.PowerOCR => Color.FromArgb(255, 24, 153, 224), // #1899e0 + _ => Color.FromArgb(255, 255, 255, 255), // never called, all values listed above + }; + } + + public static System.Type GetModulePageType(ModuleType moduleType) + { + return moduleType switch + { + ModuleType.AlwaysOnTop => typeof(AlwaysOnTopPage), + ModuleType.Awake => typeof(AwakePage), + ModuleType.ColorPicker => typeof(ColorPickerPage), + ModuleType.CropAndLock => typeof(CropAndLockPage), + ModuleType.EnvironmentVariables => typeof(EnvironmentVariablesPage), + ModuleType.FancyZones => typeof(FancyZonesPage), + ModuleType.FileLocksmith => typeof(FileLocksmithPage), + ModuleType.FindMyMouse => typeof(MouseUtilsPage), + ModuleType.Hosts => typeof(HostsPage), + ModuleType.ImageResizer => typeof(ImageResizerPage), + ModuleType.KeyboardManager => typeof(KeyboardManagerPage), + ModuleType.MouseHighlighter => typeof(MouseUtilsPage), + ModuleType.MouseJump => typeof(MouseUtilsPage), + ModuleType.MousePointerCrosshairs => typeof(MouseUtilsPage), + ModuleType.MouseWithoutBorders => typeof(MouseWithoutBordersPage), + ModuleType.PastePlain => typeof(PastePlainPage), + ModuleType.Peek => typeof(PeekPage), + ModuleType.PowerRename => typeof(PowerRenamePage), + ModuleType.PowerLauncher => typeof(PowerLauncherPage), + ModuleType.PowerAccent => typeof(PowerAccentPage), + ModuleType.RegistryPreview => typeof(RegistryPreviewPage), + ModuleType.MeasureTool => typeof(MeasureToolPage), + ModuleType.ShortcutGuide => typeof(ShortcutGuidePage), + ModuleType.PowerOCR => typeof(PowerOcrPage), + _ => typeof(DashboardPage), // never called, all values listed above + }; + } } } diff --git a/src/settings-ui/Settings.UI/SettingsXAML/Views/DashboardPage.xaml b/src/settings-ui/Settings.UI/SettingsXAML/Views/DashboardPage.xaml index cac07b5bfd..1da710fea4 100644 --- a/src/settings-ui/Settings.UI/SettingsXAML/Views/DashboardPage.xaml +++ b/src/settings-ui/Settings.UI/SettingsXAML/Views/DashboardPage.xaml @@ -1,4 +1,4 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + @@ -389,53 +398,62 @@ - - - - - - - - - - - - - - - - - - - - + diff --git a/src/settings-ui/Settings.UI/SettingsXAML/Views/DashboardPage.xaml.cs b/src/settings-ui/Settings.UI/SettingsXAML/Views/DashboardPage.xaml.cs index 77ffbff1ab..4130f94f8a 100644 --- a/src/settings-ui/Settings.UI/SettingsXAML/Views/DashboardPage.xaml.cs +++ b/src/settings-ui/Settings.UI/SettingsXAML/Views/DashboardPage.xaml.cs @@ -49,5 +49,10 @@ namespace Microsoft.PowerToys.Settings.UI.Views { ViewModel.SWVersionButtonClicked(); } + + private void DashboardListItemClick(object sender, RoutedEventArgs e) + { + ViewModel.DashboardListItemClick(sender); + } } } diff --git a/src/settings-ui/Settings.UI/ViewModels/DashboardViewModel.cs b/src/settings-ui/Settings.UI/ViewModels/DashboardViewModel.cs index 75ac631c75..73e6588b0f 100644 --- a/src/settings-ui/Settings.UI/ViewModels/DashboardViewModel.cs +++ b/src/settings-ui/Settings.UI/ViewModels/DashboardViewModel.cs @@ -78,7 +78,7 @@ namespace Microsoft.PowerToys.Settings.UI.ViewModels IsLocked = gpo == GpoRuleConfigured.Enabled || gpo == GpoRuleConfigured.Disabled, Icon = ModuleHelper.GetModuleTypeFluentIconName(moduleType), EnabledChangedCallback = EnabledChangedOnUI, - AccentColor = GetModuleAccentColor(moduleType), + AccentColor = ModuleHelper.GetModuleAccentColor(moduleType), DashboardModuleItems = GetModuleItems(moduleType), }); if (moduleType == ModuleType.KeyboardManager && gpo != GpoRuleConfigured.Disabled) @@ -88,38 +88,6 @@ namespace Microsoft.PowerToys.Settings.UI.ViewModels } } - private Color GetModuleAccentColor(ModuleType moduleType) - { - return moduleType switch - { - ModuleType.AlwaysOnTop => Color.FromArgb(255, 74, 196, 242), // #4ac4f2 - ModuleType.Awake => Color.FromArgb(255, 40, 177, 233), // #28b1e9 - ModuleType.ColorPicker => Color.FromArgb(255, 7, 129, 211), // #0781d3 - ModuleType.CropAndLock => Color.FromArgb(255, 32, 166, 228), // #20a6e4 - ModuleType.EnvironmentVariables => Color.FromArgb(255, 16, 132, 208), // #1084d0 - ModuleType.FancyZones => Color.FromArgb(255, 65, 209, 247), // #41d1f7 - ModuleType.FileLocksmith => Color.FromArgb(255, 245, 161, 20), // #f5a114 - ModuleType.FindMyMouse => Color.FromArgb(255, 104, 109, 112), // #686d70 - ModuleType.Hosts => Color.FromArgb(255, 16, 132, 208), // #1084d0 - ModuleType.ImageResizer => Color.FromArgb(255, 85, 207, 248), // #55cff8 - ModuleType.KeyboardManager => Color.FromArgb(255, 224, 231, 238), // #e0e7ee - ModuleType.MouseHighlighter => Color.FromArgb(255, 17, 126, 199), // #117ec7 - ModuleType.MouseJump => Color.FromArgb(255, 240, 240, 239), // #f0f0ef - ModuleType.MousePointerCrosshairs => Color.FromArgb(255, 25, 115, 182), // #1973b6 - ModuleType.MouseWithoutBorders => Color.FromArgb(255, 31, 164, 227), // #1fa4e3 - ModuleType.PastePlain => Color.FromArgb(255, 243, 156, 16), // #f39c10 - ModuleType.Peek => Color.FromArgb(255, 255, 214, 103), // #ffd667 - ModuleType.PowerRename => Color.FromArgb(255, 43, 186, 243), // #2bbaf3 - ModuleType.PowerLauncher => Color.FromArgb(255, 51, 191, 240), // #33bff0 - ModuleType.PowerAccent => Color.FromArgb(255, 84, 89, 92), // #54595c - ModuleType.RegistryPreview => Color.FromArgb(255, 17, 80, 138), // #11508a - ModuleType.MeasureTool => Color.FromArgb(255, 135, 144, 153), // #879099 - ModuleType.ShortcutGuide => Color.FromArgb(255, 193, 202, 209), // #c1cad1 - ModuleType.PowerOCR => Color.FromArgb(255, 24, 153, 224), // #1899e0 - _ => Color.FromArgb(255, 255, 255, 255), // never called, all values listed above - }; - } - private void LoadKBMSettingsFromJson() { KeyboardManagerProfile kbmProfile = GetKBMProfile(); @@ -528,5 +496,23 @@ namespace Microsoft.PowerToys.Settings.UI.ViewModels var actionName = "Launch"; SendConfigMSG("{\"action\":{\"RegistryPreview\":{\"action_name\":\"" + actionName + "\", \"value\":\"\"}}}"); } + + internal void DashboardListItemClick(object sender) + { + Button button = sender as Button; + if (button == null) + { + return; + } + + if (!(button.Tag is ModuleType)) + { + return; + } + + ModuleType moduleType = (ModuleType)button.Tag; + + NavigationService.Navigate(ModuleHelper.GetModulePageType(moduleType)); + } } } From 097c9706b361a117df416691f7b8cf74aed9d2cf Mon Sep 17 00:00:00 2001 From: Pedro Lamas Date: Thu, 9 Nov 2023 14:57:52 +0000 Subject: [PATCH 4/7] [Build]Add Microsoft.Build.CopyOnWrite package for Dev Drive speedup (#29726) --- Directory.Build.targets | 3 +++ PowerToys.sln | 1 + src/modules/keyboardmanager/Directory.Build.targets | 2 ++ src/settings-ui/Directory.Build.targets | 1 + 4 files changed, 7 insertions(+) create mode 100644 Directory.Build.targets diff --git a/Directory.Build.targets b/Directory.Build.targets new file mode 100644 index 0000000000..66a8733ce6 --- /dev/null +++ b/Directory.Build.targets @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/PowerToys.sln b/PowerToys.sln index 21c1848742..81257cd738 100644 --- a/PowerToys.sln +++ b/PowerToys.sln @@ -177,6 +177,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution src\.editorconfig = src\.editorconfig .vsconfig = .vsconfig Directory.Build.props = Directory.Build.props + Directory.Build.targets = Directory.Build.targets Directory.Packages.props = Directory.Packages.props Solution.props = Solution.props EndProjectSection diff --git a/src/modules/keyboardmanager/Directory.Build.targets b/src/modules/keyboardmanager/Directory.Build.targets index d37c24b655..dfcf63e016 100644 --- a/src/modules/keyboardmanager/Directory.Build.targets +++ b/src/modules/keyboardmanager/Directory.Build.targets @@ -1,4 +1,6 @@ + + diff --git a/src/settings-ui/Directory.Build.targets b/src/settings-ui/Directory.Build.targets index 742af06995..d8e2e4e8ce 100644 --- a/src/settings-ui/Directory.Build.targets +++ b/src/settings-ui/Directory.Build.targets @@ -1,4 +1,5 @@ + From 6084a51e23d2ad2280982f237090ff833cae010b Mon Sep 17 00:00:00 2001 From: Niels Laute Date: Thu, 9 Nov 2023 16:07:09 +0100 Subject: [PATCH 5/7] [Settings][UX]Fix backup info clipping (#29729) --- .../SettingsXAML/Views/GeneralPage.xaml | 35 ++++++++++++------- 1 file changed, 23 insertions(+), 12 deletions(-) diff --git a/src/settings-ui/Settings.UI/SettingsXAML/Views/GeneralPage.xaml b/src/settings-ui/Settings.UI/SettingsXAML/Views/GeneralPage.xaml index 07e415dd14..dd21099ba4 100644 --- a/src/settings-ui/Settings.UI/SettingsXAML/Views/GeneralPage.xaml +++ b/src/settings-ui/Settings.UI/SettingsXAML/Views/GeneralPage.xaml @@ -236,17 +236,18 @@ - + + + + + + TextWrapping="Wrap"> @@ -254,6 +255,7 @@ - + - + - + @@ -281,7 +286,10 @@ - + @@ -293,20 +301,23 @@ Grid.Row="1" Grid.Column="1" Foreground="{ThemeResource TextFillColorSecondaryBrush}" - Text="{Binding LastSettingsBackupFileName, Mode=OneWay}" /> + Text="{Binding LastSettingsBackupFileName, Mode=OneWay}" + TextWrapping="WrapWholeWords" /> + Text="{Binding LastSettingsBackupSource, Mode=OneWay}" + TextWrapping="WrapWholeWords" /> + Text="{Binding LastSettingsBackupDate, Mode=OneWay}" + TextWrapping="WrapWholeWords" /> From 230639fbd61a374d1f3059ba916b03e046eea614 Mon Sep 17 00:00:00 2001 From: Niels Laute Date: Thu, 9 Nov 2023 17:12:25 +0100 Subject: [PATCH 6/7] [A11y]Fix unreadable color brushes (#29731) * Updating SubtleButton brushes * Remove system brush resource * Updating custom infobar colors * Updating other SubtleButtonStyle references --- .../EnvironmentVariablesXAML/App.xaml | 78 ++++++++++++++--- .../FileLocksmithXAML/App.xaml | 83 +++++++++++++++---- src/modules/Hosts/Hosts/HostsXAML/App.xaml | 79 ++++++++++++++---- .../SettingsXAML/Styles/Button.xaml | 82 ++++++++++++++---- .../SettingsXAML/Themes/Colors.xaml | 4 +- .../SettingsXAML/Views/ImageResizerPage.xaml | 2 - 6 files changed, 263 insertions(+), 65 deletions(-) diff --git a/src/modules/EnvironmentVariables/EnvironmentVariables/EnvironmentVariablesXAML/App.xaml b/src/modules/EnvironmentVariables/EnvironmentVariables/EnvironmentVariablesXAML/App.xaml index ae8ef32742..d4b0dc7bbc 100644 --- a/src/modules/EnvironmentVariables/EnvironmentVariables/EnvironmentVariablesXAML/App.xaml +++ b/src/modules/EnvironmentVariables/EnvironmentVariables/EnvironmentVariablesXAML/App.xaml @@ -12,21 +12,66 @@ - - - - + + + + + + - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - diff --git a/src/modules/Hosts/Hosts/HostsXAML/App.xaml b/src/modules/Hosts/Hosts/HostsXAML/App.xaml index 43592ea817..7d19cc0d8d 100644 --- a/src/modules/Hosts/Hosts/HostsXAML/App.xaml +++ b/src/modules/Hosts/Hosts/HostsXAML/App.xaml @@ -11,24 +11,66 @@ - - - - + + + + + + - - - - + + + + - Transparent - Transparent + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +