Free, open-source file converter. Convert 263 formats offline by drag & drop — images, PDF, Word, Excel, PowerPoint, HWP/HWPX, video, audio, e-books and archives. No upload, no Office needed.
C# audio-converteravaloniabatch-conversionconvertercsharpdocument-converterdocx-to-pdfdotnetdrag-and-dropfile-conversionfile-converterheic-converterhwphwpximage-converterlinuxmacospdf-convertervideo-converterwindows
Setup shows the What's new slides while installing; Filee starts with them after an update
KnifeLemon302b413d3627
diff --git a/src/Filee.App/Assets/i18n/en.json b/src/Filee.App/Assets/i18n/en.jsonindex d7f8e7de..7ba63796 100644--- a/src/Filee.App/Assets/i18n/en.json+++ b/src/Filee.App/Assets/i18n/en.json@@ -759,9 +759,6 @@"installer.minimize": "Minimize","installer.error.copy": "Copy details","installer.error.copied": "Copied",- "installer.showcase.expand": "Hold a key and drag a file: drop it on a format. Groups open more formats.",- "installer.showcase.flip": "Press Tab on the donut for its other side: crop, rotate, merge PDFs, remove backgrounds and more.",- "installer.showcase.browser": "Drag a picture straight from the browser: Filee downloads it and converts it.","watch.title": "Watch folders","watch.description": "Files that land in these folders are converted while Filee runs.\nDownloads and copies wait until they're complete.","watch.add": "Add folder",diff --git a/src/Filee.App/Assets/i18n/es.json b/src/Filee.App/Assets/i18n/es.jsonindex a55549ed..ccc77450 100644--- a/src/Filee.App/Assets/i18n/es.json+++ b/src/Filee.App/Assets/i18n/es.json@@ -739,9 +739,6 @@"installer.minimize": "Minimizar","installer.error.copy": "Copiar detalles","installer.error.copied": "Copiado",- "installer.showcase.expand": "Mantén pulsada una tecla y arrastra un archivo: suéltalo sobre un formato. Los grupos abren más formatos.",- "installer.showcase.flip": "Pulsa Tab en el donut para ver su otra cara: recortar, girar, unir PDF, quitar fondos y más.",- "installer.showcase.browser": "Arrastra una imagen directamente desde el navegador: Filee la descarga y la convierte.","watch.title": "Carpetas supervisadas","watch.description": "Los archivos que lleguen a estas carpetas se convierten mientras Filee esté en ejecución.\nLas descargas y las copias se convierten cuando terminan.","watch.add": "Añadir carpeta",diff --git a/src/Filee.App/Assets/i18n/hi.json b/src/Filee.App/Assets/i18n/hi.jsonindex 03ae47ff..86f27693 100644--- a/src/Filee.App/Assets/i18n/hi.json+++ b/src/Filee.App/Assets/i18n/hi.json@@ -739,9 +739,6 @@"installer.minimize": "छोटा करें","installer.error.copy": "विवरण कॉपी करें","installer.error.copied": "कॉपी हो गया",- "installer.showcase.expand": "कोई कुंजी दबाए रखकर फ़ाइल खींचें और किसी फ़ॉर्मेट पर छोड़ें। समूह खोलने पर और फ़ॉर्मेट दिखते हैं।",- "installer.showcase.flip": "डोनट पर Tab दबाकर उसकी दूसरी तरफ़ जाएँ: क्रॉप, घुमाना, PDF जोड़ना, बैकग्राउंड हटाना और भी बहुत कुछ।",- "installer.showcase.browser": "ब्राउज़र से कोई तस्वीर सीधे खींचें: Filee उसे डाउनलोड करके कन्वर्ट करता है।","watch.title": "वॉच फ़ोल्डर","watch.description": "इन फ़ोल्डरों में आने वाली फ़ाइलें Filee चलते समय कन्वर्ट हो जाती हैं।\nडाउनलोड और कॉपी पूरी होने तक प्रतीक्षा करते हैं।","watch.add": "फ़ोल्डर जोड़ें",diff --git a/src/Filee.App/Assets/i18n/ja.json b/src/Filee.App/Assets/i18n/ja.jsonindex 007a3eba..7fcf9d92 100644--- a/src/Filee.App/Assets/i18n/ja.json+++ b/src/Filee.App/Assets/i18n/ja.json@@ -739,9 +739,6 @@"installer.minimize": "最小化","installer.error.copy": "詳細をコピー","installer.error.copied": "コピーしました",- "installer.showcase.expand": "キーを押しながらファイルをドラッグして、形式の上にドロップ。グループを開くと、さらに多くの形式が現れます。",- "installer.showcase.flip": "ドーナツでTabキーを押すと裏面へ。切り抜き、回転、PDFの結合、背景の削除などができます。",- "installer.showcase.browser": "ブラウザーの画像をそのままドラッグ。Fileeがダウンロードして変換します。","watch.title": "監視フォルダー","watch.description": "Fileeの起動中、これらのフォルダーに追加されたファイルを変換します。\nダウンロードやコピーが完了するまで処理を待ちます。","watch.add": "フォルダーを追加",diff --git a/src/Filee.App/Assets/i18n/ko.json b/src/Filee.App/Assets/i18n/ko.jsonindex eb3cc4aa..8d5bbc26 100644--- a/src/Filee.App/Assets/i18n/ko.json+++ b/src/Filee.App/Assets/i18n/ko.json@@ -759,9 +759,6 @@"installer.minimize": "최소화","installer.error.copy": "자세한 내용 복사","installer.error.copied": "복사했어요",- "installer.showcase.expand": "키를 누른 채 파일을 끌어 원하는 형식에 놓으세요. 그룹을 열면 더 많은 형식이 나와요.",- "installer.showcase.flip": "도넛에서 Tab을 누르면 뒷면이 나와요. 자르기, 회전, PDF 합치기, 배경 제거 등을 할 수 있어요.",- "installer.showcase.browser": "브라우저의 그림을 바로 끌어 놓으세요. Filee가 내려받아 변환해요.","watch.title": "자동 변환 폴더","watch.description": "Filee가 켜져 있는 동안 이 폴더에 들어온 파일을 자동으로 변환해요.\n다운로드·복사 중인 파일은 끝난 뒤에 변환해요.","watch.add": "폴더 추가",diff --git a/src/Filee.App/Assets/i18n/pl.json b/src/Filee.App/Assets/i18n/pl.jsonindex 16b813a6..03f62338 100644--- a/src/Filee.App/Assets/i18n/pl.json+++ b/src/Filee.App/Assets/i18n/pl.json@@ -759,9 +759,6 @@"installer.minimize": "Minimalizuj","installer.error.copy": "Kopiuj szczegóły","installer.error.copied": "Skopiowano",- "installer.showcase.expand": "Przytrzymaj klawisz i przeciągnij plik: upuść go na format. Grupy otwierają więcej formatów.",- "installer.showcase.flip": "Naciśnij Tab na donucie, aby zobaczyć drugą stronę: kadrowanie, obracanie, łączenie PDF, usuwanie tła i więcej.",- "installer.showcase.browser": "Przeciągnij obraz prosto z przeglądarki: Filee pobierze go i przekonwertuje.","watch.title": "Obserwowane foldery","watch.description": "Pliki trafiające do tych folderów są konwertowane, gdy Filee działa.\nPobierane i kopiowane pliki czekają na zakończenie.","watch.add": "Dodaj folder",diff --git a/src/Filee.App/Assets/i18n/ru.json b/src/Filee.App/Assets/i18n/ru.jsonindex c3eeaee2..eb9ccc08 100644--- a/src/Filee.App/Assets/i18n/ru.json+++ b/src/Filee.App/Assets/i18n/ru.json@@ -759,9 +759,6 @@"installer.minimize": "Свернуть","installer.error.copy": "Копировать подробности","installer.error.copied": "Скопировано",- "installer.showcase.expand": "Удерживая клавишу, перетащите файл и отпустите его на формате. В группах — ещё больше форматов.",- "installer.showcase.flip": "Нажмите Tab на пончике, чтобы перевернуть его: обрезка, поворот, объединение PDF, удаление фона и многое другое.",- "installer.showcase.browser": "Перетащите картинку прямо из браузера: Filee скачает и конвертирует её.","watch.title": "Папки наблюдения","watch.description": "Файлы, попавшие в эти папки, конвертируются, пока работает Filee.\nСкачиваемые и копируемые файлы ждут, пока не появятся целиком.","watch.add": "Добавить папку",diff --git a/src/Filee.App/Assets/i18n/zh-CN.json b/src/Filee.App/Assets/i18n/zh-CN.jsonindex d4077bfd..0989b9d2 100644--- a/src/Filee.App/Assets/i18n/zh-CN.json+++ b/src/Filee.App/Assets/i18n/zh-CN.json@@ -759,9 +759,6 @@"installer.minimize": "最小化","installer.error.copy": "复制详细信息","installer.error.copied": "已复制",- "installer.showcase.expand": "按住按键拖动文件,放到想要的格式上。打开分组可看到更多格式。",- "installer.showcase.flip": "在圆环上按 Tab 翻到另一面,可以裁剪、旋转、合并 PDF、去除背景等。",- "installer.showcase.browser": "直接从浏览器拖动图片,Filee 会下载并转换。","watch.title": "自动转换文件夹","watch.description": "Filee 运行时,放入这些文件夹的文件会自动转换。\n正在下载或复制的文件会等完成后再转换。","watch.add": "添加文件夹",diff --git a/src/Filee.Setup/Filee.Setup.csproj b/src/Filee.Setup/Filee.Setup.csprojindex ae4f308e..470a05d7 100644--- a/src/Filee.Setup/Filee.Setup.csproj+++ b/src/Filee.Setup/Filee.Setup.csproj@@ -54,11 +54,15 @@<ItemGroup><Compile Include="..\Filee.App\Services\SoftPalette.cs" Link="Shared\SoftPalette.cs" /><Compile Include="..\Filee.App\Services\AppLanguages.cs" Link="Shared\AppLanguages.cs" />+ <!-- The "What's new" slides on the progress card: the app's slideshow, its player and deck reader, and the media. -->+ <Compile Include="..\Filee.App\Controls\AnimatedImage.cs" Link="Shared\AnimatedImage.cs" />+ <Compile Include="..\Filee.App\Controls\AnimatedImageDecoder.cs" Link="Shared\AnimatedImageDecoder.cs" />+ <Compile Include="..\Filee.App\Controls\SlideDeck.cs" Link="Shared\SlideDeck.cs" />+ <Compile Include="..\Filee.App\Controls\SlideShow.cs" Link="Shared\SlideShow.cs" />+ <AvaloniaResource Include="..\Filee.App\Assets\WhatsNew\**" Link="Assets\WhatsNew\%(RecursiveDir)%(Filename)%(Extension)" /><AvaloniaResource Include="..\Filee.App\Styles\Soft.axaml" Link="Styles\Soft.axaml" /><AvaloniaResource Include="..\Filee.App\Assets\Icons\filee.ico" Link="Assets\Icons\filee.ico" /><AvaloniaResource Include="..\Filee.App\Assets\Icons\filee.png" Link="Assets\Icons\filee.png" />- <!-- Feature clips shown while installing (640 px animated WebP, ~330 KB each). -->- <AvaloniaResource Include="Assets\Showcase\*.webp" /><EmbeddedResource Include="..\Filee.App\Assets\i18n\*.json" Link="i18n\%(Filename)%(Extension)" LogicalName="i18n.%(Filename)%(Extension)" /></ItemGroup>diff --git a/src/Filee.Setup/Installation/Installer.cs b/src/Filee.Setup/Installation/Installer.csindex 79341f4f..e30800ff 100644--- a/src/Filee.Setup/Installation/Installer.cs+++ b/src/Filee.Setup/Installation/Installer.cs@@ -8,7 +8,8 @@// PATH; on Windows 11 registers the top-level Explorer menu package;// 7. deletes the backup, or on any failure in 4-6 puts everything back.// Filee's own settings (Explorer menu entry, start at sign-in, engines, language) are handed to Filee when Setup-// starts it, as before: Filee applies them for the signed-in user.+// starts it, as before: Filee applies them for the signed-in user. After an update Filee goes back to the tray and+// shows the new version's "What's new" slides (--background --whats-new).using Filee.Platform.Windows;using Filee.Setup.Payload;@@ -167,9 +168,12 @@ public sealed class Installer(SetupContext context, SetupPayload payload)}}- /// <summary>The arguments Filee starts with: the choices of a fresh install, or "back to the tray" after an update.</summary>+ /// <summary>+ /// The arguments Filee starts with: the choices of a fresh install, or "back to the tray" after an update, with the+ /// new version's "What's new" slides.+ /// </summary>public static string LaunchArguments(InstallChoices choices, bool update) => update- ? "--background"+ ? "--background --whats-new": $"--install-engines={string.Join(',', choices.Engines)} " +$"--start-with-windows={OnOff(choices.Tasks.Startup)} --context-menu={OnOff(choices.Tasks.ContextMenu)}" +(choices.LanguagePicked ? $" --language={choices.Language}" : "");diff --git a/src/Filee.Setup/ViewModels/SetupViewModel.cs b/src/Filee.Setup/ViewModels/SetupViewModel.csindex 61ee926c..bb12a9fe 100644--- a/src/Filee.Setup/ViewModels/SetupViewModel.cs+++ b/src/Filee.Setup/ViewModels/SetupViewModel.cs@@ -1,5 +1,5 @@// One compact card in a few states: Welcome (the logo, one Install button and an Options sheet with the folder, the-// options, the engines and the language) → Progress (feature clips while the files go in) → Done ("Launch Filee") or+// options, the engines and the language) → Progress (the new version's "What's new" slides while the files go in) → Done ("Launch Filee") or// Failed ("Copy details"). An update shows only what it may change (desktop icon, PATH); Filee's own settings stay as// they are. The uninstaller uses the same card: Uninstall (keep or delete the settings) → Progress → Uninstalled.@@ -7,6 +7,7 @@ using System.Collections.ObjectModel;using Avalonia.Threading;using CommunityToolkit.Mvvm.ComponentModel;using CommunityToolkit.Mvvm.Input;+using Filee.App.Controls;using Filee.Setup.Installation;using Filee.Setup.Payload;@@ -50,24 +51,8 @@ public sealed partial class EngineItem(EngineOffer offer, bool installed) : Obse[ObservableProperty] private string _detail = "";}-/// <summary>A feature clip shown while installing.</summary>-/// <param name="Clip">avares:// URI of the light clip.</param>-/// <param name="DarkClip">The clip for dark mode, when there is one.</param>-public sealed record Showcase(string Clip, string? DarkClip, string CaptionKey);-public sealed partial class SetupViewModel : ObservableObject{- /// <summary>The feature clips (Assets/Showcase), in the order they play.</summary>- public static readonly IReadOnlyList<Showcase> Clips =- [- new("avares://Filee.Setup/Assets/Showcase/expand-640.webp", "avares://Filee.Setup/Assets/Showcase/expand-dark-640.webp", "installer.showcase.expand"),- new("avares://Filee.Setup/Assets/Showcase/flip-640.webp", null, "installer.showcase.flip"),- new("avares://Filee.Setup/Assets/Showcase/browser-640.webp", null, "installer.showcase.browser"),- ];-- /// <summary>How long each clip stays before the next one crossfades in.</summary>- public static readonly TimeSpan ClipTime = TimeSpan.FromSeconds(6);-private readonly SetupTexts _texts;private readonly ISetupRunner _runner;private readonly PreviousInstall? _previous;@@ -75,7 +60,6 @@ public sealed partial class SetupViewModel : ObservableObjectprivate readonly long _neededSpace;private bool _languagePicked;private InstallResult? _result;- private DispatcherTimer? _clipTimer;/// <param name="version">The Filee version Setup installs (or the uninstaller removes).</param>/// <param name="initial">The choices from the command line and the defaults.</param>@@ -113,6 +97,8 @@ public sealed partial class SetupViewModel : ObservableObjectUpdateEngineSelection();};}+ if (!uninstall)+ Deck = SlideDeck.Newest(SlideDeck.LoadAll("Filee.Setup"), seen: null, SlideDeck.TryParseVersion(version) ?? new Version(0, 0, 0));_page = uninstall ? SetupPage.Uninstall : SetupPage.Welcome;texts.LanguageChanged += (_, _) => RefreshTexts();RefreshTexts();@@ -129,21 +115,14 @@ public sealed partial class SetupViewModel : ObservableObject/// <summary>Fresh installs offer the engines that aren't downloaded yet.</summary>public bool HasEngines => IsFresh && Engines.Any(e => !e.Installed);- /// <summary>/SILENT: the progress card only, no clips.</summary>+ /// <summary>/SILENT: the progress card only, no slides.</summary>public bool Silent { get; set; }- /// <summary>Dark mode: the clips with a dark variant use it.</summary>- public bool Dark- {- get;- set- {- if (field == value)- return;- field = value;- OnPropertyChanged(nameof(CurrentClip));- }- }+ /// <summary>+ /// The newest "What's new" slides up to the version being installed (Assets/WhatsNew, shared with the app), shown+ /// while the files go in; null when there are none.+ /// </summary>+ public SlideDeck? Deck { get; init; }/// <summary>Raised when the window should close (finished, cancelled).</summary>public event EventHandler? CloseRequested;@@ -166,8 +145,8 @@ public sealed partial class SetupViewModel : ObservableObjectpublic bool IsUninstallPage => Page == SetupPage.Uninstall;public bool IsUninstalled => Page == SetupPage.Uninstalled;- /// <summary>The progress card plays feature clips (not for /SILENT or the uninstaller).</summary>- public bool ShowShowcase => IsProgress && !Silent && !IsUninstall;+ /// <summary>The progress card shows the "What's new" slides (not for /SILENT or the uninstaller).</summary>+ public bool ShowShowcase => IsProgress && !Silent && !IsUninstall && Deck is { Slides.Count: > 0 };[ObservableProperty] private bool _optionsOpen;[ObservableProperty] private LanguageItem _selectedLanguage;@@ -196,15 +175,6 @@ public sealed partial class SetupViewModel : ObservableObject[ObservableProperty] private string _settingsText = "";[ObservableProperty] private bool _copied;- [ObservableProperty]- [NotifyPropertyChangedFor(nameof(CurrentClip), nameof(CurrentCaption))]- private int _clipIndex;-- /// <summary>The clip playing now.</summary>- public string CurrentClip => Dark && Clips[ClipIndex].DarkClip is { } dark ? dark : Clips[ClipIndex].Clip;-- public string CurrentCaption => _texts[Clips[ClipIndex].CaptionKey];-/// <summary>The big button of the Welcome card.</summary>public string PrimaryText => _texts[IsUpdate ? "installer.update" : "installer.install"];@@ -251,22 +221,8 @@ public sealed partial class SetupViewModel : ObservableObjectpartial void OnContextMenuChanged(bool value) => OnPropertyChanged(nameof(ModernMenuEnabled));- partial void OnPageChanged(SetupPage value)- {- if (ShowShowcase)- {- ClipIndex = 0;- _clipTimer ??= new DispatcherTimer(ClipTime, DispatcherPriority.Background, (_, _) => NextClip());- _clipTimer.Start();- }- else- {- _clipTimer?.Stop();- }- }-- /// <summary>The next feature clip (every <see cref="ClipTime"/> while installing).</summary>- public void NextClip() => ClipIndex = (ClipIndex + 1) % Clips.Count;+ /// <summary>A translated text for the current language (the slides' titles and texts).</summary>+ public string Text(string key) => _texts[key];/// <summary>Recomputes the texts with arguments (after a language change).</summary>private void RefreshTexts()@@ -290,7 +246,6 @@ public sealed partial class SetupViewModel : ObservableObjectProgressTitle = _texts[IsUninstall ? "installer.uninstall.progress" : IsUpdate ? "installer.progress.update" : "installer.progress.install"];DoneTitle = _texts["installer.done.title"];OnPropertyChanged(nameof(PrimaryText));- OnPropertyChanged(nameof(CurrentCaption));}private void UpdateEngineSelection()diff --git a/src/Filee.Setup/Views/SetupWindow.axaml.cs b/src/Filee.Setup/Views/SetupWindow.axaml.csindex d3c7a370..ddaa8b7c 100644--- a/src/Filee.Setup/Views/SetupWindow.axaml.cs+++ b/src/Filee.Setup/Views/SetupWindow.axaml.cs@@ -10,6 +10,7 @@ using Avalonia.LogicalTree;using Avalonia.Media;using Avalonia.Platform.Storage;using Avalonia.Styling;+using Filee.App.Controls;using Filee.Setup.Controls;using Filee.Setup.ViewModels;@@ -98,7 +99,6 @@ public partial class SetupWindow : Windowprivate void ApplyTheme(){var dark = ActualThemeVariant == ThemeVariant.Dark;- _model.Dark = dark;// Links and the version pill: the deeper accent on light, the accent itself on dark (enough contrast on both).if (Application.Current?.FindResource(dark ? "AccentBrush" : "AccentStrongBrush") is { } link)Resources["Setup.LinkBrush"] = link;@@ -112,12 +112,6 @@ public partial class SetupWindow : Windowcase nameof(SetupViewModel.Page):ShowState();break;- case nameof(SetupViewModel.ClipIndex) or nameof(SetupViewModel.CurrentClip):- ShowClip();- break;- case nameof(SetupViewModel.CurrentCaption):- ShowCaption();- break;case nameof(SetupViewModel.OptionsOpen) when _model.OptionsOpen:LanguageBox.Focus();break;@@ -137,37 +131,29 @@ public partial class SetupWindow : Windowreturn;state.DataContext = _model;Host.Content = state;- ShowClip();- ShowCaption();+ ShowSlides();FocusPrimary();}private T? Find<T>(string name) where T : Control =>State?.GetLogicalDescendants().OfType<T>().FirstOrDefault(c => c.Name == name);- private void ShowClip()- {- if (!_model.ShowShowcase || Find<TransitioningContentControl>("ClipHost") is not { } host)- return;- if (SetupMotion.Enabled)- host.PageTransition ??= new CrossFade(TimeSpan.FromMilliseconds(600));- (host.Content as AnimatedWebp)?.Dispose();- host.Content = new AnimatedWebp { Source = _model.CurrentClip };- }-- private void ShowCaption()+ /// <summary>The "What's new" slides on the progress card, fading in at each change.</summary>+ private void ShowSlides(){- if (!_model.ShowShowcase || Find<TransitioningContentControl>("CaptionHost") is not { } host)+ if (!_model.ShowShowcase || _model.Deck is not { } deck || Find<SlideShow>("Slides") is not { } slides)return;+ slides.PlayAnimations = SetupMotion.Enabled;if (SetupMotion.Enabled)- host.PageTransition ??= new CrossFade(TimeSpan.FromMilliseconds(600));- host.Content = new TextBlock{- Text = _model.CurrentCaption,- TextWrapping = TextWrapping.Wrap,- TextAlignment = TextAlignment.Center,- Classes = { "muted" },- };+ slides.Media.Transitions = [new DoubleTransition { Property = OpacityProperty, Duration = TimeSpan.FromMilliseconds(450) }];+ slides.IndexChanged += (_, _) =>+ {+ slides.Media.Opacity = 0;+ Avalonia.Threading.Dispatcher.UIThread.Post(() => slides.Media.Opacity = 1, Avalonia.Threading.DispatcherPriority.Render);+ };+ }+ slides.Show(deck.Slides, _model.Text);}private void FocusPrimary()diff --git a/src/Filee.Setup/Views/StateViews.axaml b/src/Filee.Setup/Views/StateViews.axamlindex eb072332..41313e6d 100644--- a/src/Filee.Setup/Views/StateViews.axaml+++ b/src/Filee.Setup/Views/StateViews.axaml@@ -2,7 +2,8 @@<ResourceDictionary xmlns="https://github.com/avaloniaui"xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"xmlns:vm="using:Filee.Setup.ViewModels"- xmlns:c="using:Filee.Setup.Controls">+ xmlns:c="using:Filee.Setup.Controls"+ xmlns:shared="using:Filee.App.Controls"><!-- Welcome: the logo assembling, one big button, Options. --><DataTemplate x:Key="Setup.Welcome" x:DataType="vm:SetupViewModel">@@ -30,15 +31,11 @@</Grid></DataTemplate>- <!-- Installing (and uninstalling): feature clips, one status line, a thin bar. -->+ <!-- Installing (and uninstalling): the new version's "What's new" slides, one status line, a thin bar. --><DataTemplate x:Key="Setup.Progress" x:DataType="vm:SetupViewModel"><Grid RowDefinitions="*,Auto" Margin="32,0,32,26">- <StackPanel VerticalAlignment="Center" Spacing="12" IsVisible="{Binding ShowShowcase}">- <Border Classes="clip" Width="448" Height="252" HorizontalAlignment="Center">- <TransitioningContentControl x:Name="ClipHost" />- </Border>- <TransitioningContentControl x:Name="CaptionHost" HorizontalAlignment="Center" MaxWidth="500" Height="40" />- </StackPanel>+ <shared:SlideShow x:Name="Slides" VerticalAlignment="Center" MaxWidth="520" MediaWidth="304" MediaHeight="171"+ AutoAdvance="0:0:6" IsVisible="{Binding ShowShowcase}" /><StackPanel VerticalAlignment="Center" HorizontalAlignment="Center" Spacing="14" IsVisible="{Binding !ShowShowcase}"><c:DonutLogo Width="84" Height="84" HorizontalAlignment="Center" /><TextBlock Classes="heading" TextAlignment="Center" TextWrapping="Wrap" Text="{Binding ProgressTitle}" />diff --git a/tests/Filee.Setup.Tests/InstallerTests.cs b/tests/Filee.Setup.Tests/InstallerTests.csindex 3f21f473..5fe93add 100644--- a/tests/Filee.Setup.Tests/InstallerTests.cs+++ b/tests/Filee.Setup.Tests/InstallerTests.cs@@ -141,8 +141,8 @@ public class InstallerTestsAssert.Equal(@"%SystemRoot%\system32;" + folder + @"\cli", path);Assert.True(File.Exists(Path.Combine(bench.Paths.CommonDesktop, "Filee.lnk")));Assert.Contains($"register-menu {folder} False", bench.System.Calls);- // Back to the tray, as before the update.- Assert.Equal("--background", result.Launch!.Arguments);+ // Back to the tray, as before the update, with the new version's "What's new" slides.+ Assert.Equal("--background --whats-new", result.Launch!.Arguments);}[Fact]@@ -300,6 +300,9 @@ public class InstallerTestsAssert.Null(CommandLine.Parse(Installer.LaunchArguments(fresh with { LanguagePicked = false }, update: false).Split(' ')).Language);// Nothing picked is an answer too: Filee then doesn't ask on first run.Assert.Empty(CommandLine.Parse(Installer.LaunchArguments(fresh with { Engines = [] }, update: false).Split(' ')).InstallEngines!);- Assert.True(CommandLine.Parse(Installer.LaunchArguments(fresh, update: true).Split(' ')).Background);+ var updated = CommandLine.Parse(Installer.LaunchArguments(fresh, update: true).Split(' '));+ Assert.True(updated.Background);+ Assert.True(updated.WhatsNew);+ Assert.False(CommandLine.Parse(Installer.LaunchArguments(fresh, update: false).Split(' ')).WhatsNew);}}diff --git a/tests/Filee.Setup.Tests/SetupWindowTests.cs b/tests/Filee.Setup.Tests/SetupWindowTests.csindex 50e6bc9d..02323caf 100644--- a/tests/Filee.Setup.Tests/SetupWindowTests.cs+++ b/tests/Filee.Setup.Tests/SetupWindowTests.cs@@ -13,6 +13,7 @@ using Avalonia.Media;using Avalonia.Styling;using Avalonia.Threading;using Avalonia.VisualTree;+using Filee.App.Controls;using Filee.Setup.Controls;using Filee.Setup.Installation;using Filee.Setup.Payload;@@ -100,7 +101,9 @@ public class SetupWindowTestsAssert.True(model.IsProgress);Assert.False(model.OptionsOpen);Assert.Equal(62, model.Percent);- Assert.NotNull(window.GetVisualDescendants().OfType<AnimatedWebp>().SingleOrDefault());+ var slides = window.GetVisualDescendants().OfType<SlideShow>().Single();+ Assert.True(slides.IsEffectivelyVisible);+ Assert.Equal(model.Deck!.Slides.Count, slides.Slides.Count);Check(window, $"setup-3-installing-{language}.png");runner.Result = new InstallResult(new LaunchRequest(@"C:\Program Files\Filee\Filee.exe", "--install-engines=pandoc"),@@ -124,15 +127,13 @@ public class SetupWindowTests{var (model, _, runner) = Model(language);var window = Show(model);- Assert.True(model.Dark);+ Assert.Equal(ThemeVariant.Dark, window.ActualThemeVariant);Check(window, $"setup-dark-1-welcome-{language}.png");model.ToggleOptionsCommand.Execute(null);Check(window, $"setup-dark-2-options-{language}.png", sheetMayScroll: true);runner.Hold = new TaskCompletionSource();var install = model.InstallAsync();Pump();- // The donut clip has a dark version.- Assert.Contains("expand-dark", window.GetVisualDescendants().OfType<AnimatedWebp>().Single().Source);Check(window, $"setup-dark-3-installing-{language}.png");runner.Hold.SetResult();await install;@@ -193,48 +194,40 @@ public class SetupWindowTests}[AvaloniaFact]- public void The_clips_take_turns_with_their_captions()+ public void The_whats_new_slides_take_turns_while_installing(){var (model, texts, runner) = Model("en");+ Assert.Equal(new Version(2, 0, 0), model.Deck!.Version);var window = Show(model);runner.Hold = new TaskCompletionSource();_ = model.InstallAsync();Pump();- var seen = new HashSet<string>();- for (var i = 0; i < SetupViewModel.Clips.Count + 1; i++)+ var slides = window.GetVisualDescendants().OfType<SlideShow>().Single();+ Assert.Equal(TimeSpan.FromSeconds(6), slides.AutoAdvance);+ // Still pictures without animations (the poster frame), the texts in Setup's language.+ Assert.False(slides.PlayAnimations);+ for (var i = 0; i < slides.Slides.Count; i++){- // The clip on the card and its caption are the current ones (the 6-second timer may move on meanwhile).- var shown = window.GetVisualDescendants().OfType<AnimatedWebp>().Last().Source!;- Assert.Equal(SetupViewModel.Clips[model.ClipIndex].Clip, shown);- Assert.Equal(texts[SetupViewModel.Clips[model.ClipIndex].CaptionKey], model.CurrentCaption);- seen.Add(shown);- var before = model.ClipIndex;- model.NextClip();- Assert.Equal((before + 1) % SetupViewModel.Clips.Count, model.ClipIndex);+ Assert.Equal(i, slides.Index);+ Assert.True(slides.Media.HasPicture);+ Assert.Contains(window.GetVisualDescendants().OfType<TextBlock>(), t => t.Text == texts[slides.Slides[i].TitleKey]);+ slides.AdvanceNow();Pump();}- Assert.Equal(SetupViewModel.Clips.Count, seen.Count);+ Assert.Equal(0, slides.Index);runner.Hold.SetResult();window.Close();}[AvaloniaFact]- public void A_clip_plays_frame_after_frame()+ public void Silent_and_uninstall_show_no_slides(){- var clip = new AnimatedWebp { Source = SetupViewModel.Clips[1].Clip };- Assert.True(clip.FrameCount > 30);- var window = new Window { Content = clip, Width = 640, Height = 360 };- window.Show();- foreach (var frame in new[] { 0, 1, 2, clip.FrameCount - 1, 0 })- {- clip.ShowFrame(frame);- Assert.Equal(frame, clip.Frame);- }- // Jumping ahead decodes the frames it builds on.- clip.ShowFrame(clip.FrameCount / 2);- Assert.Equal(clip.FrameCount / 2, clip.Frame);- window.Close();- clip.Dispose();+ var (model, _, _) = Model("en");+ model.Silent = true;+ model.Page = SetupPage.Progress;+ Assert.False(model.ShowShowcase);+ var (uninstall, _, _) = Model("en", uninstall: true);+ Assert.Null(uninstall.Deck);}[AvaloniaFact]@@ -370,7 +363,15 @@ public class SetupWindowTeststext.Measure(new Size(text.Bounds.Width + text.Margin.Left + text.Margin.Right, double.PositiveInfinity));Assert.True(text.DesiredSize.Height - text.Margin.Top - text.Margin.Bottom <= text.Bounds.Height + 1, $"{name}: \"{text.Text}\" is cut off");}+ // The slides (picture, the tallest slide's text, the dots) fit in the space they get.+ foreach (var slides in state.GetVisualDescendants().OfType<SlideShow>().Where(s => s.IsEffectivelyVisible))+ {+ slides.Measure(new Size(slides.Bounds.Width, double.PositiveInfinity));+ Assert.True(slides.DesiredSize.Height <= slides.Bounds.Height + 1, $"{name}: the slides need {slides.DesiredSize.Height:0} px, they get {slides.Bounds.Height:0}");+ slides.InvalidateMeasure();+ }// Nothing may overlap the buttons at the bottom of the card.+if (state.GetVisualDescendants().OfType<Button>().FirstOrDefault(b => b.Name == "PrimaryButton" && b.IsEffectivelyVisible) is { } primary&& state is Grid { RowDefinitions.Count: 2 } grid&& grid.Children.OfType<Control>().First(c => Grid.GetRow(c) == 0 && c.IsEffectivelyVisible) is { } content