Browse Source

Merge pull request #868 from Dzhake/export-folder

Suggest document's folder when exporting
Krzysztof Krysiński 4 months ago
parent
commit
ee090a33df
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/PixiEditor/Views/Dialogs/ExportFilePopup.axaml.cs

+ 2 - 2
src/PixiEditor/Views/Dialogs/ExportFilePopup.axaml.cs

@@ -413,8 +413,8 @@ internal partial class ExportFilePopup : PixiEditorPopup
         {
             Title = new LocalizedString("EXPORT_SAVE_TITLE"),
             SuggestedFileName = SuggestedName,
-            SuggestedStartLocation =
-                await GetTopLevel(this).StorageProvider.TryGetWellKnownFolderAsync(WellKnownFolder.Documents),
+            SuggestedStartLocation = string.IsNullOrEmpty(document.FullFilePath) ? await GetTopLevel(this).StorageProvider.TryGetWellKnownFolderAsync(WellKnownFolder.Documents) : await GetTopLevel(this).StorageProvider.TryGetFolderFromPathAsync(document.FullFilePath),
+                
             FileTypeChoices =
                 SupportedFilesHelper.BuildSaveFilter(SelectedExportIndex == 1
                     ? FileTypeDialogDataSet.SetKind.Video