From e60ae4e41fea45c1b55f7a979f69658d8aaa8bc6 Mon Sep 17 00:00:00 2001 From: Hosted Weblate Date: Sun, 12 Apr 2026 18:49:45 +0200 Subject: [PATCH 01/20] i18n: translation updates from weblate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Aindriú Mac Giolla Eoin Co-authored-by: Amadɣas Co-authored-by: Aman Alam Co-authored-by: Asier Saratsua Garmendia Co-authored-by: Baurzhan Muftakhidinov Co-authored-by: ButterflyOfFire Co-authored-by: David Carvalho Co-authored-by: Ettore Atalan Co-authored-by: Fedorov Alexei Co-authored-by: Geeson Wan Co-authored-by: Hosted Weblate Co-authored-by: Jiri Grönroos Co-authored-by: Julien Brouillard Co-authored-by: Jun Hwi Ku Co-authored-by: Otto Domínguez Co-authored-by: Priit Jõerüüt Co-authored-by: Thomas Worofsky Co-authored-by: Tommi Nieminen Co-authored-by: Urocissa Caerulea.Tw Co-authored-by: VandaL Co-authored-by: Vilius Paliokas Co-authored-by: Walter William Beckerleg Bruckman Co-authored-by: Zahid Rizky Fakhri Co-authored-by: defaultUser822 Co-authored-by: jonnysemon Co-authored-by: lorduskordus Co-authored-by: taijuin Lee Co-authored-by: therealmate Co-authored-by: Димко Co-authored-by: 麋麓 BigELK176 Co-authored-by: 김유빈 Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/ar/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/cs/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/de/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/es_419/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/fi/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/fr/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/ga/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/hu/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/id/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/kab/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/kk/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/ko/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/lt/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/pa/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/pl/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/pt_BR/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/ru/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/uk/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/zh_Hans/ Translate-URL: https://hosted.weblate.org/projects/pop-os/cosmic-files/zh_Hant/ Translation: Pop OS/COSMIC Files --- i18n/ar/cosmic_files.ftl | 21 +-- i18n/cs/cosmic_files.ftl | 3 +- i18n/de/cosmic_files.ftl | 13 +- i18n/es-419/cosmic_files.ftl | 2 +- i18n/eu/cosmic_files.ftl | 0 i18n/fi/cosmic_files.ftl | 189 +++++++++++++++------ i18n/fr/cosmic_files.ftl | 1 + i18n/ga/cosmic_files.ftl | 1 + i18n/hu/cosmic_files.ftl | 1 + i18n/id/cosmic_files.ftl | 1 + i18n/kab/cosmic_files.ftl | 321 +++++++++++++++++++++++++++++++++++ i18n/kk/cosmic_files.ftl | 3 +- i18n/ko/cosmic_files.ftl | 7 +- i18n/lt/cosmic_files.ftl | 2 +- i18n/pa/cosmic_files.ftl | 14 +- i18n/pl/cosmic_files.ftl | 1 + i18n/pt-BR/cosmic_files.ftl | 7 +- i18n/ru/cosmic_files.ftl | 3 +- i18n/uk/cosmic_files.ftl | 2 +- i18n/zh-CN/cosmic_files.ftl | 27 +-- i18n/zh-TW/cosmic_files.ftl | 217 ++++++++++++++++------- 21 files changed, 684 insertions(+), 152 deletions(-) create mode 100644 i18n/eu/cosmic_files.ftl diff --git a/i18n/ar/cosmic_files.ftl b/i18n/ar/cosmic_files.ftl index f9b641d..867e83c 100644 --- a/i18n/ar/cosmic_files.ftl +++ b/i18n/ar/cosmic_files.ftl @@ -22,10 +22,10 @@ empty-trash-warning = سيتم حذف العناصر الموجودة في مج ## New File/Folder Dialog -create-new-file = إنشاء ملف جديد -create-new-folder = إنشاء مجلد جديد +create-new-file = أنشئ ملف جديد +create-new-folder = أنشئ مجلَّد جديد file-name = اسم الملف -folder-name = اسم المجلد +folder-name = اسم المجلَّد file-already-exists = يوجد ملف بهذا الاسم بالفعل folder-already-exists = يوجد مجلد بهذا الاسم بالفعل name-hidden = الاسماء التي تبدأ بنقطة «.» ستكون مخفية @@ -34,10 +34,10 @@ name-no-slashes = لا يمكن أن يحتوي الاسم على شرطات م ## Open/Save Dialog -cancel = إلغاء -open = فتح -open-file = فتح ملف -open-folder = افتح مجلد +cancel = ألغِ +open = افتح +open-file = افتح ملف +open-folder = افتح مجلَّد open-in-new-tab = افتح في لسان جديد open-in-new-window = افتح في نافذة جديدة open-multiple-files = افتح عدة ملفات @@ -150,12 +150,12 @@ trashed-on = مهمل details = التفاصيل pause = ألبث resume = استئناف -create-archive = إنشاء أرشيف +create-archive = أنشئ أرشيف extract-password-required = كلمة السر مطلوبة extract-to = استخرِج إلى... extract-to-title = استخرِج إلى مجلّد mount-error = تعذر الوصول إلى القرص -create = إنشاء +create = أنشئ open-item-location = افتح مكان العنصر set-executable-and-launch-description = أتريد تعيين «{ $name }» كقابل للتنفيذ وتشغيله؟ favorite-path-error-description = @@ -259,7 +259,7 @@ related-apps = تطبيقات ذات صلة selected-items = العناصر { $items } المحدّدة permanently-delete-question = احذف نهائيًا؟ delete = احذف -permanently-delete-warning = هل أنت متأكد من أنك تريد حذف { $target } نهائيًا؟ لا يمكن التراجع عن هذا الإجراء. +permanently-delete-warning = سيُحذف { $target } نهائيًا. لا يمكن التراجع عن هذا الإجراء. replace-warning-operation = أتريد استبداله؟ استبداله سيكتب فوق محتواه. original-file = الملف الأصلي replace-with = استبدل بـ @@ -371,3 +371,4 @@ move-to = انقل إلى... show-recents = مجلد الحديثة في الشريط الجانبي clear-recents-history = امحُ التأريخ الحديث copy-path = انسخ المسار +mixed = مختلط diff --git a/i18n/cs/cosmic_files.ftl b/i18n/cs/cosmic_files.ftl index fde9f4f..54b9e10 100644 --- a/i18n/cs/cosmic_files.ftl +++ b/i18n/cs/cosmic_files.ftl @@ -176,7 +176,7 @@ set-executable-and-launch-description = Chcete povolit spouštění souboru „{ set-and-launch = Povolit a spustit open-with = Otevřít pomocí other = Ostatní -none = Žádný +none = Žádné icon-size-and-spacing = Velikost a rozestupy ikon grid-spacing = Rozestupy mřížky deleting = @@ -417,3 +417,4 @@ move-to-title = Vyberte cíl přesunutí show-recents = Složka „Nedávné“ v postranním panelu copy-path = Kopírovat cestu clear-recents-history = Vymazat historii „Nedávné“ +mixed = Různé diff --git a/i18n/de/cosmic_files.ftl b/i18n/de/cosmic_files.ftl index c300df6..98d2f1b 100644 --- a/i18n/de/cosmic_files.ftl +++ b/i18n/de/cosmic_files.ftl @@ -330,7 +330,7 @@ light = Hell type-to-search = Zum Suchen tippen type-to-search-recursive = Durchsucht den aktuellen Ordner und alle Unterordner -type-to-search-enter-path = Gibt den Pfad zu einem Verzeichnis oder einer Datei ein +type-to-search-enter-path = Gib den Pfad zum Verzeichnis oder zur Datei ein # Kontextmenü add-to-sidebar = Zur Seitenleiste hinzufügen compress = Komprimieren... @@ -376,9 +376,9 @@ select-all = Alles auswählen ## Ansicht -zoom-in = Vergrößern +zoom-in = Hineinzoomen default-size = Standardgröße -zoom-out = Verkleinern +zoom-out = Herauszoomen view = Ansicht grid-view = Rasteransicht list-view = Listenansicht @@ -390,7 +390,7 @@ menu-about = Über COSMIC Dateien... ## Sortieren -sort = Sortieren +sort = Sortierung sort-a-z = A-Z sort-z-a = Z-A sort-newest-first = Neueste zuerst @@ -424,3 +424,8 @@ clear-recents-history = Verlauf zuletzt verwendeter Elemente leeren comment = Dateimanager für den COSMIC Desktop keywords = Ordner;Manager; move-to-button-label = Verschieben +move-to-title = Verschiebeziel auswählen +remove-from-recents = Aus den zuletzt verwendeten Elementen entfernen +move-to = Verschieben nach... +copy-path = Pfad kopieren +mixed = Gemischt diff --git a/i18n/es-419/cosmic_files.ftl b/i18n/es-419/cosmic_files.ftl index ca17ec5..9f8ef72 100644 --- a/i18n/es-419/cosmic_files.ftl +++ b/i18n/es-419/cosmic_files.ftl @@ -5,7 +5,7 @@ no-results = No se encontraron resultados filesystem = Sistema de archivos home = Inicio networks = Redes -notification-in-progress = Las operaciones de archivo están en progreso. +notification-in-progress = Las operaciones de archivo están en progreso trash = Papelera recents = Recientes undo = Deshacer diff --git a/i18n/eu/cosmic_files.ftl b/i18n/eu/cosmic_files.ftl new file mode 100644 index 0000000..e69de29 diff --git a/i18n/fi/cosmic_files.ftl b/i18n/fi/cosmic_files.ftl index 105bff6..f22b7b4 100644 --- a/i18n/fi/cosmic_files.ftl +++ b/i18n/fi/cosmic_files.ftl @@ -5,7 +5,7 @@ no-results = Ei tuloksia filesystem = Tiedostojärjestelmä home = Koti networks = Verkot -notification-in-progress = Tiedostotoimintoja käynnissä. +notification-in-progress = Tiedostotoimintoja käynnissä trash = Roskakori recents = Viimeaikaiset undo = Kumoa @@ -16,7 +16,7 @@ today = Tänään desktop-view-options = Työpöytänäkymän asetukset… show-on-desktop = Näytä työpöydällä desktop-folder-content = Työpöytäkansion sisältö -mounted-drives = Tiedostojärjestelmään liitetyt kovalevyt +mounted-drives = Liitetyt asemat trash-folder-icon = Roskakorikansion kuvake icon-size-and-spacing = Kuvakkeen koko ja välistys icon-size = Kuvakkeen koko @@ -38,7 +38,7 @@ create-archive = Luo arkisto ## Empty Trash Dialog empty-trash = Tyhjennä roskakori -empty-trash-warning = Haluatko varmasti tyhjentää koko roskakorin pysyvästi? +empty-trash-warning = Roskakorikansion kohteet poistetaan pysyvästi ## Mount Error Dialog @@ -73,8 +73,8 @@ save-file = Tallenna tiedosto ## Open With Dialog -open-with-title = Kuinka haluat avata kohteen "{ $name }"? -browse-store = Selaa { $store } +open-with-title = Miten haluat avata kohteen "{ $name }"? +browse-store = Selaa { $store }a ## Rename Dialog @@ -88,15 +88,15 @@ replace-title = "{ $filename }" on jo olemassa tässä sijainnissa replace-warning = Haluatko korvata sen tallentamallasi kohteella? Korvaaminen ylikirjoittaa kohteen sisällön. replace-warning-operation = Haluatko korvata sen? Korvaaminen ylikirjoittaa sen sisällön. original-file = Alkuperäinen tiedosto -replace-with = Korvaa kohteella -apply-to-all = Sovella kaikkiin +replace-with = Korvaa käyttäen +apply-to-all = Toteuta kaikkiin keep-both = Pidä molemmat skip = Ohita ## Set as Executable and Launch Dialog set-executable-and-launch = Aseta käynnistettäväksi ja käynnistä -set-executable-and-launch-description = Haluatko asettaa kohteen "{ $name }" käynnistettväksi ja käynnistää sen? +set-executable-and-launch-description = Haluatko asettaa kohteen "{ $name }" käynnistettäväksi ja käynnistää sen? set-and-launch = Aseta ja käynnistä ## Metadata Dialog @@ -116,9 +116,9 @@ other = Muut add-network-drive = Lisää verkkolevy connect = Yhdistä connect-anonymously = Yhdistä nimettömästi -connecting = Yhdistää… +connecting = Yhdistetään… domain = Verkkotunnus -enter-server-address = Syötä palvelimen osoite +enter-server-address = Kirjoita palvelimen osoite network-drive-description = Palvelinosoitteet sisältävät protokollaetuliitteen sekä osoitteen. Esimerkkejä: ssh://192.168.0.1, ftp://[2001:db8::1] @@ -126,91 +126,91 @@ network-drive-description = ### Make sure to keep the comma which separates the columns network-drive-schemes = - Saatavissa olevat protokollat,Etuliite + Saatavilla olevat yhteyskäytännöt,Etuliite AppleTalk,afp:// - File Transfer Protocol,ftp:// or ftps:// + File Transfer Protocol,ftp:// tai ftps:// Network File System,nfs:// Server Message Block,smb:// - SSH File Transfer Protocol,sftp:// or ssh:// - WebDav,dav:// or davs:// -network-drive-error = Verkkolevy saavuttamattomissa + SSH File Transfer Protocol,sftp:// tai ssh:// + WebDav,dav:// tai davs:// +network-drive-error = Verkkolevy ei saatavilla password = Salasana remember-password = Muista salasana try-again = Yritä uudelleen -username = Käyttäjänimi +username = Käyttäjätunnus ## Operations edit-history = Muokkaa historiaa history = Historia no-history = Historia on tyhjä. -pending = Odottaa käsittelyä -failed = Epäonnistui -complete = Valmis +pending = Jonossa +failed = Epäonnistuneet +complete = Valmiit compressing = - Tiivistetään { $items } { $items -> + Pakataan { $items } { $items -> [one] kohde - *[other] kohteita - } lähteestä "{ $from }" arkistoon "{ $to }" + *[other] kohdetta + } sijainnista "{ $from }" arkistoon "{ $to }" ({ $progress })… compressed = - Tiivistetty { $items } { $items -> + Pakattu { $items } { $items -> [one] kohde - *[other] kohteet - } lähteestä "{ $from }" arkistoon "{ $to }" + *[other] kohdetta + } sijainnista "{ $from }" arkistoon "{ $to }" copy_noun = Kopio -creating = Luodaan kohdetta "{ $name }" kohteen "{ $parent }" alle -created = Luotu kohde "{ $name }" kohteen "{ $parent }" alle +creating = Luodaan "{ $name }" kohteen "{ $parent }" alle +created = Luotu "{ $name }" kohteen "{ $parent }" alle copying = Kopioidaan { $items } { $items -> [one] kohde - *[other] kohteita - } lähteestä "{ $from }" kohteeseen "{ $to }" + *[other] kohdetta + } sijainnista "{ $from }" kohteeseen "{ $to }" ({ $progress })… copied = Kopioitu { $items } { $items -> [one] kohde - *[other] kohteet - } lähteestä "{ $from }" kohteeseen "{ $to }" -emptying-trash = Tyhjennetään { trash } + *[other] kohdetta + } sijainnista "{ $from }" kohteeseen "{ $to }" +emptying-trash = Tyhjennetään { trash } ({ $progress })… emptied-trash = Tyhjennetty { trash } extracting = Puretaan { $items } { $items -> [one] kohde - *[other] kohteet - } arkistosta "{ $from }" kohteeseen "{ $to }" + *[other] kohdetta + } arkistosta "{ $from }" kohteeseen "{ $to }" ({ $progress })… extracted = Purettu { $items } { $items -> [one] kohde - *[other] kohteet + *[other] kohdetta } arkistosta "{ $from }" kohteeseen "{ $to }" setting-executable-and-launching = Asetetaan "{ $name }" käynnistettäväksi ja käynnistetään set-executable-and-launched = Asetettu "{ $name }" käynnistettäväksi ja käynnistetty moving = Siirretään { $items } { $items -> [one] kohde - *[other] kohteet - } lähteestä "{ $from }" kohteeseen "{ $to }" + *[other] kohdetta + } sijainnista "{ $from }" kohteeseen "{ $to }" ({ $progress })… moved = Siirretty { $items } { $items -> [one] kohde - *[other] kohteet - } lähteestä "{ $from }" kohteeseen "{ $to }" + *[other] kohdetta + } sijainnista "{ $from }" kohteeseen "{ $to }" renaming = Nimetään kohde "{ $from }" muotoon "{ $to }" renamed = Nimetty kohde "{ $from }" muotoon "{ $to }" restoring = Palautetaan { $items } { $items -> [one] kohde - *[other] kohteet - } { trash }sta + *[other] kohdetta + } roskakorista ({ $progress })… restored = Palautettu { $items } { $items -> [one] kohde - *[other] kohteet - } { trash }sta -unknown-folder = Tuntematon kansio + *[other] kohdetta + } roskakorista +unknown-folder = tuntematon kansio ## Open with -menu-open-with = Avaa ohjelmalla… +menu-open-with = Avaa sovelluksella… default-app = { $name } (oletus) ## Show details @@ -225,14 +225,14 @@ settings = Asetukset appearance = Ulkoasu theme = Teema -match-desktop = Sovita yhteen työpöydän kanssa +match-desktop = Sovita työpöytään dark = Tumma light = Vaalea # Context menu add-to-sidebar = Lisää sivupalkkiin -compress = Pakkaa +compress = Pakkaa… extract-here = Pura new-file = Uusi tiedosto… new-folder = Uusi kansio… @@ -241,9 +241,9 @@ move-to-trash = Siirrä roskakoriin restore-from-trash = Palauta roskakorista remove-from-sidebar = Poista sivupalkista sort-by-name = Järjestä nimen mukaan -sort-by-modified = Järjestä muokkauspäivämäärän mukaan +sort-by-modified = Järjestä muokkausajan mukaan sort-by-size = Järjestä koon mukaan -sort-by-trashed = Järjestä poistamispäivämäärän mukaan +sort-by-trashed = Järjestä poistamisajan mukaan ## Desktop @@ -281,9 +281,9 @@ grid-view = Ruudukkonäkymä list-view = Listanäkymä show-hidden-files = Näytä piilotetut tiedostot list-directories-first = Näytä kansiot ensin -gallery-preview = Gallerian esinäkymä +gallery-preview = Gallerian esikatselu menu-settings = Asetukset… -menu-about = Tietoa COSMIC Tiedostoista… +menu-about = Tietoa COSMICin tiedostonhallinnasta… ## Sort @@ -318,3 +318,90 @@ move-to-button-label = Siirrä clear-recents-history = Tyhjennä viimeaikaisten historia copy-path = Kopioi polku dismiss = Hylkää viesti +operations-running = + { $running } { $running -> + [one] toiminto + *[other] toimintoa + } käynnissä ({ $percent } %)... +operations-running-finished = + { $running } { $running -> + [one] toiminto + *[other] toimintoa + } käynnissä ({ $percent } %), { $finished } valmistunut… +pause = Keskeytä +extract-to = Pura sijaintiin… +permanently-delete-warning = { $target } tullaan poistamaan pysyvästi. Tätä toimintoa ei voi perua. +execute-only = Vain suoritus +write-only = Vain kirjoitus +write-execute = Kirjoita ja suorita +read-only = Vain luku +read-execute = Lue ja suorita +read-write = Lue ja kirjoita +read-write-execute = Lue, kirjoita sekä suorita +calculating = Lasketaan… +single-click = Yhden napsautuksen avaus +type-to-search = Kirjoita etsiäksesi +type-to-search-recursive = Etsii nykyisestä kansiosta ja kaikista alikansioista +remove-from-recents = Poista viimeaikaisista +selected-items = { $items } valittua kohdetta +show-recents = Viimeaikaisten kansio sivupalkissa +copy-to = Kopioi… +move-to = Siirrä… +details = Yksityiskohdat +grid-spacing = Ruudukkovälit +none = Ei mitään +favorite-path-error = Virhe avattaessa kansiota +favorite-path-error-description = + Polun { $path } avaaminen ei onnistunut + "{ $path }" ei välttämättä ole olemassa tai oikeutesi eivät riitä sen avaamiseen + + Haluatko poistaa sen sivupalkista? +keep = Pidä +repository = Tietovarasto +support = Tuki +progress = { $percent } % +progress-cancelled = { $percent } %, peruttu +progress-failed = { $percent } %, epäonnistui +progress-paused = { $percent } %, keskeytetty +setting-permissions = Asetetaan kohteen "{ $name }" käyttöoikeudeksi { $mode } +set-permissions = Asetettu kohteen { $name } käyttöoikeudeksi { $mode } +permanently-deleting = + Poistetaan pysyvästi { $items } { $items -> + [one] kohde + *[other] kohdetta + } +permanently-deleted = + Poistettu pysyvästi { $items } { $items -> + [one] kohde + *[other] kohdetta + } +items = Kohteita: { $items } +item-accessed = Käytetty: { $accessed } +type-to-search-enter-path = Kirjoittaa polun kansioon tai tiedostoon +eject = Poista asemasta +copy-to-title = Valitse mihin kopioidaan +move-to-title = Valitse mihin siirretään +pasted-image = Liitetty kuva +pasted-text = Liitetty teksti +pasted-video = Liitetty video +type-to-search-select = Valitsee ensimmäisen täsmäävän tiedoston tai kansion +deleting = + Poistetaan { $items } { $items -> + [one] kohde + *[other] kohdetta + } roskakorista ({ $progress })… +deleted = + Poistettu { $items } { $items -> + [one] kohde + *[other] kohdetta + } roskakorista +removing-from-recents = + Poistetaan { $items } { $items -> + [one] kohde + *[other] kohdetta + } viimeaikaisista +removed-from-recents = + Poistettu { $items } { $items -> + [one] kohde + *[other] kohdetta + } viimeaikaisista diff --git a/i18n/fr/cosmic_files.ftl b/i18n/fr/cosmic_files.ftl index fa54fd7..a461a9f 100644 --- a/i18n/fr/cosmic_files.ftl +++ b/i18n/fr/cosmic_files.ftl @@ -436,3 +436,4 @@ keywords = Dossier;Gestionnaire; show-recents = Dossier Récents dans la barre latérale copy-path = Copier le chemin clear-recents-history = Effacer l'historique des Récents +mixed = Mixte diff --git a/i18n/ga/cosmic_files.ftl b/i18n/ga/cosmic_files.ftl index 7a9cfdf..5a9aa9a 100644 --- a/i18n/ga/cosmic_files.ftl +++ b/i18n/ga/cosmic_files.ftl @@ -433,3 +433,4 @@ keywords = Fillteán;Bainisteoir; show-recents = Fillteán le déanaí sa bharra taoibh clear-recents-history = Glan stair na n-earraí le déanaí copy-path = Cóipeáil an chosán +mixed = Measctha diff --git a/i18n/hu/cosmic_files.ftl b/i18n/hu/cosmic_files.ftl index dcf9f84..6a87c44 100644 --- a/i18n/hu/cosmic_files.ftl +++ b/i18n/hu/cosmic_files.ftl @@ -436,3 +436,4 @@ move-to = Áthelyezés ide… show-recents = Legutóbbiak mappa megjelenítése az oldalsávban copy-path = Útvonal másolása clear-recents-history = Legutóbbiak előzményének törlése +mixed = Vegyes diff --git a/i18n/id/cosmic_files.ftl b/i18n/id/cosmic_files.ftl index 9a1e8c4..2f1f21b 100644 --- a/i18n/id/cosmic_files.ftl +++ b/i18n/id/cosmic_files.ftl @@ -318,3 +318,4 @@ comment = Pengelola berkas untuk desktop COSMIC show-recents = Map terbaru di bilah sisi clear-recents-history = Bersihkan riwayat Terbaru copy-path = Salin jalur +mixed = Bercampur diff --git a/i18n/kab/cosmic_files.ftl b/i18n/kab/cosmic_files.ftl index e759fa5..233c47d 100644 --- a/i18n/kab/cosmic_files.ftl +++ b/i18n/kab/cosmic_files.ftl @@ -1 +1,322 @@ change-wallpaper = Beddel aɣrab n ugdil… +cosmic-files = Ifuyla COSMIC +empty-folder = Akaram d ilem +empty-folder-hidden = Akaram d ilem (yesɛa iferdisen yeffren) +no-results = Ulac igmaḍ yettwafen +home = Agejdan +networks = Iẓeḍwa +notification-in-progress = Timhalin ɣef ifuyla la tteddunt +trash = Iḍumman +recents = Melmi kan +undo = Ssemmet +today = Ass-a +desktop-view-options = Iɣewwaṛen n tmeẓri n tnarit… +show-on-desktop = Sken deg tnarit +desktop-folder-content = Agbur n ukaram n tnarit +trash-folder-icon = Tignit n ukaram n iḍumman +icon-size-and-spacing = Tiddi n tignit akked tallunt +icon-size = Tiddi n tignit +name = Isem +modified = Ittusnifel +trashed-on = Yettwakkes ɣer tqecwalt n yiḍumman +size = Tiddi +details = Talqayt +pause = Serǧu +resume = Kemmel +create-archive = Snulfu-d aɣbaṛ +extract-to = Ssef ɣer... +extract-to-title = Ssef ɣer ukaram +empty-trash = Silem iḍumman +rename-folder = Snifel isem n ukaram +filesystem = Anagraw n yifuyla +dismiss = Zgel izen +empty-trash-title = Silem iḍumman? +empty-trash-warning = Iferdisen n ukaram n iḍumman ad ttwakksen i lebda +create-new-file = Snulfu-d afaylu amaynut +create-new-folder = Snulfu-d akaram amaynut +file-name = Isem n ufaylu +folder-name = Isem n ukaram +file-already-exists = Afaylu s yisem-agi yella yakan +folder-already-exists = Akaram s yisem-agi yella yakan +name-hidden = Ismawen ibeddun s "." ad ttwaffren +name-invalid = Isem ur yezmir ara ad yili "{ $filename }" +cancel = Sefsex +create = Snulfu-d +open = Ldi +open-file = Ldi afaylu +open-folder = Ldi akaram +open-in-new-tab = Ldi deg yiccer amaynut +open-in-new-window = Ldi deg usfaylu amaynut +open-item-location = Ldi adig n uferdis +open-multiple-files = Ldi aget n ifuyla +mounted-drives = imeɣriyen yettuserkben +mount-error = Ulamek anekcum ɣer umeɣri +operations-running = + { $running } { $running -> + [one] n temhelt la tteddu + *[other] n temhal la tteddunt + } ({ $percent }%)... +operations-running-finished = + { $running } { $running -> + [one] n temhelt la tteddu + *[other] n temhal la tteddunt + } ({ $percent }%), { $finished } { $finished -> + [one] tfukk + *[other] fukkent + }... +copy-to-title = Fren taɣerwaḍt n unɣel +copy-to-button-label = Nɣel +move-to-title = Fren taɣerwaḍt n usmutti +move-to-button-label = Smutti +comment = Amsefrak n yifuyla i tnarit COSMIC +keywords = Akaram;Amsefrak; +delete = kkes +replace = Semselsi +support = Tallalt +settings = Iɣewwaṛen +appearance = Timeẓri +theme = Asentel +dark = Aɣmayan +light = Aceɛlal +paste = Senteḍ +select-all = Fren akk +zoom-in = Asemɣeṛ +default-size = Tiddi tamezwert +zoom-out = Asemẓi +view = Wali +menu-settings = Iɣewwaṛen… +save = Sekles +match-desktop = Amṣada d tnarit +file = Afaylu +new-window = Asfaylu amaynut +quit = Tuffɣa +edit = Ẓreg +cut = Gzem +copy = Nɣel +repository = Asarsay +pasted-image = Tettwasenṭeḍ tugna +pasted-text = Yettwasenṭeḍ uḍris +pasted-video = Tettwasenṭeḍ tvidyut +compress = Skussem… +grid-spacing = Tallunt n iẓiki +extract-password-required = Awal uffir yettwasra +permanently-delete-question = Kkes s wudem imezgi? +permanently-delete-warning = { $target } ad yettwakkes s wudem imezgi. Tigawt-agi ur tezmir ara ad tettwasefsex. +rename-file = Snifel isem n ufaylu +replace-title = "{ $filename }" yella yakan deg wadig-a +replace-warning = Tebɣiḍ ad t-tsemselsiḍ s win ara teskelseḍ? Asemselsi-ines ad yaru sennig ugbur-is. +replace-warning-operation = Tebɣiḍ ad t-tsemselsiḍ? Asemselsi-ines ad yaru sennig ugbur-is. +original-file = Afaylu aneṣli +replace-with = Semselsi s +apply-to-all = Snes i meṛṛa +keep-both = Eǧǧ-iten deg sin +skip = Zgel +set-executable-and-launch = Sbeddet am umselkam syinna senker +set-executable-and-launch-description = Tebɣiḍ ad tesbeddeḍ "{ $name }" am umselkam syinna ad tessenkreḍ? +set-and-launch = Sbadu sakin senker +add-network-drive = Rnu ameɣri n uẓeṭṭa +connect = Qqen +connect-anonymously = Qqen s wudem udrig +connecting = Tuqqna… +domain = Taɣult +enter-server-address = Sekcem tansa n uqeddac +network-drive-description = + Tansiwin n uqeddac gebrent azwir n uneggaf akked tansa. + Imedyaten: ssh://192.168.0.1, ftp://[2001:db8::1] +network-drive-error = Ur izmir ara ad yekcem ɣer umeɣri n uzeṭṭa +password = Awal uffir +remember-password = Cfu ɣef wawal uffir +try-again = ɛreḍ tikelt nniḍen +username = Isem n useqdac +cancelled = Yettwasefsex +edit-history = Ẓreg amazray +history = Amazray +no-history = Ulac iferdisen deg umazray. +pending = Yettṛaǧu +progress-cancelled = { $percent }%, yettwasefsex +progress-failed = { $percent }%, ur yeddi ara +failed = Ur yeddi ara +renaming = Asnifel n yisem "{ $from }" ɣer "{ $to }" +renamed = Yettwasenfel yisem n "{ $from }" ɣer "{ $to }" +unknown-folder = akaram arussin +menu-open-with = Ldi s… +default-app = { $name } (amezwer) +show-details = Sken talqayt +type = Anaw: { $mime } +items = Iferdisen: { $items } +item-size = Tiddi: { $size } +item-created = Yettwarna: { $created } +item-modified = Ittusnifel: { $modified } +item-accessed = Yettwakcem: { $accessed } +calculating = Asiḍen… +single-click = Asiti asuf i ulday +type-to-search = Aru iwakken ad tnadiḍ +type-to-search-recursive = Nadi akaram amiran akked ikaramen inaddawen meṛṛa +type-to-search-enter-path = Sekcem abrid ɣer ukaram neɣ afaylu +add-to-sidebar = Rnu ɣer ufeggag adisan +delete-permanently = Kkes i lebda +grid-view = Askan s iẓiki +list-view = Askan s tebdart +show-hidden-files = Sken ifuyla uffiren +gallery-preview = Taskant n temidelt +menu-about = Ɣef Ifuyla COSMIC… +sort = Asmizzwer +sort-newest-first = Amaynut d amezwaru +sort-oldest-first = Aqbur d amezwaru +sort-smallest-to-largest = Seg umeẓyan akk ɣer umeqqran +sort-largest-to-smallest = Seg umeqqran akk ɣer umeẓyan +open-multiple-folders = Ldi usgit n ikaramen +save-file = Sekles afaylu +open-with-title = Amek tebɣiḍ ad teldiḍ "{ $name }"? +browse-store = Snirem { $store } +other-apps = Isnasen-nniḍen +emptying-trash = Silem { trash } ({ $progress })… +emptied-trash = D ilem { trash } +set-permissions = Sbadu isirigen i "{ $name }" ɣer { $mode } +eject = Ḍeqqer +extract-here = Ssef +new-file = Afaylu amaynut… +new-folder = Akaram amaynut… +open-in-terminal = Ldi deg yixef +move-to-trash = Smutti ɣer tqecwalt n yiḍumman +restore-from-trash = Err-d seg tqecwalt n yiḍumman +remove-from-sidebar = Kkes seg ugalis adisan +sort-by-name = Smizzwer s yisem +sort-by-modified = Asmizzwer s usnifel +sort-by-size = Asmizzwer s tiddi +sort-by-trashed = Asmizzwer s wakud n tukksa +remove-from-recents = Kkes seg ineggura +desktop-appearance = Timeẓri n tnarit… +display-settings = Iɣewwaṛen n ubeqqeḍ... +new-tab = Iccer amaynut +reload-folder = Ales asali n ukaram +rename = Snifel isem... +close-tab = Mdel iccer +list-directories-first = Sken di tazwara ikaramen +open-with = Ldi s +owner = Bab +group = Agraw +other = Ayen nniḍen +none = Ula Yiwen +execute-only = Selkem kan +write-only = Aru kan +write-execute = Aru u selkem +read-only = I tɣuri kan +read-execute = Ɣeṛ u selkem +read-write = Ɣeṛ u aru +read-write-execute = Ɣeṛ, aru, u selkem +favorite-path-error = Tuccḍa deg ulday n ukaram +remove = Kkes +keep = Eǧǧ +progress = { $percent }% +progress-paused = { $percent }%, ibedd +complete = Immed +copy_noun = Nɣel +creating = Asnulfu n "{ $name }" deg "{ $parent }" +created = Yettwarna "{ $name }" deg "{ $parent }" +setting-executable-and-launching = Asbadu n "{ $name }" am umselkam syin ad yettwasekker +set-executable-and-launched = Sbadu "{ $name }" am umselkam syin sekker-it +setting-permissions = Asbadu n tsirag i "{ $name }" ɣer { $mode } +related-apps = Isnasen icudden +favorite-path-error-description = + Ur izmir ara ad yeldi "{ $path }" + "{ $path }" yezmer lḥal ulac-it neɣ ahat ur tesɛiḍ ara tisirag akken ad t-teldiḍ + + Tebɣiḍ ad t-tekkseḍ seg ufeggag adisan? +compressing = + La issekkussum { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg "{ $from }" ɣer "{ $to }" ({ $progress })... +compressed = + Yekussem { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg "{ $from }" ɣer "{ $to }" +copying = + Anɣal { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg "{ $from }" ɣer "{ $to }" ({ $progress })... +copied = + Yettwanɣel { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg "{ $from }" ɣer "{ $to }" +deleting = + Tukksa { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg { trash } ({ $progress })... +deleted = + Yettwakkes { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg { trash } +extracting = + Tussfa { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg "{ $from }" ɣer "{ $to }" ({ $progress })... +extracted = + Yettusef { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg "{ $from }" ɣer "{ $to }" +moving = + Asmutti { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg "{ $from }" ɣer "{ $to }" ({ $progress })... +moved = + Yettwasenkez { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg "{ $from }" ɣer "{ $to }" +permanently-deleting = + Tukksa i lebda { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } +permanently-deleted = + I lebda yettwakkes { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } +removing-from-recents = + Tukksa { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg { recents } +removed-from-recents = + Yettwakkes { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg { recents } +restoring = + Tiririt { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg { trash } ({ $progress })… +restored = + Yettwarr-d { $items } { $items -> + [one] n uferdis + *[other] n yiferdisen + } seg { trash } +network-drive-schemes = + Ineggafen iwejden, azwir + AppleTalk,afp:// + Aneggaf n usiweḍ n yifuyla,ftp:// neɣ ftps:// + Anagraw n yifuyla n uzeṭṭa,nfs:// + Iḥder n yizen n uqeddac,smb:// + SSH Aneggaf n usiweḍ n yifuyla,sftp:// neɣ ssh:// + WebDAV:// neɣ davs:// +sort-a-z = A-Ẓ +sort-z-a = Ẓ-A +selected-items = { $items } n yiferdisen yettwafernen +type-to-search-select = Fren afaylu amezwaru neɣ akaram yemṣadan +copy-to = Nɣel ɣer... +move-to = Smutti ɣer… +show-recents = Akaram n melmi kan deg ufeggag adisan +clear-recents-history = Sfeḍ azray n melmi kan +copy-path = Nɣel abrid diff --git a/i18n/kk/cosmic_files.ftl b/i18n/kk/cosmic_files.ftl index 6afb314..3b97025 100644 --- a/i18n/kk/cosmic_files.ftl +++ b/i18n/kk/cosmic_files.ftl @@ -256,7 +256,7 @@ type-to-search-recursive = Ағымдағы бума мен барлық ішк type-to-search-enter-path = Бумаға немесе файлға жолды енгізеді type-to-search-select = Бірінші сәйкес келетін файлды немесе буманы таңдайды add-to-sidebar = Бүйірлік панельге қосу -compress = Сығу +compress = Сығу... delete-permanently = Біржолата өшіру eject = Шығару extract-here = Тарқату @@ -318,3 +318,4 @@ keywords = Folder;Manager;Бума;Басқарушы; show-recents = Бүйір панеліндегі «Жуырдағы құжаттар» бумасы clear-recents-history = Жуырдағылар тарихын өшіру copy-path = Орналасқан жолын көшіру +mixed = Аралас diff --git a/i18n/ko/cosmic_files.ftl b/i18n/ko/cosmic_files.ftl index aec0e3f..3a9f2f6 100644 --- a/i18n/ko/cosmic_files.ftl +++ b/i18n/ko/cosmic_files.ftl @@ -110,7 +110,7 @@ dismiss = 메시지 무시 copy_noun = 복사 progress = { $percent }% related-apps = 관련 앱 -compress = 압축 +compress = 압축... network-drive-error = 네트워크 드라이브에 접근할 수 없음 icon-size-and-spacing = 아이콘 크기 및 간격 password = 암호 @@ -272,3 +272,8 @@ network-drive-schemes = WebDAV,dav:// 또는 davs:// type-to-search-select = 일치하는 첫 번째 파일 또는 폴더를 선택합니다 comment = COSMIC 데스크톱용 위한 파일 관리자 +keywords = 폴더;관리자; +copy-to-button-label = 복사 +move-to-button-label = 이동 +clear-recents-history = 최근 기록 비우기 +copy-path = 복사 경로 diff --git a/i18n/lt/cosmic_files.ftl b/i18n/lt/cosmic_files.ftl index 8faf6d7..acceb7c 100644 --- a/i18n/lt/cosmic_files.ftl +++ b/i18n/lt/cosmic_files.ftl @@ -252,7 +252,7 @@ type-to-search = Norint ieškoti, pradėkite rašyti type-to-search-recursive = Paieška dabartiniame aplanke ir jo poaplankiuose type-to-search-enter-path = Įvedamas aplanko ar failo kelias add-to-sidebar = Pridėti į šonjuostę -compress = Suspausti +compress = Suspausti... delete-permanently = Ištrinti visam laikui eject = Išstumti extract-here = Išskleisti diff --git a/i18n/pa/cosmic_files.ftl b/i18n/pa/cosmic_files.ftl index e5c829f..be7163e 100644 --- a/i18n/pa/cosmic_files.ftl +++ b/i18n/pa/cosmic_files.ftl @@ -32,7 +32,7 @@ pause = ਵਿਰਾਮ resume = ਮੁੜ-ਚਾਲੂ create-archive = ਅਕਾਇਵ ਬਣਾਓ extract-password-required = ਪਾਸਵਰਡ ਚਾਹੀਦਾ ਹੈ -extract-to = Extract To... +extract-to = ਖਿਲਾਰੋ... extract-to-title = ਫੋਲਡਰ ਵਿੱਚ ਖਿਲਾਰੋ empty-trash = ਰੱਦੀ ਨੂੰ ਖਾਲੀ ਕਰੋ empty-trash-title = ਰੱਦੀ ਨੂੰ ਖਾਲੀ ਕਰਨਾ ਹੈ? @@ -113,7 +113,7 @@ replace-title = "{ $filename }" ਪਹਿਲਾਂ ਹੀ ਇਸ ਟਿਕਾਣ favorite-path-error = ਡਾਇਰੈਕਟਰੀ ਖੋਲ੍ਹਣ ਦੌਰਾਨ ਗਲਤੀ add-network-drive = ਨੈੱਟਵਰਕ ਡਰਾਇਵ ਜੋੜੋ connect-anonymously = ਅਣਪਛਾਤੇ ਵਜੋਂ ਕਨੈਕਟ ਕਰੋ -connecting = Connecting... +connecting = ਕਨੈਕਟ ਕੀਤਾ ਜਾ ਰਿਹਾ ਹੈ... domain = ਡੋਮੇਨ enter-server-address = ਸਰਵਰ ਦਾ ਸਿਰਨਾਵਾਂ ਦਿਓ password = ਪਾਸਵਰਡ @@ -138,9 +138,9 @@ sort-by-modified = ਸੋਧ ਨਾਲ ਲੜੀਬੱਧ sort-by-size = ਆਕਾਰ ਨਾਲ ਲੜੀਬੱਧ sort-by-trashed = ਹਟਾਉਣ ਸਮੇਂ ਨਾਲ ਲੜੀਬੱਧ remove-from-recents = ਸੱਜਰਿਆਂ ਵਿੱਚੋਂ ਹਟਾਓ -change-wallpaper = Change wallpaper... -desktop-appearance = Desktop appearance... -display-settings = Display settings... +change-wallpaper = ਵਾਲਪੇਪਰ ਨੂੰ ਬਦਲੋ... +desktop-appearance = ਡੈਸਕਟਾਪ ਦੀ ਦਿੱਖ... +display-settings = ਡਿਸਪਲੇਅ ਸੈਟਿੰਗਾਂ... file = ਫ਼ਾਇਲ new-tab = ਨਵੀਂ ਟੈਬ new-window = ਨਵੀਂ ਵਿੰਡੋ @@ -195,11 +195,11 @@ type-to-search = ਖੋਜਣ ਲਈ ਲਿਖੋ type-to-search-recursive = ਮੌਜੂਦਾ ਫੋਲਡਰ ਅਤੇ ਸਭ ਅਧੀਨ-ਫੋਲਡਰਾਂ ਵਿੱਚ ਖੋਜੋ add-to-sidebar = ਬਾਹੀ ਵਿੱਚ ਜੋੜੋ compress = ਕੰਪਰੈਸ -copy-to = Copy to... +copy-to = ਇੱਥੇ ਕਾਪੀ ਕਰੋ... delete-permanently = ਪੱਕੇ ਤੌਰ ਉੱਤੇ ਹਟਾਓ eject = ਬਾਹਰ extract-here = ਖਿਲਾਰੋ -move-to = Move to... +move-to = ਇੱਥੇ ਭੇਜੋ... remove-from-sidebar = ਬਾਹੀ ਵਿੱਚੋਂ ਹਟਾਓ reload-folder = ਫੋਲਡਰ ਨੂੰ ਮੁੜ-ਲੋਡ ਕਰੋ list-view = ਸੂਚੀ ਝਲਕ diff --git a/i18n/pl/cosmic_files.ftl b/i18n/pl/cosmic_files.ftl index daf1007..b0bc7a8 100644 --- a/i18n/pl/cosmic_files.ftl +++ b/i18n/pl/cosmic_files.ftl @@ -437,3 +437,4 @@ move-to = Przenieś do… show-recents = Ostatnie katalogi w panelu bocznym clear-recents-history = Wyczyść bierzącą historię copy-path = Skopiuj ścieżkę +mixed = Mieszane diff --git a/i18n/pt-BR/cosmic_files.ftl b/i18n/pt-BR/cosmic_files.ftl index 732d0fb..86ebd88 100644 --- a/i18n/pt-BR/cosmic_files.ftl +++ b/i18n/pt-BR/cosmic_files.ftl @@ -424,8 +424,8 @@ sort-largest-to-smallest = Do maior para o menor empty-trash-title = Esvaziar a lixeira? type-to-search-select = Seleciona o primeiro arquivo ou pasta correspondente pasted-image = Imagem colada -pasted-text = Texto copiado -pasted-video = Vídeo copiado +pasted-text = Texto colado +pasted-video = Vídeo colado copy-to-title = Selecione o destino da cópia copy-to-button-label = Copiar move-to-title = Selecione o destino da movimentação @@ -433,6 +433,7 @@ move-to-button-label = Mover copy-to = Copiar para... move-to = Mover para... keywords = Pasta;Gerenciador; -show-recents = Pasta Recentes na barra lateral +show-recents = Pasta de recentes na barra lateral clear-recents-history = Limpar histórico de recentes copy-path = Copiar caminho +mixed = Misto diff --git a/i18n/ru/cosmic_files.ftl b/i18n/ru/cosmic_files.ftl index 15b8eb1..e9673f1 100644 --- a/i18n/ru/cosmic_files.ftl +++ b/i18n/ru/cosmic_files.ftl @@ -195,7 +195,7 @@ dark = Тёмная light = Светлая # Context menu add-to-sidebar = Добавить на боковую панель -compress = Сжать +compress = Сжать... extract-here = Распаковать new-file = Новый файл… new-folder = Новая папка… @@ -380,3 +380,4 @@ keywords = Папка;Менеджер; show-recents = «Недавние документы» в бок. панели clear-recents-history = Очистить историю недавних copy-path = Копировать путь +mixed = Смешанные diff --git a/i18n/uk/cosmic_files.ftl b/i18n/uk/cosmic_files.ftl index 1413460..611c2b1 100644 --- a/i18n/uk/cosmic_files.ftl +++ b/i18n/uk/cosmic_files.ftl @@ -317,7 +317,7 @@ single-click = Відкривати одним клацанням type-to-search = Введіть для пошуку type-to-search-recursive = Шукає у поточній теці та всіх підтеках type-to-search-enter-path = Вводить шлях до каталогу або файлу -compress = Стиснути +compress = Стиснути... delete-permanently = Остаточно видалити eject = Безпечно вилучити extract-here = Видобути diff --git a/i18n/zh-CN/cosmic_files.ftl b/i18n/zh-CN/cosmic_files.ftl index 0002c17..11441d1 100644 --- a/i18n/zh-CN/cosmic_files.ftl +++ b/i18n/zh-CN/cosmic_files.ftl @@ -11,7 +11,7 @@ recents = 最近访问 undo = 撤销 today = 今天 # Desktop view options -desktop-view-options = 桌面视图选项... +desktop-view-options = 桌面视图选项… show-on-desktop = 在桌面显示 desktop-folder-content = 桌面文件夹内容 mounted-drives = 已装载驱动器 @@ -31,7 +31,7 @@ operations-running = 正在进行 { $running } { $running -> [one] 个操作 *[other] 个操作 - }({ $percent }%)... + }({ $percent }%)… operations-running-finished = 正在进行 { $running } { $running -> [one] 个操作 @@ -50,7 +50,7 @@ create-archive = 创建压缩包 ## Extract Dialog extract-password-required = 需要密码 -extract-to = 提取到... +extract-to = 提取到… extract-to-title = 提取到文件夹 ## Empty Trash Dialog @@ -317,7 +317,7 @@ unknown-folder = 未知文件夹 ## Open with -menu-open-with = 打开方式... +menu-open-with = 打开方式… default-app = { $name }(默认) ## Show details @@ -329,7 +329,7 @@ item-size = 文件大小:{ $size } item-created = 创建于:{ $created } item-modified = 修改于:{ $modified } item-accessed = 访问于:{ $accessed } -calculating = 计算中... +calculating = 计算中… ## Settings @@ -355,8 +355,8 @@ compress = 压缩… delete-permanently = 永久删除 eject = 弹出 extract-here = 解压到此处 -new-file = 新建文件... -new-folder = 新建文件夹... +new-file = 新建文件… +new-folder = 新建文件夹… open-in-terminal = 在终端模拟器中打开 move-to-trash = 移动到回收站 restore-from-trash = 从回收站中还原 @@ -369,9 +369,9 @@ remove-from-recents = 从最近访问中移除 ## Desktop -change-wallpaper = 更改壁纸... -desktop-appearance = 桌面外观... -display-settings = 显示设置... +change-wallpaper = 更改壁纸… +desktop-appearance = 桌面外观… +display-settings = 显示设置… # Menu @@ -382,7 +382,7 @@ file = 文件 new-tab = 新建标签 new-window = 新建窗口 reload-folder = 刷新文件夹 -rename = 重命名... +rename = 重命名… close-tab = 关闭标签 quit = 退出 @@ -405,7 +405,7 @@ list-view = 列表视图 show-hidden-files = 显示隐藏文件 list-directories-first = 优先列出目录 gallery-preview = 图库预览 -menu-settings = 设置... +menu-settings = 设置… menu-about = 关于 COSMIC 文件… ## Sort @@ -435,4 +435,5 @@ comment = COSMIC 桌面的文件管理器 keywords = 文件夹;管理器; clear-recents-history = 清除最近访问历史 copy-path = 复制文件路径 -show-recents = 侧边栏显示最近访问 +show-recents = 侧边栏中的最近访问 +mixed = 混合 diff --git a/i18n/zh-TW/cosmic_files.ftl b/i18n/zh-TW/cosmic_files.ftl index 1149a62..2bf8e5b 100644 --- a/i18n/zh-TW/cosmic_files.ftl +++ b/i18n/zh-TW/cosmic_files.ftl @@ -1,11 +1,11 @@ -cosmic-files = COSMIC 檔案總管 +cosmic-files = COSMIC 檔案 empty-folder = 空資料夾 empty-folder-hidden = 空資料夾(包含隱藏項目) no-results = 找不到結果 filesystem = 檔案系統 -home = 主目錄 +home = 家目錄 networks = 網路 -notification-in-progress = 檔案操作正在進行中。 +notification-in-progress = 檔案操作正在進行中 trash = 垃圾桶 recents = 最近使用 undo = 復原 @@ -25,7 +25,7 @@ create-archive = 建立壓縮檔案 ## Empty Trash Dialog empty-trash = 清空垃圾桶 -empty-trash-warning = 你確定要永久刪除垃圾桶中的所有項目嗎? +empty-trash-warning = 垃圾桶中的項目將被永久刪除 ## New File/Folder Dialog @@ -33,16 +33,16 @@ create-new-file = 建立新檔案 create-new-folder = 建立新資料夾 file-name = 檔案名稱 folder-name = 資料夾名稱 -file-already-exists = 已存在同名檔案。 -folder-already-exists = 已存在同名資料夾。 -name-hidden = 以「.」開頭的名稱將會被隱藏。 -name-invalid = 名稱不能是 「{ $filename }」。 -name-no-slashes = 名稱不能包含斜線。 +file-already-exists = 相同名稱的檔案已經存在 +folder-already-exists = 相同名稱的資料夾已經存在 +name-hidden = 以「.」開頭的名稱將會被隱藏 +name-invalid = 名稱不能是「{ $filename }」 +name-no-slashes = 名稱不能包含斜線 ## Open/Save Dialog cancel = 取消 -create = 建立 +create = 創作 open = 開啟 open-file = 開啟檔案 open-folder = 開啟資料夾 @@ -62,12 +62,12 @@ rename-folder = 重新命名資料夾 ## Replace Dialog replace = 取代 -replace-title = 檔案「{ $filename }」已存在於此位置。 +replace-title = 「{ $filename }」已存在於此位置 replace-warning = 你要取代它嗎?取代將覆蓋其內容。 replace-warning-operation = 你要取代它嗎?取代將覆蓋其內容。 original-file = 原始檔案 replace-with = 取代為 -apply-to-all = 套用至所有項目 +apply-to-all = 套用至全部 keep-both = 保留兩者 skip = 跳過 @@ -95,13 +95,13 @@ network-drive-description = 伺服器地址包括協定前綴和地址。 範例:ssh://192.168.0.1, ftp://[2001:db8::1] network-drive-schemes = - 可用協定,前綴 - AppleTalk,afp:// - 檔案傳輸協定,ftp:// 或 ftps:// - 網路檔案系統,nfs:// - 伺服器訊息區塊,smb:// - SSH 檔案傳輸協定,sftp:// 或 ssh:// - WebDav,dav:// 或 davs:// + 可用協定,前綴 + AppleTalk,afp:// + 檔案傳輸協定,ftp:// 或 ftps:// + 網路檔案系統,nfs:// + 伺服器訊息區塊,smb:// + SSH 檔案傳輸協定,sftp:// 或 ssh:// + WebDav,dav:// 或 davs:// network-drive-error = 無法存取網路磁碟機 password = 密碼 remember-password = 記住密碼 @@ -112,7 +112,7 @@ username = 使用者名稱 edit-history = 編輯歷史 history = 歷史紀錄 -no-history = 沒有歷史項目。 +no-history = 無歷史記錄項目。 pending = 待處理 failed = 失敗 complete = 完成 @@ -133,51 +133,51 @@ copying = 正在複製 { $items } { $items -> [one] 項目 *[other] 項目 - } 從「{ $from }」到「{ $to }」({ $progress })... + }從「{ $from }」到「{ $to }」({ $progress })... copied = 已複製 { $items } { $items -> [one] 項目 *[other] 項目 }從「{ $from }」到「{ $to }」 -emptying-trash = 正在清空{ trash }({ $progress })… -emptied-trash = 已清空{ trash } +emptying-trash = 正在清空 { trash }({ $progress })… +emptied-trash = 已經清空 { trash } extracting = 正在解壓縮 { $items } 項目 { $items -> [one] 項目 *[other] 項目 - } 從「{ $from }」到「{ $to }」({ $progress })... + }從「{ $from }」至「{ $to }」({ $progress })... extracted = 已解壓縮 { $items } 項目 { $items -> [one] 項目 *[other] 項目 - } 從 { $from } 到 { $to } + }從「{ $from }」到「{ $to }」 moving = 正在移動 { $items } { $items -> [one] 項目 *[other] 項目 - } 從「{ $from }」到「{ $to }」({ $progress })... + }從「{ $from }」到「{ $to }」({ $progress })... moved = - 已移動 { $items } { $items -> + 已經移動 { $items } { $items -> [one] 項目 *[other] 項目 - } 從「{ $from }」到「{ $to }」 -renaming = 正在重新命名「{ $from }」為「{ $to }」 -renamed = 已重新命名 { $from } 為 { $to } + } 從「{ $from }」至「{ $to }」 +renaming = 正在重新命名「{ $from }」至「{ $to }」 +renamed = 已經重新命名「{ $from }」至「{ $to }」 restoring = 正在還原 { $items } 項目 { $items -> [one] 項目 *[other] 項目 - } 從{ trash }({ $progress })... + }自 { trash } ({ $progress })... restored = - 已還原 { $items } 項目 { $items -> + 已經還原 { $items } 項目 { $items -> [one] 項目 *[other] 項目 - } 從{ trash } -unknown-folder = 未知資料夾 + }從 { trash } +unknown-folder = 不明資料夾 ## Open with -menu-open-with = 開啟方式... +menu-open-with = 開啟檔案... default-app = { $name } (預設) ## Show details @@ -192,15 +192,15 @@ settings = 設定 appearance = 外觀 theme = 主題 -match-desktop = 與桌面一致 -dark = 暗色模式 -light = 亮色模式 +match-desktop = 符合桌面 +dark = 深色 +light = 淺色 # Context menu -add-to-sidebar = 加入側邊欄 -compress = 壓縮 -extract-here = 解壓縮至此 -new-file = 新檔案... -new-folder = 新資料夾... +add-to-sidebar = 添加至側邊欄 +compress = 壓縮… +extract-here = 解壓縮 +new-file = 新建檔案... +new-folder = 新建資料夾... open-in-terminal = 在終端機中開啟 move-to-trash = 移動至垃圾桶 restore-from-trash = 從垃圾桶還原 @@ -215,8 +215,8 @@ sort-by-size = 依大小排序 ## File file = 檔案 -new-tab = 新分頁 -new-window = 新視窗 +new-tab = 新建分頁 +new-window = 新建視窗 rename = 重新命名... close-tab = 關閉分頁 quit = 退出 @@ -238,36 +238,36 @@ view = 檢視 grid-view = 網格檢視 list-view = 列表檢視 show-hidden-files = 顯示隱藏檔案 -list-directories-first = 優先列出目錄 +list-directories-first = 目錄優先列出 menu-settings = 設定... -menu-about = 關於 COSMIC 檔案總管... +menu-about = 關於 COSMIC 檔案... ## Sort sort = 排序 sort-a-z = A-Z sort-z-a = Z-A -sort-newest-first = 最新的在前 -sort-oldest-first = 最舊的在前 -sort-smallest-to-largest = 由小至大 -sort-largest-to-smallest = 由大至小 +sort-newest-first = 最新優先 +sort-oldest-first = 最舊優先 +sort-smallest-to-largest = 從小到大 +sort-largest-to-smallest = 從大到小 deleted = - 已刪除 { $items } { $items -> + 已經刪除 { $items } { $items -> [one] 項目 *[other] 項目 - }從{ trash } + }從 { trash } permanently-deleting = 正在永久刪除 { $items } { $items -> [one] 项目 *[other] 项目 } permanently-deleted = - 已永久刪除 { $items } { $items -> + 已經永久刪除 { $items } { $items -> [one] 项目 *[other] 项目 } removing-from-recents = - 正在從{ recents }中移除 { $items } { $items -> + 正在從 { recents } 中移除 { $items } { $items -> [one] 项目 *[other] 项目 } @@ -275,9 +275,112 @@ deleting = 正在刪除 { $items } { $items -> [one] 项目 *[other] 项目 - }從{ trash }({ $progress })… + }從 { trash }({ $progress })… removed-from-recents = - 已從{ recents }中移除 { $items } { $items -> + 已經從 { recents } 中移除 { $items } { $items -> [one] 项目 *[other] 项目 } +repository = 軟體庫源 +desktop-view-options = 桌面檢視選項... +show-on-desktop = 顯示在桌面 +desktop-folder-content = 桌面資料夾內容 +mounted-drives = 已經掛載的磁碟機 +trash-folder-icon = 垃圾桶圖示 +trashed-on = 遺棄時間 +icon-size-and-spacing = 圖示大小與間距 +icon-size = 圖示大小 +grid-spacing = 網格間距 +details = 詳情 +dismiss = 撤停訊息 +delete = 刪除 +remove = 移除 +support = 支援 +cancelled = 已取消 +keywords = 資料夾;管理器; +empty-trash-title = 清空垃圾桶? +pause = 暫停 +resume = 繼續 +extract-password-required = 需要密碼 +extract-to = 解壓縮至... +extract-to-title = 解壓縮至資料夾 +mount-error = 無法存取磁碟機 +open-with-title = 您要如何開啟「{ $name }」? +browse-store = 瀏覽 { $store } +other-apps = 其他應用程式 +related-apps = 相關應用程式 +permanently-delete-question = 永久刪除? +set-executable-and-launch = 設定為可以執行並啟動 +read-only = 唯讀 +read-execute = 讀取和執行 +read-write = 讀取和寫入 +read-write-execute = 讀取、寫入和執行 +favorite-path-error = 開啟目錄時發生錯誤 +set-executable-and-launch-description = 您是否要將「{ $name }」設為可執行並啟動它? +set-and-launch = 設定並啟動 +none = 無 +execute-only = 僅執行 +write-only = 僅寫入 +write-execute = 寫入和執行 +operations-running = + { $running } { $running -> + [one] 個操作 + *[other] 個操作 + }正在執行({ $percent }%)... +operations-running-finished = + { $running } { $running -> + [one] 個操作 + *[other] 個操作 + }正在執行({ $percent }%), { $finished } 個已經完成... +permanently-delete-warning = 「{ $target }」將被永久刪除。此操作無法復原。 +open-with = 開啟檔案 +selected-items = 已經選定 { $items } 個項目 +copy-to-title = 選擇複製目的地 +copy-to-button-label = 複製 +move-to-title = 選擇移動目的地 +move-to-button-label = 移動 +keep = 保留 +progress = { $percent }% +progress-cancelled = { $percent }%,已經取消 +progress-failed = { $percent }%,失敗 +progress-paused = { $percent }%,已經暫停 +favorite-path-error-description = + 無法開啟「{ $path }」 + 「{ $path }」可能不存在,或您可能沒有權限開啟它。 + + 您是否要將它從側邊欄移除? +comment = COSMIC 桌面檔案管理器 +pasted-image = 已經貼上的圖片 +pasted-text = 已經貼上的文字 +pasted-video = 已經貼上的影片 +sort-by-trashed = 依丟入時間排序 +calculating = 計算中... +single-click = 點按以開啟 +type-to-search = 輸入進行搜尋 +type-to-search-recursive = 搜尋目前資料夾及全部子資料夾 +type-to-search-enter-path = 輸入目錄或檔案的路徑 +delete-permanently = 永久刪除 +eject = 彈出 +remove-from-recents = 從最近項目中移除 +change-wallpaper = 變更桌布... +desktop-appearance = 桌面外觀... +display-settings = 顯示設定... +reload-folder = 重新載入資料夾 +gallery-preview = 圖庫預覽 +type = 類型:{ $mime } +items = 項目:{ $items } +item-size = 大小:{ $size } +item-created = 建立時間:{ $created } +item-modified = 修改時間:{ $modified } +item-accessed = 存取時間:{ $accessed } +type-to-search-select = 選取第一個符合條件的檔案或資料夾 +copy-to = 複製至... +move-to = 移動至... +show-recents = 側邊欄中的最近使用資料夾 +clear-recents-history = 清除最近使用歷史記錄 +copy-path = 複製路徑 +setting-executable-and-launching = 設定「{ $name }」為可以執行並進行啟動 +set-executable-and-launched = 設定「{ $name }」為可以執行並已經啟動 +setting-permissions = 設定「{ $name }」的權限至 { $mode } +set-permissions = 設定「{ $name }」的權限至 { $mode } +mixed = 混合 From fc25260a5ffbb1ce55408ac03f0372f93c3fdcf8 Mon Sep 17 00:00:00 2001 From: Hojjat Date: Mon, 6 Apr 2026 23:14:06 -0600 Subject: [PATCH 02/20] feat: select file name until the extension in rename and save dialog --- Cargo.lock | 98 +++++++++++++++++++++++++++------------------------ src/app.rs | 15 ++++++-- src/dialog.rs | 11 ++++++ 3 files changed, 75 insertions(+), 49 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f89c7f4..97505bf 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1317,7 +1317,7 @@ dependencies = [ [[package]] name = "cosmic-config" version = "1.0.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "atomicwrites", "cosmic-config-derive", @@ -1338,7 +1338,7 @@ dependencies = [ [[package]] name = "cosmic-config-derive" version = "1.0.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "quote", "syn", @@ -1479,7 +1479,7 @@ dependencies = [ [[package]] name = "cosmic-text" version = "0.18.2" -source = "git+https://github.com/pop-os/cosmic-text.git#9a2ab09f06905e91f41d64ac6eee887726e7fd76" +source = "git+https://github.com/pop-os/cosmic-text.git#4d74f795cc771fdcc7ea0f9cacba63fcf036fad6" dependencies = [ "bitflags 2.11.0", "fontdb", @@ -1502,7 +1502,7 @@ dependencies = [ [[package]] name = "cosmic-theme" version = "1.0.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "almost", "configparser", @@ -2365,7 +2365,7 @@ version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fc6d3a3635983a889f065aa9ce760384713f23a9b4a04f696f86c39a5d7a6a5a" dependencies = [ - "indexmap 2.13.1", + "indexmap 2.14.0", "nom 8.0.0", ] @@ -2584,9 +2584,9 @@ dependencies = [ [[package]] name = "gif" -version = "0.14.1" +version = "0.14.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5df2ba84018d80c213569363bdcd0c64e6933c67fe4c1d60ecf822971a3c35e" +checksum = "ee8cfcc411d9adbbaba82fb72661cc1bcca13e8bba98b364e62b2dba8f960159" dependencies = [ "color_quant", "weezl", @@ -2850,6 +2850,12 @@ dependencies = [ "foldhash 0.2.0", ] +[[package]] +name = "hashbrown" +version = "0.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4f467dd6dccf739c208452f8014c75c18bb8301b050ad1cfb27153803edb0f51" + [[package]] name = "heck" version = "0.4.1" @@ -2983,7 +2989,7 @@ dependencies = [ [[package]] name = "iced" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "dnd", "iced_accessibility", @@ -3004,7 +3010,7 @@ dependencies = [ [[package]] name = "iced_accessibility" version = "0.1.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "accesskit", "accesskit_winit", @@ -3013,7 +3019,7 @@ dependencies = [ [[package]] name = "iced_core" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "bitflags 2.11.0", "bytes", @@ -3037,7 +3043,7 @@ dependencies = [ [[package]] name = "iced_debug" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "iced_core", "iced_futures", @@ -3047,7 +3053,7 @@ dependencies = [ [[package]] name = "iced_futures" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "futures", "iced_core", @@ -3061,7 +3067,7 @@ dependencies = [ [[package]] name = "iced_graphics" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "bitflags 2.11.0", "bytemuck", @@ -3082,7 +3088,7 @@ dependencies = [ [[package]] name = "iced_program" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "iced_graphics", "iced_runtime", @@ -3091,7 +3097,7 @@ dependencies = [ [[package]] name = "iced_renderer" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "iced_graphics", "iced_tiny_skia", @@ -3103,7 +3109,7 @@ dependencies = [ [[package]] name = "iced_runtime" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "bytes", "cosmic-client-toolkit", @@ -3118,7 +3124,7 @@ dependencies = [ [[package]] name = "iced_tiny_skia" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "bytemuck", "cosmic-text", @@ -3135,7 +3141,7 @@ dependencies = [ [[package]] name = "iced_wgpu" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "as-raw-xcb-connection", "bitflags 2.11.0", @@ -3166,7 +3172,7 @@ dependencies = [ [[package]] name = "iced_widget" version = "0.14.2" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "cosmic-client-toolkit", "dnd", @@ -3184,7 +3190,7 @@ dependencies = [ [[package]] name = "iced_winit" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "cosmic-client-toolkit", "cursor-icon", @@ -3671,7 +3677,7 @@ dependencies = [ "byteorder-lite", "color_quant", "exr", - "gif 0.14.1", + "gif 0.14.2", "image-webp", "moxcms", "num-traits", @@ -3720,12 +3726,12 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.13.1" +version = "2.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "45a8a2b9cb3e0b0c1803dbb0758ffac5de2f425b23c28f518faabd9d805342ff" +checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9" dependencies = [ "equivalent", - "hashbrown 0.16.1", + "hashbrown 0.17.0", "serde", "serde_core", ] @@ -4297,7 +4303,7 @@ checksum = "48f5d2a454e16a5ea0f4ced81bd44e4cfc7bd3a507b61887c99fd3538b28e4af" [[package]] name = "libcosmic" version = "1.0.0" -source = "git+https://github.com/pop-os/libcosmic.git#a44cff8011d81209e18de86f24da248c88b5a28d" +source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" dependencies = [ "apply", "ashpd 0.12.3", @@ -4374,14 +4380,14 @@ checksum = "b6d2cec3eae94f9f509c767b45932f1ada8350c4bdb85af2fcab4a3c14807981" [[package]] name = "libredox" -version = "0.1.15" +version = "0.1.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ddbf48fd451246b1f8c2610bd3b4ac0cc6e149d89832867093ab69a17194f08" +checksum = "e02f3bb43d335493c96bf3fd3a321600bf6bd07ed34bc64118e9293bdffea46c" dependencies = [ "bitflags 2.11.0", "libc", "plain", - "redox_syscall 0.7.3", + "redox_syscall 0.7.4", ] [[package]] @@ -4728,7 +4734,7 @@ dependencies = [ "half", "hashbrown 0.16.1", "hexf-parse", - "indexmap 2.13.1", + "indexmap 2.14.0", "libm", "log", "num-traits", @@ -5234,11 +5240,11 @@ dependencies = [ [[package]] name = "ordermap" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cfa78c92071bbd3628c22b1a964f7e0eb201dc1456555db072beb1662ecd6715" +checksum = "7f7476a5b122ff1fce7208e7ee9dccd0a516e835f5b8b19b8f3c98a34cf757c1" dependencies = [ - "indexmap 2.13.1", + "indexmap 2.14.0", "serde", "serde_core", ] @@ -5992,9 +5998,9 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.7.3" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ce70a74e890531977d37e532c34d45e9055d2409ed08ddba14529471ed0be16" +checksum = "f450ad9c3b1da563fb6948a8e0fb0fb9269711c9c73d9ea1de5058c79c8d643a" dependencies = [ "bitflags 2.11.0", ] @@ -6370,7 +6376,7 @@ version = "1.0.149" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "83fc039473c5595ace860d8c4fafa220ff474b3fc6bfdb4293327f1a37e94d86" dependencies = [ - "indexmap 2.13.1", + "indexmap 2.14.0", "itoa", "memchr", "serde", @@ -6408,7 +6414,7 @@ dependencies = [ "chrono", "hex", "indexmap 1.9.3", - "indexmap 2.13.1", + "indexmap 2.14.0", "schemars 0.9.0", "schemars 1.2.1", "serde_core", @@ -7107,7 +7113,7 @@ version = "1.1.2+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "81f3d15e84cbcd896376e6730314d59fb5a87f31e4b038454184435cd57defee" dependencies = [ - "indexmap 2.13.1", + "indexmap 2.14.0", "serde_core", "serde_spanned", "toml_datetime", @@ -7131,7 +7137,7 @@ version = "0.25.11+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0b59c4d22ed448339746c59b905d24568fcbb3ab65a500494f7b8c3e97739f2b" dependencies = [ - "indexmap 2.13.1", + "indexmap 2.14.0", "toml_datetime", "toml_parser", "winnow 1.0.1", @@ -7598,7 +7604,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bb0e353e6a2fbdc176932bbaab493762eb1255a7900fe0fea1a2f96c296cc909" dependencies = [ "anyhow", - "indexmap 2.13.1", + "indexmap 2.14.0", "wasm-encoder", "wasmparser", ] @@ -7611,7 +7617,7 @@ checksum = "47b807c72e1bac69382b3a6fb3dbe8ea4c0ed87ff5629b8685ae6b9a611028fe" dependencies = [ "bitflags 2.11.0", "hashbrown 0.15.5", - "indexmap 2.13.1", + "indexmap 2.14.0", "semver", ] @@ -7848,7 +7854,7 @@ dependencies = [ "cfg_aliases", "document-features", "hashbrown 0.16.1", - "indexmap 2.13.1", + "indexmap 2.14.0", "log", "naga", "once_cell", @@ -8615,7 +8621,7 @@ dependencies = [ "libredox", "orbclient", "raw-window-handle", - "redox_syscall 0.7.3", + "redox_syscall 0.7.4", "smol_str", "tracing", "winit-core", @@ -8774,7 +8780,7 @@ checksum = "b7c566e0f4b284dd6561c786d9cb0142da491f46a9fbed79ea69cdad5db17f21" dependencies = [ "anyhow", "heck 0.5.0", - "indexmap 2.13.1", + "indexmap 2.14.0", "prettyplease", "syn", "wasm-metadata", @@ -8805,7 +8811,7 @@ checksum = "9d66ea20e9553b30172b5e831994e35fbde2d165325bec84fc43dbf6f4eb9cb2" dependencies = [ "anyhow", "bitflags 2.11.0", - "indexmap 2.13.1", + "indexmap 2.14.0", "log", "serde", "serde_derive", @@ -8824,7 +8830,7 @@ checksum = "ecc8ac4bc1dc3381b7f59c34f00b67e18f910c2c0f50015669dde7def656a736" dependencies = [ "anyhow", "id-arena", - "indexmap 2.13.1", + "indexmap 2.14.0", "log", "semver", "serde", @@ -9323,7 +9329,7 @@ dependencies = [ "flate2", "getrandom 0.4.2", "hmac", - "indexmap 2.13.1", + "indexmap 2.14.0", "lzma-rust2", "memchr", "pbkdf2", diff --git a/src/app.rs b/src/app.rs index 254827b..ace9cb1 100644 --- a/src/app.rs +++ b/src/app.rs @@ -4218,12 +4218,14 @@ impl Application for App { .collect(); if !selected.is_empty() { //TODO: batch rename - let tasks = selected + let mut last_name = String::new(); + let tasks: Vec<_> = selected .into_iter() .filter_map(|path| { let parent = path.parent()?.to_path_buf(); let name = path.file_name()?.to_str()?.to_string(); let dir = path.is_dir(); + last_name = name.clone(); Some(self.dialog_pages.push_back(DialogPage::RenameItem { from: path, parent, @@ -4231,9 +4233,15 @@ impl Application for App { dir, })) }) - .chain(std::iter::once(widget::text_input::focus( + .collect(); + let tasks = tasks.into_iter().chain([ + widget::text_input::focus(self.dialog_text_input.clone()), + widget::text_input::select_until_last( self.dialog_text_input.clone(), - ))); + &last_name, + '.', + ), + ]); return Task::batch(tasks); } } @@ -6102,6 +6110,7 @@ impl Application for App { .into(), widget::text_input("", name.as_str()) .id(self.dialog_text_input.clone()) + .double_click_select_delimiter('.') .on_input(move |name| { Message::DialogUpdate(DialogPage::RenameItem { from: from.clone(), diff --git a/src/dialog.rs b/src/dialog.rs index 0ed4474..f9894ac 100644 --- a/src/dialog.rs +++ b/src/dialog.rs @@ -600,6 +600,7 @@ impl App { col = col.push( widget::text_input("", filename) .id(self.filename_id.clone()) + .double_click_select_delimiter('.') .on_input(Message::Filename) .on_submit(|_| Message::Save(false)), ); @@ -1962,6 +1963,16 @@ impl Application for App { if self.search_get().is_some() { return widget::text_input::focus(self.search_id.clone()); } + if let DialogKind::SaveFile { filename } = &self.flags.kind { + return Task::batch([ + widget::text_input::focus(self.filename_id.clone()), + widget::text_input::select_until_last( + self.filename_id.clone(), + filename, + '.', + ), + ]); + } return widget::text_input::focus(self.filename_id.clone()); } } From c114759c9ed4164939914c6eae61b4567377a73c Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Fri, 10 Apr 2026 05:48:58 +0200 Subject: [PATCH 03/20] chore: use tracing for structured logs --- Cargo.toml | 3 ++- src/lib.rs | 34 ++++++++++++++++++++++++++++++++-- 2 files changed, 34 insertions(+), 3 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 8be8b9a..1b90a4a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -14,7 +14,6 @@ icu = { version = "2.1.1", features = ["compiled_data"] } cctk = { git = "https://github.com/pop-os/cosmic-protocols", package = "cosmic-client-toolkit", rev = "160b086", optional = true } cosmic-mime-apps = { git = "https://github.com/pop-os/cosmic-mime-apps.git", optional = true } dirs = "6.0.0" -env_logger = "0.11" gio = { version = "0.21", optional = true } glib = { version = "0.21", optional = true } glob = "0.3" @@ -62,6 +61,8 @@ png = "0.18" jxl-oxide = { version = "0.12.5", features = ["image"] } num_cpus = "1.17.0" filetime = "0.2" +tracing = "0.1.44" +tracing-subscriber = { version = "0.3.22", features = ["env-filter"] } # Completion-based IO runtime to enable io_uring / IOCP file IO support. [dependencies.compio] diff --git a/src/lib.rs b/src/lib.rs index cc0bcc1..b4c85c7 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -3,6 +3,7 @@ use cosmic::{app::Settings, iced::Limits}; use std::{env, fs, path::PathBuf, process}; +use tracing_subscriber::{layer::SubscriberExt, util::SubscriberInitExt}; use app::{App, Flags}; pub mod app; @@ -73,7 +74,22 @@ pub fn is_wayland() -> bool { /// Runs application in desktop mode #[rustfmt::skip] pub fn desktop() -> Result<(), Box> { - env_logger::Builder::from_env(env_logger::Env::default().default_filter_or("warn")).init(); + let log_format = tracing_subscriber::fmt::format() + .pretty() + .without_time() + .with_line_number(true) + .with_file(true) + .with_target(false) + .with_thread_names(true); + + let log_layer = tracing_subscriber::fmt::Layer::default() + .with_writer(std::io::stderr) + .event_format(log_format); + + tracing_subscriber::registry() + .with(tracing_subscriber::EnvFilter::from_env("RUST_LOG")) + .with(log_layer) + .init(); localize::localize(); @@ -108,7 +124,21 @@ pub fn desktop() -> Result<(), Box> { /// Runs application with these settings #[rustfmt::skip] pub fn main() -> Result<(), Box> { - env_logger::Builder::from_env(env_logger::Env::default().default_filter_or("warn")).init(); + let log_format = tracing_subscriber::fmt::format() + .pretty() + .with_line_number(true) + .with_file(true) + .with_target(false) + .with_thread_names(true); + + let log_layer = tracing_subscriber::fmt::Layer::default() + .with_writer(std::io::stderr) + .event_format(log_format); + + tracing_subscriber::registry() + .with(tracing_subscriber::EnvFilter::from_env("RUST_LOG")) + .with(log_layer) + .init(); localize::localize(); From b299f1a172388e73f0c3405f82b08ca4d3cc8884 Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Fri, 10 Apr 2026 05:57:34 +0200 Subject: [PATCH 04/20] chore: add methods to `Controller` to pause and unpause futures - Use `Controller::until_paused` as a signal in a select to pause futures - Use `Controller::until_unpaused` to block futures in a select loop --- src/operation/controller.rs | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/src/operation/controller.rs b/src/operation/controller.rs index f4b26fe..960a28d 100644 --- a/src/operation/controller.rs +++ b/src/operation/controller.rs @@ -86,6 +86,35 @@ impl Controller { self.set_state(ControllerState::Paused); } + /// Returns when the state is paused. + /// + /// Use this to pause futures. + pub async fn until_paused(&self) { + loop { + if matches!(self.state(), ControllerState::Paused) { + return; + } + + self.inner.notify.notified().await; + } + } + + /// Returns when state is neither paused, cancelled, nor failed. + /// + /// Use this to resume futures. + pub async fn until_unpaused(&self) { + loop { + if !matches!( + self.state(), + ControllerState::Paused | ControllerState::Cancelled | ControllerState::Failed + ) { + return; + } + + self.inner.notify.notified().await; + } + } + pub fn unpause(&self) { if !self.is_cancelled() | !self.is_failed() { self.set_state(ControllerState::Running); From e2bdcf8da4df1cdb2a4d707ed52a14b04eb4c0ff Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Fri, 10 Apr 2026 06:03:16 +0200 Subject: [PATCH 05/20] fix: use gio file copy fallback to fix MTP unsupported I/O errors --- Cargo.toml | 1 + src/operation/recursive.rs | 441 ++++++++++++++++++++++++++----------- 2 files changed, 311 insertions(+), 131 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 1b90a4a..9447640 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -63,6 +63,7 @@ num_cpus = "1.17.0" filetime = "0.2" tracing = "0.1.44" tracing-subscriber = { version = "0.3.22", features = ["env-filter"] } +thiserror = "2.0.18" # Completion-based IO runtime to enable io_uring / IOCP file IO support. [dependencies.compio] diff --git a/src/operation/recursive.rs b/src/operation/recursive.rs index 61c4841..befe69c 100644 --- a/src/operation/recursive.rs +++ b/src/operation/recursive.rs @@ -1,15 +1,31 @@ -use compio::BufResult; -use compio::buf::{IntoInner, IoBuf}; -use compio::io::{AsyncReadAt, AsyncWriteAt}; -use std::future::Future; -use std::pin::Pin; -use std::time::Instant; -use std::{cell::Cell, error::Error, fs, ops::ControlFlow, path::PathBuf, rc::Rc}; -use walkdir::WalkDir; - -use crate::operation::{OperationError, sync_to_disk}; +// Copyright 2023 System76 +// SPDX-License-Identifier: GPL-3.0-only use super::{Controller, OperationSelection, ReplaceResult, copy_unique_path}; +use crate::operation::{OperationError, sync_to_disk}; +use anyhow::Context as AnyhowContext; +use compio::BufResult; +use compio::buf::{IntoInner, IoBuf}; +use compio::driver::{ToSharedFd, op::AsyncifyFd}; +use compio::io::{AsyncReadAt, AsyncWriteAt}; +use cosmic::iced::futures; +use futures::future::Either; +use futures::{FutureExt, StreamExt}; +use gio::prelude::FileExtManual; +use std::future::Future; +use std::pin::Pin; +use std::rc::Rc; +use std::time::Instant; +use std::{cell::Cell, error::Error, fs, ops::ControlFlow, path::PathBuf}; +use walkdir::WalkDir; + +#[derive(thiserror::Error, Debug)] +pub enum GioCopyError { + #[error("controller state")] + Controller(OperationError), + #[error("gio copy failed")] + GLib(#[from] glib::Error), +} pub enum Method { Copy, @@ -313,136 +329,26 @@ impl Op { }) } - async fn run( - &mut self, - ctx: &mut Context, - mut progress: Progress, - ) -> Result> { + async fn run(&mut self, ctx: &mut Context, progress: Progress) -> Result> { if self.skipped.normal.get() || (self.is_cleanup && self.skipped.cleanup.get()) { return Ok(true); } match self.kind { OpKind::Copy => { - // Remove `to` if overwriting and it is an existing file - if self.to.is_file() { - match ctx.replace(self).await? { - ControlFlow::Continue(to) => { - self.to = to; - } - ControlFlow::Break(ret) => { - return Ok(ret); - } - } + let result = self.copy(ctx, progress).await; + + if result.is_err() { + _ = compio::fs::remove_file(&self.to).await; } - let (from_file, metadata, mut to_file) = cosmic::iced::futures::try_join!( - async { - compio::fs::OpenOptions::new() - .read(true) - .open(&self.from) - .await - }, - compio::fs::metadata(&self.from), - // This is atomic and ensures `to` is not created by any other process - async { - compio::fs::OpenOptions::new() - .create_new(true) - .write(true) - .open(&self.to) - .await - } - )?; - - progress.total_bytes = Some(metadata.len()); - (ctx.on_progress)(self, &progress); - if let Err(err) = to_file.set_permissions(metadata.permissions()).await { - // This error is not propagated upwards as some filesystems do not support setting permissions - log::warn!( - "failed to set permissions for {}: {}", - self.to.display(), - err - ); - } - - // Prevent spamming the progress callbacks. - let mut last_progress_update = Instant::now(); - // io_uring/IOCP requires transferring ownership of the buffer to the kernel. - let mut buf_in = std::mem::take(&mut ctx.buf); - // Track where the current read/write position is at. - let mut pos = 0; - - loop { - let BufResult(result, buf_out) = from_file.read_at(buf_in, pos).await; - - let count = match result { - Ok(0) => { - ctx.buf = buf_out; - break; - } - Ok(count) => count, - Err(why) => { - ctx.buf = buf_out; - return Err(why.into()); - } - }; - - let BufResult(result, buf_out_slice) = - to_file.write_at(buf_out.slice(..count), pos).await; - let buf_out = buf_out_slice.into_inner(); - - if let Err(why) = result { - ctx.buf = buf_out; - return Err(why.into()); - } - - progress.current_bytes += count as u64; - pos += count as u64; - - // Avoid spamming progress messages too early. - let current = Instant::now(); - if current.duration_since(last_progress_update).as_millis() > 49 { - last_progress_update = current; - (ctx.on_progress)(self, &progress); - - // Also check if the progress was cancelled. - if let Err(state) = ctx.controller.check().await { - ctx.buf = buf_out; - return Err(OperationError::from_state(state, &ctx.controller).into()); - } - } - - buf_in = buf_out; - } - - let mut times = fs::FileTimes::new(); - { - use std::os::unix::prelude::MetadataExt; - log::info!("{}", metadata.mtime()); - } - if let Ok(time) = metadata.modified() { - times = times.set_modified(time); - } - if let Ok(time) = metadata.accessed() { - times = times.set_accessed(time); - } - //TODO: upstream set_times implementation to compio? - { - use compio::driver::{ToSharedFd, op::AsyncifyFd}; - let op = - AsyncifyFd::new(to_file.to_shared_fd(), move |file: &std::fs::File| { - BufResult(file.set_times(times).map(|_| 0), ()) - }); - match compio::runtime::submit(op).await.0.map(|_| ()) { - Ok(()) => { - log::info!("set times for {} to {:?}", self.to.display(), times); - } - Err(err) => { - log::warn!("failed to set times for {}: {}", self.to.display(), err); - } - } - } + return result; } OpKind::Move { cross_device_copy } => { + // Do not clean up if cross_device_copy is set + if cross_device_copy { + self.skipped.cleanup.set(true); + } + // Remove `to` if overwriting and it is an existing file if self.to.is_file() { match ctx.replace(self).await? { @@ -520,4 +426,277 @@ impl Op { } Ok(true) } + + async fn copy( + &mut self, + ctx: &mut Context, + mut progress: Progress, + ) -> Result> { + // Remove `to` if overwriting and it is an existing file + if self.to.is_file() { + match ctx.replace(self).await? { + ControlFlow::Continue(to) => { + self.to = to; + } + ControlFlow::Break(ret) => { + return Ok(ret); + } + } + } + + let (from_file, metadata, to_file) = cosmic::iced::futures::join!( + async { + compio::fs::OpenOptions::new() + .read(true) + .open(&self.from) + .await + .with_context(|| format!("failed to open {} for reading", self.from.display(),)) + }, + async { compio::fs::metadata(&self.from).await.ok() }, + // This is atomic and ensures `to` is not created by any other process + async { + compio::fs::OpenOptions::new() + .create_new(true) + .write(true) + .open(&self.to) + .await + .with_context(|| format!("failed to open {} for writing", self.to.display())) + } + ); + + let from_file = from_file?; + let mut to_file = to_file?; + progress.total_bytes = metadata.as_ref().map(|m| m.len()); + (ctx.on_progress)(self, &progress); + + if let Some(metadata) = metadata.as_ref() { + if let Err(why) = to_file.set_permissions(metadata.permissions()).await { + // This error is not propagated upwards as some filesystems do not support setting permissions + if !matches!(why.kind(), std::io::ErrorKind::Unsupported) { + tracing::warn!(?why, "failed to set permissions for {}", self.to.display(),); + } + } + } + + // Prevent spamming the progress callbacks. + let mut last_progress_update = Instant::now(); + // io_uring/IOCP requires transferring ownership of the buffer to the kernel. + let mut buf_in = std::mem::take(&mut ctx.buf); + // Track where the current read/write position is at. + let mut pos = 0; + + loop { + let BufResult(result, buf_out) = from_file.read_at(buf_in, pos).await; + + let count = match result { + Ok(0) => { + buf_in = buf_out; + break; + } + Ok(count) => count, + Err(why) => { + ctx.buf = buf_out; + tracing::error!("failed to read: {:?}", why); + _ = futures::future::join(from_file.close(), to_file.close()).await; + return Err(why).context("failed to read")?; + } + }; + + let BufResult(result, buf_out_slice) = + to_file.write_at(buf_out.slice(..count), pos).await; + let buf_out = buf_out_slice.into_inner(); + + if let Err(why) = result { + if let std::io::ErrorKind::Unsupported = why.kind() { + ctx.buf = buf_out; + _ = futures::future::join(from_file.close(), to_file.close()).await; + return self + .gio_file_copy(ctx, progress) + .await + .map(|_| true) + .map_err(Into::into); + } + + tracing::error!("failed to write: {:?}", why); + ctx.buf = buf_out; + _ = futures::future::join(from_file.close(), to_file.close()).await; + return Err(why).context("failed to write")?; + } + + progress.current_bytes += count as u64; + pos += count as u64; + + // Avoid spamming progress messages too early. + let current = Instant::now(); + if current.duration_since(last_progress_update).as_millis() > 49 { + last_progress_update = current; + (ctx.on_progress)(self, &progress); + + // Also check if the progress was cancelled. + if let Err(state) = ctx.controller.check().await { + ctx.buf = buf_out; + tracing::warn!( + "operation to copy from {:?} to {:?} cancelled", + self.from, + self.to + ); + _ = futures::future::join(from_file.close(), to_file.close()).await; + return Err(OperationError::from_state(state, &ctx.controller).into()); + } + } + + buf_in = buf_out; + } + + ctx.buf = buf_in; + + if let Some(metadata) = metadata.as_ref() { + let mut times = fs::FileTimes::new(); + if let Ok(time) = metadata.modified() { + times = times.set_modified(time); + } + if let Ok(time) = metadata.accessed() { + times = times.set_accessed(time); + } + //TODO: upstream set_times implementation to compio? + let op = AsyncifyFd::new(to_file.to_shared_fd(), move |file: &std::fs::File| { + BufResult(file.set_times(times).map(|_| 0), ()) + }); + match compio::runtime::submit(op).await.0.map(|_| ()) { + Ok(()) => { + tracing::info!("set times for {} to {:?}", self.to.display(), times); + } + Err(why) => { + if !matches!(why.kind(), std::io::ErrorKind::Unsupported) { + tracing::error!(?why, "failed to set times for {}", self.to.display()); + } + } + } + } + + _ = to_file.close().await; + + Ok(true) + } + + /// Fallback mechanism in the event that unsupported I/O error errors occur. + /// Fixes unsupported errors when copying large files over MTP. + /// TODO: Find what Gio.File does to work around this. + async fn gio_file_copy( + &self, + ctx: &mut Context, + mut progress: Progress, + ) -> Result<(), GioCopyError> { + _ = compio::fs::remove_file(&self.to).await; + + let from = gio::File::for_path(&self.from); + let to = gio::File::for_path(&self.to); + let (progress_tx, mut progress_rx) = tokio::sync::mpsc::unbounded_channel(); + let (tx, rx) = tokio::sync::oneshot::channel(); + let (pause_tx, mut pause_rx) = tokio::sync::watch::channel(false); + + let task = compio::runtime::spawn_blocking(move || { + let glib_context = glib::MainContext::new(); + let glib_loop = glib::MainLoop::new(Some(&glib_context), false); + glib_context.with_thread_default(move || { + let glib_loop2 = glib_loop.clone(); + glib::MainContext::ref_thread_default().spawn_local(async move { + // Create a future for copying the file with `gio::File`. This also creates a progress stream. + let (gio_copy_fut, mut progress_stream) = from.copy_future( + &to, + gio::FileCopyFlags::OVERWRITE | gio::FileCopyFlags::ALL_METADATA, + glib::Priority::LOW, + ); + + let mut copy_fut = + gio_copy_fut.map(|result| result.map_err(GioCopyError::GLib)); + + let mut progress_fut = std::pin::pin!(async { + while let Some((current_bytes, _)) = progress_stream.next().await { + _ = progress_tx.send(current_bytes); + } + + drop(progress_tx); + futures::future::pending::<()>().await; + }); + + // Poll the progress future while waiting for the copy future to finish. + let mut main_fut = std::pin::pin!(async { + loop { + if let Either::Right((result, _)) = + futures::future::select(&mut progress_fut, &mut copy_fut).await + { + return result; + } + } + }); + + let mut pause_rx2 = pause_rx.clone(); + + loop { + let until_paused = std::pin::pin!(pause_rx.wait_for(|paused| *paused)); + match futures::future::select(until_paused, &mut main_fut).await { + Either::Left(_) => { + _ = pause_rx2.wait_for(|paused| !*paused).await; + } + + Either::Right((result, _)) => { + _ = tx.send(result.map(|_| ())); + glib_loop2.quit(); + return; + } + } + } + }); + + glib_loop.run(); + }) + }); + + let mut last_progress_update = Instant::now(); + let mut task = task.fuse(); + let mut rx = rx.fuse(); + + loop { + let until_paused = std::pin::pin!(ctx.controller.until_paused()); + + futures::select! { + value = progress_rx.recv().fuse() => { + if let Some(current_bytes) = value { + progress.current_bytes = current_bytes as u64; + let current = Instant::now(); + if current.duration_since(last_progress_update).as_millis() > 49 { + last_progress_update = current; + (ctx.on_progress)(self, &progress); + + tracing::info!("checking controller"); + + // Also check if the progress was cancelled. + if let Err(state) = ctx.controller.check().await { + tracing::warn!( + "operation to copy from {:?} to {:?} cancelled", + self.from, + self.to + ); + return Err::<(), GioCopyError>(GioCopyError::Controller( + OperationError::from_state(state, &ctx.controller), + )); + } + } + } + } + + result = rx => return result.unwrap(), + + _ = task => (), + + _ = until_paused.fuse() => { + // Pauses an active copy while the controller state is paused. + _ = pause_tx.send(true); + ctx.controller.until_unpaused().await; + _ = pause_tx.send(false); + } + } + } + } } From bb15f30fe5adcea4df8418adf867ba8bea876ae2 Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Fri, 10 Apr 2026 15:49:04 +0200 Subject: [PATCH 06/20] chore: update Cargo.lock --- Cargo.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f89c7f4..55dead6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1354,7 +1354,6 @@ dependencies = [ "cosmic-client-toolkit", "cosmic-mime-apps", "dirs 6.0.0", - "env_logger", "fastrand", "filetime", "flate2", @@ -1394,8 +1393,11 @@ dependencies = [ "tar", "tempfile", "test-log", + "thiserror 2.0.18", "tikv-jemallocator", "tokio", + "tracing", + "tracing-subscriber", "trash", "url", "uzers", @@ -1963,7 +1965,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "32e90c2accc4b07a8456ea0debdc2e7587bdd890680d71173a15d4ae604f6eef" dependencies = [ "log", - "regex", ] [[package]] @@ -1975,7 +1976,6 @@ dependencies = [ "anstream", "anstyle", "env_filter", - "jiff", "log", ] From 93dd775f3c6452ec8b82998d002b7351085c70a5 Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Tue, 14 Apr 2026 16:23:10 +0200 Subject: [PATCH 07/20] perf: get image dimensions from background thread This caused the tab subscription to block the tokio executor. Instead store the image dimensions in the `Item`, which is created on a background thread. --- src/mounter/gvfs.rs | 1 + src/tab.rs | 15 ++++++++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/src/mounter/gvfs.rs b/src/mounter/gvfs.rs index cd4ea68..8ac42dc 100644 --- a/src/mounter/gvfs.rs +++ b/src/mounter/gvfs.rs @@ -199,6 +199,7 @@ fn network_scan(uri: &str, sizes: IconSizes) -> Result, String> { metadata, hidden, location_opt: Some(location), + image_dimensions: None, mime, icon_handle_grid, icon_handle_list, diff --git a/src/tab.rs b/src/tab.rs index b0b3a34..1e63588 100644 --- a/src/tab.rs +++ b/src/tab.rs @@ -708,6 +708,9 @@ pub fn item_from_gvfs_info(path: PathBuf, file_info: gio::FileInfo, sizes: IconS children_opt, }, hidden, + image_dimensions: (!remote && mime.type_() == mime::IMAGE) + .then(|| image::image_dimensions(&path).ok()) + .flatten(), location_opt: Some(Location::Path(path)), mime, icon_handle_grid, @@ -843,6 +846,7 @@ pub fn item_from_entry( }, hidden, location_opt: Some(Location::Path(path)), + image_dimensions: None, mime, icon_handle_grid, icon_handle_list, @@ -896,6 +900,9 @@ pub fn item_from_trash_entry( metadata: ItemMetadata::Trash { metadata, entry }, hidden: false, location_opt: None, + image_dimensions: (mime.type_() == mime::IMAGE) + .then(|| image::image_dimensions(&original_path).ok()) + .flatten(), mime, icon_handle_grid, icon_handle_list, @@ -1444,6 +1451,7 @@ pub fn scan_desktop( metadata, hidden: false, location_opt: Some(Location::Trash), + image_dimensions: None, mime, icon_handle_grid, icon_handle_list, @@ -2319,6 +2327,7 @@ pub struct Item { pub hidden: bool, pub location_opt: Option, pub mime: Mime, + pub image_dimensions: Option<(u32, u32)>, pub icon_handle_grid: widget::icon::Handle, pub icon_handle_list: widget::icon::Handle, pub icon_handle_list_condensed: widget::icon::Handle, @@ -6713,13 +6722,13 @@ impl Tab { // Determine effective memory budget based on image size let (effective_max_mb, effective_jobs) = if mime.type_() == mime::IMAGE { - match image::image_dimensions(&path) { - Ok((width, height)) => { + match item.image_dimensions { + Some((width, height)) => { let (_use_dedicated, eff_mb, eff_jobs) = should_use_dedicated_worker(width, height, max_mb, max_jobs); (eff_mb, eff_jobs) } - Err(_) => (max_mb, max_jobs), + None => (max_mb, max_jobs), } } else { (max_mb, max_jobs) From 971374f60ba701cb2a8728985c9d2742c590b036 Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Tue, 14 Apr 2026 16:27:53 +0200 Subject: [PATCH 08/20] perf: use atomics for controller progress and state --- Cargo.lock | 8 ++++++++ Cargo.toml | 2 ++ src/operation/controller.rs | 29 +++++++++++++++++++---------- 3 files changed, 29 insertions(+), 10 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 55dead6..9a0d3f9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -538,6 +538,12 @@ version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" +[[package]] +name = "atomic_float" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "628d228f918ac3b82fe590352cc719d30664a0c13ca3a60266fe02c7132d480a" + [[package]] name = "atomicwrites" version = "0.4.2" @@ -1349,6 +1355,7 @@ name = "cosmic-files" version = "1.0.9" dependencies = [ "anyhow", + "atomic_float", "bzip2", "compio", "cosmic-client-toolkit", @@ -1378,6 +1385,7 @@ dependencies = [ "notify-debouncer-full", "notify-rust", "num_cpus", + "num_enum", "open", "ordermap", "paste", diff --git a/Cargo.toml b/Cargo.toml index 9447640..74e554b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -64,6 +64,8 @@ filetime = "0.2" tracing = "0.1.44" tracing-subscriber = { version = "0.3.22", features = ["env-filter"] } thiserror = "2.0.18" +atomic_float = "1.1.0" +num_enum = "0.7.6" # Completion-based IO runtime to enable io_uring / IOCP file IO support. [dependencies.compio] diff --git a/src/operation/controller.rs b/src/operation/controller.rs index 960a28d..691316c 100644 --- a/src/operation/controller.rs +++ b/src/operation/controller.rs @@ -1,7 +1,11 @@ -use std::sync::{Arc, Mutex}; +use atomic_float::AtomicF32; +use num_enum::{IntoPrimitive, TryFromPrimitive}; +use std::sync::Arc; +use std::sync::atomic::{self, AtomicU16}; use tokio::sync::Notify; -#[derive(Clone, Copy, Debug, PartialEq, Eq)] +#[derive(Clone, Copy, Debug, PartialEq, Eq, IntoPrimitive, TryFromPrimitive)] +#[repr(u16)] pub enum ControllerState { Cancelled, Failed, @@ -11,8 +15,8 @@ pub enum ControllerState { #[derive(Debug)] struct ControllerInner { - state: Mutex, - progress: Mutex, + state: AtomicU16, + progress: AtomicF32, notify: Notify, } @@ -27,8 +31,8 @@ impl Default for Controller { Self { primary: true, inner: Arc::new(ControllerInner { - state: Mutex::new(ControllerState::Running), - progress: Mutex::new(0.0), + state: AtomicU16::new(ControllerState::Running.into()), + progress: AtomicF32::new(0.0), notify: Notify::new(), }), } @@ -50,19 +54,24 @@ impl Controller { } pub fn progress(&self) -> f32 { - *self.inner.progress.lock().unwrap() + self.inner.progress.load(atomic::Ordering::Relaxed) } pub fn set_progress(&self, progress: f32) { - *self.inner.progress.lock().unwrap() = progress; + self.inner + .progress + .swap(progress, atomic::Ordering::Relaxed); } pub fn state(&self) -> ControllerState { - *self.inner.state.lock().unwrap() + ControllerState::try_from(self.inner.state.load(atomic::Ordering::Relaxed)) + .unwrap_or(ControllerState::Failed) } pub fn set_state(&self, state: ControllerState) { - *self.inner.state.lock().unwrap() = state; + self.inner + .state + .store(state.into(), atomic::Ordering::Relaxed); self.inner.notify.notify_waiters(); } From e35d5123f05bdd0ca2c06d0a3a60a04e0cb324ee Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Tue, 14 Apr 2026 16:38:56 +0200 Subject: [PATCH 09/20] perf: avoid holding async mutex guards across await points tokio recommends using a sync mutex with a notifier instead of the async mutex where possible. Rust forbids holding a sync mutex guard across await points so we can prevent a potential deadlock this way. This adds a custom channel based on the tokio mpmc example for handling gvfs events from callbacks to avoid the async mutex requirement. Messages are held in a `VecDeque` behind a sync mutex and the receiver will get notified via the notifier when a message is added to the queue. Weak references used in gio callbacks in case the sender is dropped by the application. --- src/app.rs | 5 +-- src/channel.rs | 77 +++++++++++++++++++++++++++++++++++++++++++++ src/lib.rs | 3 +- src/mounter/gvfs.rs | 70 +++++++++++++++++++++++++++++------------ src/tab.rs | 23 ++++++-------- 5 files changed, 139 insertions(+), 39 deletions(-) create mode 100644 src/channel.rs diff --git a/src/app.rs b/src/app.rs index 19dc54d..a427065 100644 --- a/src/app.rs +++ b/src/app.rs @@ -6958,8 +6958,7 @@ impl Application for App { |_| { stream::channel( 1, - move |msg_tx: futures::channel::mpsc::Sender<_>| async move { - let msg_tx = Arc::new(tokio::sync::Mutex::new(msg_tx)); + move |mut msg_tx: futures::channel::mpsc::Sender<_>| async move { tokio::task::spawn_blocking(move || { match notify_rust::Notification::new() .summary(&fl!("notification-in-progress")) @@ -6969,8 +6968,6 @@ impl Application for App { Ok(notification) => { let _ = futures::executor::block_on(async { msg_tx - .lock() - .await .send(Message::Notification(Arc::new( Mutex::new(notification), ))) diff --git a/src/channel.rs b/src/channel.rs new file mode 100644 index 0000000..e91bc35 --- /dev/null +++ b/src/channel.rs @@ -0,0 +1,77 @@ +// Copyright 2025 System76 +// SPDX-License-Identifier: MPL-2.0 + +use std::{ + collections::VecDeque, + sync::{ + Arc, Mutex, + atomic::{AtomicBool, Ordering}, + }, +}; + +/// Create a channel backed by `tokio::sync::Notify` and a sync mutex with a vec deque. +pub fn channel() -> (Sender, Receiver) { + let channel = Arc::new(Channel { + queue: Mutex::new(VecDeque::default()), + notify: tokio::sync::Notify::const_new(), + closed: AtomicBool::new(false), + }); + + (Sender(channel.clone()), Receiver(channel)) +} + +/// A channel backed by `tokio::sync::Notify` and a sync mutex with a vec deque. +struct Channel { + pub(self) queue: Mutex>, + /// Set when a new message has been stored. + pub(self) notify: tokio::sync::Notify, + /// Set when the receiver is dropped. + pub(self) closed: AtomicBool, +} + +pub struct Sender(Arc>); + +impl Sender { + pub fn send(&self, message: Message) { + self.0.queue.lock().unwrap().push_back(message); + self.0.notify.notify_one(); + } +} + +impl Drop for Sender { + fn drop(&mut self) { + self.0.closed.store(true, Ordering::SeqCst); + self.0.notify.notify_one(); + } +} + +pub struct Receiver(Arc>); + +impl Receiver { + /// Returns a value until the sender is dropped. + pub async fn recv(&self) -> Option { + loop { + { + let mut queue = self.0.queue.lock().unwrap(); + if let Some(value) = queue.pop_front() { + if queue.capacity() - queue.len() > 32 { + let capacity = queue.len().next_power_of_two(); + queue.shrink_to(capacity); + } + drop(queue); + return Some(value); + } + } + + if self.0.closed.load(Ordering::SeqCst) { + return None; + } + + self.0.notify.notified().await; + } + } + + pub fn try_recv(&self) -> Option { + self.0.queue.lock().unwrap().pop_front() + } +} diff --git a/src/lib.rs b/src/lib.rs index b4c85c7..9214a7f 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -8,6 +8,7 @@ use tracing_subscriber::{layer::SubscriberExt, util::SubscriberInitExt}; use app::{App, Flags}; pub mod app; mod archive; +pub mod channel; pub mod clipboard; mod context_action; use config::Config; @@ -136,7 +137,7 @@ pub fn main() -> Result<(), Box> { .event_format(log_format); tracing_subscriber::registry() - .with(tracing_subscriber::EnvFilter::from_env("RUST_LOG")) + .with(tracing_subscriber::EnvFilter::from_default_env()) .with(log_layer) .init(); diff --git a/src/mounter/gvfs.rs b/src/mounter/gvfs.rs index 8ac42dc..d6294b6 100644 --- a/src/mounter/gvfs.rs +++ b/src/mounter/gvfs.rs @@ -5,7 +5,7 @@ use cosmic::{ }; use gio::{glib, prelude::*}; use std::{any::TypeId, cell::Cell, future::pending, hash::Hash, path::PathBuf, sync::Arc}; -use tokio::sync::{Mutex, mpsc}; +use tokio::sync::mpsc; use super::{Mounter, MounterAuth, MounterItem, MounterItems, MounterMessage}; use crate::{ @@ -230,7 +230,10 @@ fn dir_info(uri: &str) -> Result<(String, String, Option), glib::Error> Ok((resolved_uri, info.display_name().into(), file.path())) } -fn mount_op(uri: String, event_tx: mpsc::UnboundedSender) -> gio::MountOperation { +fn mount_op( + uri: String, + event_tx: std::sync::Weak>, +) -> gio::MountOperation { let mount_op = gio::MountOperation::new(); mount_op.connect_ask_password( move |mount_op, message, default_user, default_domain, flags| { @@ -253,9 +256,9 @@ fn mount_op(uri: String, event_tx: mpsc::UnboundedSender) -> gio::MountOp .then_some(false), }; let (auth_tx, mut auth_rx) = mpsc::channel(1); - event_tx - .send(Event::NetworkAuth(uri.clone(), auth, auth_tx)) - .unwrap(); + if let Some(event_tx) = event_tx.upgrade() { + event_tx.send(Event::NetworkAuth(uri.clone(), auth, auth_tx)); + } //TODO: async recv? if let Some(auth) = auth_rx.blocking_recv() { if auth.anonymous_opt == Some(true) { @@ -358,37 +361,45 @@ impl Item { pub struct Gvfs { command_tx: mpsc::UnboundedSender, - event_rx: Arc>>, + event_rx: Arc>, } impl Gvfs { pub fn new() -> Self { //TODO: switch to using gvfs-zbus which will better integrate with async rust let (command_tx, mut command_rx) = mpsc::unbounded_channel(); - let (event_tx, event_rx) = mpsc::unbounded_channel(); + let (event_tx, event_rx) = crate::channel::channel(); + let event_tx = Arc::new(event_tx); std::thread::spawn(move || { let main_loop = glib::MainLoop::new(None, false); main_loop.context().spawn_local(async move { + let event_tx = Arc::downgrade(&event_tx); let monitor = gio::VolumeMonitor::get(); { let event_tx = event_tx.clone(); monitor.connect_mount_changed(move |_monitor, mount| { log::info!("mount changed {}", MountExt::name(mount)); - event_tx.send(Event::Changed).unwrap(); + if let Some(event_tx) = event_tx.upgrade() { + event_tx.send(Event::Changed); + } }); } { let event_tx = event_tx.clone(); monitor.connect_mount_added(move |_monitor, mount| { log::info!("mount added {}", MountExt::name(mount)); - event_tx.send(Event::Changed).unwrap(); + if let Some(event_tx) = event_tx.upgrade() { + event_tx.send(Event::Changed); + } }); } { let event_tx = event_tx.clone(); monitor.connect_mount_removed(move |_monitor, mount| { log::info!("mount removed {}", MountExt::name(mount)); - event_tx.send(Event::Changed).unwrap(); + if let Some(event_tx) = event_tx.upgrade() { + event_tx.send(Event::Changed); + } }); } @@ -396,21 +407,27 @@ impl Gvfs { let event_tx = event_tx.clone(); monitor.connect_volume_changed(move |_monitor, volume| { log::info!("volume changed {}", VolumeExt::name(volume)); - event_tx.send(Event::Changed).unwrap(); + if let Some(event_tx) = event_tx.upgrade() { + event_tx.send(Event::Changed); + } }); } { let event_tx = event_tx.clone(); monitor.connect_volume_added(move |_monitor, volume| { log::info!("volume added {}", VolumeExt::name(volume)); - event_tx.send(Event::Changed).unwrap(); + if let Some(event_tx) = event_tx.upgrade() { + event_tx.send(Event::Changed); + } }); } { let event_tx = event_tx.clone(); monitor.connect_volume_removed(move |_monitor, volume| { log::info!("volume removed {}", VolumeExt::name(volume)); - event_tx.send(Event::Changed).unwrap(); + if let Some(event_tx) = event_tx.upgrade() { + event_tx.send(Event::Changed); + } }); } @@ -420,7 +437,11 @@ impl Gvfs { items_tx.send(items(&monitor, sizes)).await.unwrap(); } Cmd::Rescan => { - event_tx.send(Event::Items(items(&monitor, IconSizes::default()))).unwrap(); + let Some(event_tx) = event_tx.upgrade() else { + return; + }; + + event_tx.send(Event::Items(items(&monitor, IconSizes::default()))); } Cmd::Mount(mounter_item, complete_tx) => { let MounterItem::Gvfs(ref item) = mounter_item else { @@ -472,6 +493,9 @@ impl Gvfs { .ok().map(|info| info.boolean(gio::FILE_ATTRIBUTE_FILESYSTEM_REMOTE)) .unwrap_or(true); } + let Some(event_tx) = event_tx.upgrade() else { + return; + }; event_tx.send(Event::MountResult(updated_item, match res { Ok(()) => { _ = complete_tx.send(Ok(())); @@ -483,7 +507,7 @@ impl Gvfs { Some(gio::IOErrorEnum::FailedHandled) => Ok(false), _ => Err(format!("{err}")) }} - })).unwrap(); + })); }, ); break; @@ -499,6 +523,9 @@ impl Gvfs { gio::Cancellable::NONE, move |res| { log::info!("network drive {uri}: result {res:?}"); + let Some(event_tx) = event_tx.upgrade() else { + return; + }; event_tx.send(Event::NetworkResult(uri, match res { Ok(()) => { _ = result_tx.send(Ok(())); @@ -509,7 +536,7 @@ impl Gvfs { Some(gio::IOErrorEnum::FailedHandled) => Ok(false), _ => Err(format!("{err}")) }} - })).unwrap(); + })); } ); } @@ -533,6 +560,9 @@ impl Gvfs { // FIXME sometimes a uri can be mounted and then not recognized as mounted... // seems to be related to uri with a path items_tx.blocking_send(network_scan(&uri, sizes)).unwrap(); + let Some(event_tx) = event_tx.upgrade() else { + return; + }; event_tx.send(Event::NetworkResult(resolved_uri, match res { Ok(()) => { Ok(true) @@ -541,7 +571,7 @@ impl Gvfs { Some(gio::IOErrorEnum::FailedHandled) => Ok(false), _ => Err(format!("{err}")) } - })).unwrap(); + })); } ); } else { @@ -597,7 +627,7 @@ impl Gvfs { }); Self { command_tx, - event_rx: Arc::new(Mutex::new(event_rx)), + event_rx: Arc::new(event_rx), } } } @@ -671,7 +701,7 @@ impl Mounter for Gvfs { let event_rx = self.event_rx.clone(); struct Wrapper { command_tx: mpsc::UnboundedSender, - event_rx: Arc>>, + event_rx: Arc>, } impl Hash for Wrapper { fn hash(&self, state: &mut H) { @@ -695,7 +725,7 @@ impl Mounter for Gvfs { MounterMessage, >| async move { command_tx.send(Cmd::Rescan).unwrap(); - while let Some(event) = event_rx.lock().await.recv().await { + while let Some(event) = event_rx.recv().await { match event { Event::Changed => command_tx.send(Cmd::Rescan).unwrap(), Event::Items(items) => { diff --git a/src/tab.rs b/src/tab.rs index 1e63588..a0f95a0 100644 --- a/src/tab.rs +++ b/src/tab.rs @@ -6955,9 +6955,8 @@ impl Tab { .await .unwrap(); - let output = Arc::new(tokio::sync::Mutex::new(output)); + let (watch_tx, mut watch_rx) = tokio::sync::watch::channel(true); { - let output = output.clone(); tokio::task::spawn_blocking(move || { scan_search( &search_location, @@ -6985,14 +6984,7 @@ impl Tab { true } else { // Wake up update method - futures::executor::block_on(async { - output - .lock() - .await - .send(Message::SearchReady(false)) - .await - }) - .is_ok() + watch_tx.send(false).is_ok() } } Err(_) => false, @@ -7005,13 +6997,16 @@ impl Tab { search_location, start.elapsed(), ); - }) - .await - .unwrap(); + }); + } + + while watch_rx.changed().await.is_ok() { + let is_ready = *watch_rx.borrow_and_update(); + let _ = output.send(Message::SearchReady(is_ready)).await; } // Send final ready - let _ = output.lock().await.send(Message::SearchReady(true)).await; + let _ = output.send(Message::SearchReady(true)).await; std::future::pending().await }, From 0bd20e57e7d9023f4372f5fb65ac77710b2fdae3 Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Tue, 14 Apr 2026 16:51:21 +0200 Subject: [PATCH 10/20] refactor: use select macro for gio copy futures --- src/operation/recursive.rs | 36 ++++++++++++------------------------ 1 file changed, 12 insertions(+), 24 deletions(-) diff --git a/src/operation/recursive.rs b/src/operation/recursive.rs index befe69c..bbe89d1 100644 --- a/src/operation/recursive.rs +++ b/src/operation/recursive.rs @@ -9,7 +9,6 @@ use compio::buf::{IntoInner, IoBuf}; use compio::driver::{ToSharedFd, op::AsyncifyFd}; use compio::io::{AsyncReadAt, AsyncWriteAt}; use cosmic::iced::futures; -use futures::future::Either; use futures::{FutureExt, StreamExt}; use gio::prelude::FileExtManual; use std::future::Future; @@ -608,10 +607,11 @@ impl Op { glib::Priority::LOW, ); - let mut copy_fut = - gio_copy_fut.map(|result| result.map_err(GioCopyError::GLib)); + let mut copy_fut = gio_copy_fut + .map(|result| result.map_err(GioCopyError::GLib)) + .fuse(); - let mut progress_fut = std::pin::pin!(async { + let progress_fut = std::pin::pin!(async { while let Some((current_bytes, _)) = progress_stream.next().await { _ = progress_tx.send(current_bytes); } @@ -620,31 +620,23 @@ impl Op { futures::future::pending::<()>().await; }); - // Poll the progress future while waiting for the copy future to finish. - let mut main_fut = std::pin::pin!(async { - loop { - if let Either::Right((result, _)) = - futures::future::select(&mut progress_fut, &mut copy_fut).await - { - return result; - } - } - }); - + let mut progress_fut = progress_fut.fuse(); let mut pause_rx2 = pause_rx.clone(); loop { let until_paused = std::pin::pin!(pause_rx.wait_for(|paused| *paused)); - match futures::future::select(until_paused, &mut main_fut).await { - Either::Left(_) => { - _ = pause_rx2.wait_for(|paused| !*paused).await; - } + futures::select! { + _ = &mut progress_fut => {}, - Either::Right((result, _)) => { + result = &mut copy_fut => { _ = tx.send(result.map(|_| ())); glib_loop2.quit(); return; } + + _ = until_paused.fuse() => { + _ = pause_rx2.wait_for(|paused| !*paused).await; + } } } }); @@ -659,7 +651,6 @@ impl Op { loop { let until_paused = std::pin::pin!(ctx.controller.until_paused()); - futures::select! { value = progress_rx.recv().fuse() => { if let Some(current_bytes) = value { @@ -668,9 +659,6 @@ impl Op { if current.duration_since(last_progress_update).as_millis() > 49 { last_progress_update = current; (ctx.on_progress)(self, &progress); - - tracing::info!("checking controller"); - // Also check if the progress was cancelled. if let Err(state) = ctx.controller.check().await { tracing::warn!( From 15e40461e545a70871e21bcd1e698748abd523ed Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Fri, 10 Apr 2026 06:08:21 +0200 Subject: [PATCH 11/20] fix: do not generate thumbnail if file is being written --- src/operation/mod.rs | 3 ++ src/operation/notifiers.rs | 58 ++++++++++++++++++++++++++++++++++++++ src/operation/recursive.rs | 2 ++ src/tab.rs | 4 +++ 4 files changed, 67 insertions(+) create mode 100644 src/operation/notifiers.rs diff --git a/src/operation/mod.rs b/src/operation/mod.rs index da4a83b..1daed41 100644 --- a/src/operation/mod.rs +++ b/src/operation/mod.rs @@ -22,6 +22,9 @@ use zip::AesMode::Aes256; pub use self::controller::{Controller, ControllerState}; pub mod controller; +pub use notifiers::*; +mod notifiers; + pub use self::reader::OpReader; pub mod reader; diff --git a/src/operation/notifiers.rs b/src/operation/notifiers.rs new file mode 100644 index 0000000..0e27ce9 --- /dev/null +++ b/src/operation/notifiers.rs @@ -0,0 +1,58 @@ +// Copyright 2026 System76 +// SPDX-License-Identifier: GPL-3.0-only + +use std::path::{Path, PathBuf}; +use std::sync::{Arc, LazyLock, Mutex}; +use tokio::sync::Notify; + +/// Monitor files which are being written to. +pub struct FileWritingNotifier { + data: Vec, + notify: Arc, +} + +static ACTIVELY_WRITING: LazyLock> = LazyLock::new(|| { + Mutex::new(FileWritingNotifier { + data: Vec::new(), + notify: Arc::new(Notify::new()), + }) +}); + +/// Append path that is being written to. +pub fn actively_writing_add(path: PathBuf) { + ACTIVELY_WRITING.lock().unwrap().data.push(path); +} + +/// Remove path to file that has finished writing and notify waiters. +pub fn actively_writing_remove(path: &Path) { + let mut guard = ACTIVELY_WRITING.lock().unwrap(); + guard.data.retain(|p| p != path); + guard.notify.notify_waiters(); +} + +/// Wait until the actively-writing queue is empty or a file has been removed. +pub async fn actively_writing_tick() { + let notify = (|| { + let guard = ACTIVELY_WRITING.lock().unwrap(); + + if !guard.data.is_empty() { + return Some(guard.notify.clone()); + } + + None + })(); + + if let Some(notify) = notify { + notify.notified().await + } +} + +/// Check if a file is being written to. Avoid thumbnail generation until after it is finished. +pub fn is_actively_writing_to(path: &Path) -> bool { + ACTIVELY_WRITING + .lock() + .unwrap() + .data + .iter() + .any(|p| p == path) +} diff --git a/src/operation/recursive.rs b/src/operation/recursive.rs index bbe89d1..a38ea74 100644 --- a/src/operation/recursive.rs +++ b/src/operation/recursive.rs @@ -334,12 +334,14 @@ impl Op { } match self.kind { OpKind::Copy => { + crate::operation::actively_writing_add(self.to.clone()); let result = self.copy(ctx, progress).await; if result.is_err() { _ = compio::fs::remove_file(&self.to).await; } + crate::operation::actively_writing_remove(&self.to); return result; } OpKind::Move { cross_device_copy } => { diff --git a/src/tab.rs b/src/tab.rs index a0f95a0..9d9d2a2 100644 --- a/src/tab.rs +++ b/src/tab.rs @@ -6771,6 +6771,10 @@ impl Tab { stream::channel( 1, move |mut output: futures::channel::mpsc::Sender<_>| async move { + while crate::operation::is_actively_writing_to(&path) { + crate::operation::actively_writing_tick().await; + } + let message = { let path = path.clone(); From e21989aaa31a830005bb912e275b30815d5639ac Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Fri, 10 Apr 2026 06:09:51 +0200 Subject: [PATCH 12/20] chore: use compio::fs::rename for quick renames --- src/operation/mod.rs | 64 +++++++++++++++++++++++++------------------- 1 file changed, 37 insertions(+), 27 deletions(-) diff --git a/src/operation/mod.rs b/src/operation/mod.rs index 1daed41..f9fae0d 100644 --- a/src/operation/mod.rs +++ b/src/operation/mod.rs @@ -114,7 +114,7 @@ async fn copy_or_move( ); // Handle duplicate file names by renaming paths - let mut from_to_pairs: Vec<(PathBuf, PathBuf)> = paths + let from_to_pairs_iter = paths .into_iter() .zip(std::iter::repeat(to.as_path())) .filter_map(|(from, to)| { @@ -132,36 +132,46 @@ async fn copy_or_move( //TODO: how to handle from missing file name? None } - }) - .collect(); + }); // Attempt quick and simple renames //TODO: allow rename to be used for directories in recursive context? - if matches!(method, Method::Move { .. }) { - from_to_pairs.retain(|(from, to)| { - //TODO: show replace dialog here? - if to.exists() { - return true; - } - //TODO: use compio::fs::rename? - match fs::rename(from, to) { - Ok(()) => { - log::info!("renamed {} to {}", from.display(), to.display()); - false + let from_to_pairs: Vec<(PathBuf, PathBuf)> = if matches!(method, Method::Move { .. }) { + from_to_pairs_iter + .map(|(from, to)| async move { + //TODO: show replace dialog here? + if to.exists() { + return Some((from, to)); } - Err(err) => { - log::info!( - "failed to rename {} to {}, fallback to recursive move: {}", - from.display(), - to.display(), - err - ); - true + + match compio::fs::rename(&from, &to).await { + Ok(()) => { + log::info!("renamed {} to {}", from.display(), to.display()); + None + } + Err(err) => { + log::info!( + "failed to rename {} to {}, fallback to recursive move: {}", + from.display(), + to.display(), + err + ); + Some((from, to)) + } } - } - }); - } + }) + .collect::>() + .fold(Vec::new(), |mut pairs, pair| async move { + if let Some(pair) = pair { + pairs.push(pair); + } + pairs + }) + .await + } else { + from_to_pairs_iter.collect() + }; let mut context = Context::new(controller.clone()); @@ -219,7 +229,7 @@ pub async fn sync_to_disk( } })) .buffer_unordered(32) - .collect::>() + .collect::<()>() .await; // Sync directories to disk @@ -229,7 +239,7 @@ pub async fn sync_to_disk( } })) .buffer_unordered(16) - .collect::>() + .collect::<()>() .await; } From 1c4ab758143244c4b7b0c612831fb5346b03d291 Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Tue, 14 Apr 2026 17:15:19 +0200 Subject: [PATCH 13/20] fix: gate gio file copy fallback with gvfs feature --- src/operation/recursive.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/operation/recursive.rs b/src/operation/recursive.rs index a38ea74..9a33ebd 100644 --- a/src/operation/recursive.rs +++ b/src/operation/recursive.rs @@ -10,7 +10,6 @@ use compio::driver::{ToSharedFd, op::AsyncifyFd}; use compio::io::{AsyncReadAt, AsyncWriteAt}; use cosmic::iced::futures; use futures::{FutureExt, StreamExt}; -use gio::prelude::FileExtManual; use std::future::Future; use std::pin::Pin; use std::rc::Rc; @@ -18,10 +17,14 @@ use std::time::Instant; use std::{cell::Cell, error::Error, fs, ops::ControlFlow, path::PathBuf}; use walkdir::WalkDir; +#[cfg(feature = "gvfs")] +use gio::prelude::FileExtManual; + #[derive(thiserror::Error, Debug)] pub enum GioCopyError { #[error("controller state")] Controller(OperationError), + #[cfg(feature = "gvfs")] #[error("gio copy failed")] GLib(#[from] glib::Error), } @@ -508,6 +511,7 @@ impl Op { let buf_out = buf_out_slice.into_inner(); if let Err(why) = result { + #[cfg(feature = "gvfs")] if let std::io::ErrorKind::Unsupported = why.kind() { ctx.buf = buf_out; _ = futures::future::join(from_file.close(), to_file.close()).await; @@ -583,6 +587,7 @@ impl Op { /// Fallback mechanism in the event that unsupported I/O error errors occur. /// Fixes unsupported errors when copying large files over MTP. /// TODO: Find what Gio.File does to work around this. + #[cfg(feature = "gvfs")] async fn gio_file_copy( &self, ctx: &mut Context, From 908f30a571b496a3658ad60a1c7f6a10e92fde50 Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Tue, 14 Apr 2026 17:47:50 +0200 Subject: [PATCH 14/20] example(dialog): switch logger to fix build --- examples/dialog.rs | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/examples/dialog.rs b/examples/dialog.rs index d1d5515..be93576 100644 --- a/examples/dialog.rs +++ b/examples/dialog.rs @@ -9,9 +9,25 @@ use cosmic_files::dialog::{ Dialog, DialogChoice, DialogChoiceOption, DialogFilter, DialogFilterPattern, DialogKind, DialogMessage, DialogResult, DialogSettings, }; +use tracing_subscriber::{layer::SubscriberExt, util::SubscriberInitExt}; fn main() -> Result<(), Box> { - env_logger::Builder::from_env(env_logger::Env::default().default_filter_or("warn")).init(); + let log_format = tracing_subscriber::fmt::format() + .pretty() + .without_time() + .with_line_number(true) + .with_file(true) + .with_target(false) + .with_thread_names(true); + + let log_layer = tracing_subscriber::fmt::Layer::default() + .with_writer(std::io::stderr) + .event_format(log_format); + + tracing_subscriber::registry() + .with(tracing_subscriber::EnvFilter::from_env("RUST_LOG")) + .with(log_layer) + .init(); let settings = Settings::default(); app::run::(settings, ())?; From 33890633b5ee25a02126d6a8c01f38cf6cfaff23 Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Tue, 14 Apr 2026 11:09:50 -0600 Subject: [PATCH 15/20] Epoch 1.0.11 version update Generated by cosmic-epoch scripts/version-update.sh --- Cargo.lock | 348 +++++++++++++++++---------------- Cargo.toml | 2 +- cosmic-files-applet/Cargo.toml | 2 +- debian/changelog | 6 + 4 files changed, 187 insertions(+), 171 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 18345fc..0084c8d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -192,7 +192,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0f2a1bb052857d5dd49572219344a7332b31b76405648eabac5bc68978251bcd" dependencies = [ "android-properties", - "bitflags 2.11.0", + "bitflags 2.11.1", "cc", "jni", "libc", @@ -361,7 +361,7 @@ dependencies = [ "enumflags2", "futures-channel", "futures-util", - "rand 0.9.2", + "rand 0.9.4", "raw-window-handle", "serde", "serde_repr", @@ -379,7 +379,7 @@ dependencies = [ "enumflags2", "futures-channel", "futures-util", - "rand 0.9.2", + "rand 0.9.4", "serde", "serde_repr", "tokio", @@ -696,20 +696,20 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.11.0" +version = "2.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "843867be96c8daad0d758b57df9392b6d8d271134fce549de6ce169ff98a92af" +checksum = "c4512299f36f043ab09a583e57bceb5a5aab7a73db1805848e8fef3c9e8c78b3" dependencies = [ "serde_core", ] [[package]] name = "bitstream-io" -version = "4.9.0" +version = "4.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60d4bd9d1db2c6bdf285e223a7fa369d5ce98ec767dec949c6ca62863ce61757" +checksum = "7eff00be299a18769011411c9def0d827e8f2d7bf0c3dbf53633147a8867fd1f" dependencies = [ - "core2", + "no_std_io2", ] [[package]] @@ -879,7 +879,7 @@ version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4dbf9978365bac10f54d1d4b04f7ce4427e51f71d61f2fe15e3fed5166474df7" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "polling", "rustix 1.1.4", "slab", @@ -900,9 +900,9 @@ dependencies = [ [[package]] name = "cc" -version = "1.2.59" +version = "1.2.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7a4d3ec6524d28a329fc53654bbadc9bdd7b0431f5d65f1a56ffb28a1ee5283" +checksum = "43c5703da9466b66a946814e1adf53ea2c90f10063b86290cc9eb67ce3478a20" dependencies = [ "find-msvc-tools", "jobserver", @@ -1273,20 +1273,11 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3d44a101f213f6c4cdc1853d4b78aef6db6bdfa3468798cc1d9912f4735013eb" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "core-foundation 0.10.1", "libc", ] -[[package]] -name = "core2" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b49ba7ef1ad6107f8824dbe97de947cbaac53c44e7f9756a1fba0d37c1eec505" -dependencies = [ - "memchr", -] - [[package]] name = "core_affinity" version = "0.8.3" @@ -1312,7 +1303,7 @@ name = "cosmic-client-toolkit" version = "0.2.0" source = "git+https://github.com/pop-os/cosmic-protocols?rev=160b086#160b086abe03cd34a8a375d7fbe47b24308d1f38" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "cosmic-protocols", "libc", "smithay-client-toolkit", @@ -1323,7 +1314,7 @@ dependencies = [ [[package]] name = "cosmic-config" version = "1.0.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "atomicwrites", "cosmic-config-derive", @@ -1344,7 +1335,7 @@ dependencies = [ [[package]] name = "cosmic-config-derive" version = "1.0.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "quote", "syn", @@ -1352,7 +1343,7 @@ dependencies = [ [[package]] name = "cosmic-files" -version = "1.0.9" +version = "1.0.11" dependencies = [ "anyhow", "atomic_float", @@ -1419,7 +1410,7 @@ dependencies = [ [[package]] name = "cosmic-files-applet" -version = "1.0.9" +version = "1.0.11" dependencies = [ "cosmic-files", "log", @@ -1429,7 +1420,7 @@ dependencies = [ [[package]] name = "cosmic-freedesktop-icons" version = "0.4.0" -source = "git+https://github.com/pop-os/freedesktop-icons#7a61a704f6d1ec41f71cbe766e3cc484858523fa" +source = "git+https://github.com/pop-os/freedesktop-icons#9c562fe3ecf03241a46a60c0078cd6ea10bd75ce" dependencies = [ "bstr", "btoi", @@ -1456,7 +1447,7 @@ name = "cosmic-protocols" version = "0.2.0" source = "git+https://github.com/pop-os/cosmic-protocols?rev=160b086#160b086abe03cd34a8a375d7fbe47b24308d1f38" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "wayland-backend", "wayland-client", "wayland-protocols", @@ -1491,7 +1482,7 @@ name = "cosmic-text" version = "0.18.2" source = "git+https://github.com/pop-os/cosmic-text.git#4d74f795cc771fdcc7ea0f9cacba63fcf036fad6" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "fontdb", "harfrust", "linebender_resource_handle", @@ -1512,7 +1503,7 @@ dependencies = [ [[package]] name = "cosmic-theme" version = "1.0.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "almost", "configparser", @@ -1830,7 +1821,7 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1e0e367e4e7da84520dedcac1901e4da967309406d1e51017ae1abfb97adbd38" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.6.2", "libc", "objc2 0.6.4", @@ -1861,7 +1852,7 @@ name = "dnd" version = "0.1.0" source = "git+https://github.com/pop-os/window_clipboard.git?tag=sctk-0.20#f68595ee0e62fbd6589f4709b5aaa5c3c7ea5f6c" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "mime 0.1.0", "raw-window-handle", "smithay-client-toolkit", @@ -1886,7 +1877,7 @@ checksum = "75b325c5dbd37f80359721ad39aca5a29fb04c89279657cffdda8736d0c0b9d2" [[package]] name = "dpi" version = "0.1.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" [[package]] name = "drm" @@ -1894,7 +1885,7 @@ version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a0f8a69e60d75ae7dab4ef26a59ca99f2a89d4c142089b537775ae0c198bdcde" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "bytemuck", "drm-ffi", "drm-fourcc", @@ -2277,9 +2268,9 @@ checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb" [[package]] name = "font-types" -version = "0.11.2" +version = "0.11.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d9237c6d82152100c691fb77ea18037b402bcc7257d2c876a4ffac81bc22a1c" +checksum = "5b38ad915f6dadd993ced50848a8291a543bd41ca62bc10740d5e64e2ab4cfd7" dependencies = [ "bytemuck", ] @@ -2653,7 +2644,7 @@ version = "0.21.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "16de123c2e6c90ce3b573b7330de19be649080ec612033d397d72da265f1bd8b" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "futures-channel", "futures-core", "futures-executor", @@ -2748,7 +2739,7 @@ version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fbcd2dba93594b227a1f57ee09b8b9da8892c34d55aa332e034a228d0fe6a171" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "gpu-alloc-types", ] @@ -2758,7 +2749,7 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "98ff03b468aa837d70984d55f5d3f846f6ec31fe34bbb97c4f85219caeee1ca4" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", ] [[package]] @@ -2779,7 +2770,7 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b89c83349105e3732062a895becfc71a8f921bb71ecbbdd8ff99263e3b53a0ca" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "gpu-descriptor-types", "hashbrown 0.15.5", ] @@ -2790,7 +2781,7 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fdf242682df893b86f33a73828fb09ca4b2d3bb6cc95249707fc684d27484b91" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", ] [[package]] @@ -2827,7 +2818,7 @@ version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9da2e5ae821f6e96664977bf974d6d6a2d6682f9ccee23e62ec1d134246845f9" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "bytemuck", "core_maths", "read-fonts", @@ -2997,7 +2988,7 @@ dependencies = [ [[package]] name = "iced" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "dnd", "iced_accessibility", @@ -3018,7 +3009,7 @@ dependencies = [ [[package]] name = "iced_accessibility" version = "0.1.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "accesskit", "accesskit_winit", @@ -3027,9 +3018,9 @@ dependencies = [ [[package]] name = "iced_core" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "bytes", "cosmic-client-toolkit", "dnd", @@ -3051,7 +3042,7 @@ dependencies = [ [[package]] name = "iced_debug" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "iced_core", "iced_futures", @@ -3061,7 +3052,7 @@ dependencies = [ [[package]] name = "iced_futures" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "futures", "iced_core", @@ -3075,9 +3066,9 @@ dependencies = [ [[package]] name = "iced_graphics" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "bytemuck", "cosmic-text", "half", @@ -3096,7 +3087,7 @@ dependencies = [ [[package]] name = "iced_program" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "iced_graphics", "iced_runtime", @@ -3105,7 +3096,7 @@ dependencies = [ [[package]] name = "iced_renderer" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "iced_graphics", "iced_tiny_skia", @@ -3117,7 +3108,7 @@ dependencies = [ [[package]] name = "iced_runtime" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "bytes", "cosmic-client-toolkit", @@ -3132,7 +3123,7 @@ dependencies = [ [[package]] name = "iced_tiny_skia" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "bytemuck", "cosmic-text", @@ -3149,10 +3140,10 @@ dependencies = [ [[package]] name = "iced_wgpu" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "as-raw-xcb-connection", - "bitflags 2.11.0", + "bitflags 2.11.1", "bytemuck", "cosmic-client-toolkit", "cryoglyph", @@ -3180,7 +3171,7 @@ dependencies = [ [[package]] name = "iced_widget" version = "0.14.2" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "cosmic-client-toolkit", "dnd", @@ -3198,7 +3189,7 @@ dependencies = [ [[package]] name = "iced_winit" version = "0.14.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "cosmic-client-toolkit", "cursor-icon", @@ -3699,6 +3690,15 @@ dependencies = [ "zune-jpeg 0.5.15", ] +[[package]] +name = "image-extras" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "86d29ba92ef6970a2685cc758b455d190842b8b9e96c865ffd31cdb9954b7548" +dependencies = [ + "image", +] + [[package]] name = "image-webp" version = "0.2.4" @@ -3759,7 +3759,7 @@ version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bd5b3eaf1a28b758ac0faa5a4254e8ab2705605496f1b1f3fbbc3988ad73d199" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "inotify-sys", "libc", ] @@ -3818,7 +3818,7 @@ version = "0.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fdd7bddefd0a8833b88a4b68f90dae22c7450d11b354198baee3874fd811b344" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "cfg-if", "libc", ] @@ -4002,9 +4002,9 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.94" +version = "0.3.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e04e2ef80ce82e13552136fabeef8a5ed1f985a96805761cbb9a2c34e7664d9" +checksum = "2964e92d1d9dc3364cae4d718d93f227e3abb088e747d92e0395bfdedf1c12ca" dependencies = [ "cfg-if", "futures-util", @@ -4207,7 +4207,7 @@ version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0fbe853b403ae61a04233030ae8a79d94975281ed9770a1f9e246732b534b28d" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "serde", ] @@ -4298,20 +4298,20 @@ checksum = "7a79a3332a6609480d7d0c9eab957bca6b455b91bb84e66d19f5ff66294b85b8" [[package]] name = "libbz2-rs-sys" -version = "0.2.2" +version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c4a545a15244c7d945065b5d392b2d2d7f21526fba56ce51467b06ed445e8f7" +checksum = "b3a6a8c165077efc8f3a971534c50ea6a1a18b329ef4a66e897a7e3a1494565f" [[package]] name = "libc" -version = "0.2.184" +version = "0.2.185" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48f5d2a454e16a5ea0f4ced81bd44e4cfc7bd3a507b61887c99fd3538b28e4af" +checksum = "52ff2c0fe9bc6cb6b14a0592c2ff4fa9ceb83eea9db979b0487cd054946a2b8f" [[package]] name = "libcosmic" version = "1.0.0" -source = "git+https://github.com/pop-os/libcosmic.git#6caccaba337ed9bab21c5fe3c2aa7392e322e89c" +source = "git+https://github.com/pop-os/libcosmic.git#c423ad1bfc25057922406c687f2ddc75ead5ab67" dependencies = [ "apply", "ashpd 0.12.3", @@ -4339,6 +4339,7 @@ dependencies = [ "iced_widget", "iced_winit", "image", + "image-extras", "jiff", "libc", "log", @@ -4392,7 +4393,7 @@ version = "0.1.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e02f3bb43d335493c96bf3fd3a321600bf6bd07ed34bc64118e9293bdffea46c" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "libc", "plain", "redox_syscall 0.7.4", @@ -4496,9 +4497,9 @@ dependencies = [ [[package]] name = "lru" -version = "0.16.3" +version = "0.16.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1dc47f592c06f33f8e3aea9591776ec7c9f9e4124778ff8a3c3b87159f7e593" +checksum = "7f66e8d5d03f609abc3a39e6f08e4164ebf1447a732906d39eb9b99b7919ef39" [[package]] name = "lyon" @@ -4650,7 +4651,7 @@ version = "0.32.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "00c15a6f673ff72ddcc22394663290f870fb224c1bfce55734a75c414150e605" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block", "core-graphics-types 0.2.0", "foreign-types", @@ -4735,7 +4736,7 @@ checksum = "066cf25f0e8b11ee0df221219010f213ad429855f57c494f995590c861a9a7d8" dependencies = [ "arrayvec", "bit-set", - "bitflags 2.11.0", + "bitflags 2.11.1", "cfg-if", "cfg_aliases", "codespan-reporting", @@ -4759,7 +4760,7 @@ version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c3f42e7bbe13d351b6bead8286a43aac9534b82bd3cc43e47037f012ebfd62d4" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "jni-sys 0.3.1", "log", "ndk-sys", @@ -4795,13 +4796,22 @@ version = "0.29.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "71e2746dc3a24dd78b3cfcb7be93368c6de9963d30f43a6a73998a9cf4b17b46" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "cfg-if", "cfg_aliases", "libc", "memoffset", ] +[[package]] +name = "no_std_io2" +version = "0.9.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b51ed7824b6e07d354605f4abb3d9d300350701299da96642ee084f5ce631550" +dependencies = [ + "memchr", +] + [[package]] name = "nom" version = "7.1.3" @@ -4833,7 +4843,7 @@ version = "8.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4d3d07927151ff8575b7087f245456e549fea62edf0ec4e565a5ee50c8402bc3" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "fsevent-sys", "inotify", "kqueue", @@ -4860,9 +4870,9 @@ dependencies = [ [[package]] name = "notify-rust" -version = "4.14.0" +version = "4.15.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b2c9bc1689653cfbc04400b8719f2562638ff9c545bbd48cc58c657a14526df" +checksum = "3c8146c105ae33d744e2d645f684d063b01176a99daf5986556266777b428816" dependencies = [ "futures-lite", "log", @@ -4878,7 +4888,7 @@ version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "42b8cfee0e339a0337359f3c88165702ac6e600dc01c0cc9579a92d62b08477a" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", ] [[package]] @@ -5030,7 +5040,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e4e89ad9e3d7d297152b17d39ed92cd50ca8063a89a9fa569046d41568891eff" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.5.1", "libc", "objc2 0.5.2", @@ -5046,7 +5056,7 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d49e936b501e5c5bf01fda3a9452ff86dc3ea98ad5f283e1455153142d97518c" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.6.2", "objc2 0.6.4", "objc2-core-foundation", @@ -5059,7 +5069,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "617fbf49e071c178c0b24c080767db52958f716d9eabdf0890523aeae54773ef" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.5.1", "objc2 0.5.2", "objc2-foundation 0.2.2", @@ -5071,7 +5081,7 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2a180dd8642fa45cdb7dd721cd4c11b1cadd4929ce112ebd8b9f5803cc79d536" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.6.2", "dispatch2", "objc2 0.6.4", @@ -5083,7 +5093,7 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e022c9d066895efa1345f8e33e584b9f958da2fd4cd116792e15e07e4720a807" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "libc", "objc2-core-foundation", ] @@ -5106,7 +5116,7 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d425caf1df73233f29fd8a5c3e5edbc30d2d4307870f802d18f00d83dc5141a6" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "objc2-core-foundation", "objc2-core-graphics", ] @@ -5123,7 +5133,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0ee638a5da3799329310ad4cfa62fbf045d5f56e3ef5ba4149e7452dcf89d5a8" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.5.1", "libc", "objc2 0.5.2", @@ -5135,7 +5145,7 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e3e0adef53c21f888deb4fa59fc59f7eb17404926ee8a6f59f5df0fd7f9f3272" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.6.2", "libc", "objc2 0.6.4", @@ -5148,7 +5158,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dd0cba1276f6023976a406a14ffa85e1fdd19df6b0f737b063b95f6c8c7aadd6" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.5.1", "objc2 0.5.2", "objc2-foundation 0.2.2", @@ -5160,7 +5170,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e42bee7bff906b14b167da2bac5efe6b6a07e6f7c0a21a7308d40c960242dc7a" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.5.1", "objc2 0.5.2", "objc2-foundation 0.2.2", @@ -5173,7 +5183,7 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d87d638e33c06f577498cbcc50491496a3ed4246998a7fbba7ccb98b1e7eab22" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "objc2 0.6.4", "objc2-core-foundation", "objc2-foundation 0.3.2", @@ -5416,7 +5426,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3c80231409c20246a13fddb31776fb942c38553c51e871f8cbd687a4cfb5843d" dependencies = [ "phf_shared 0.11.3", - "rand 0.8.5", + "rand 0.8.6", ] [[package]] @@ -5526,9 +5536,9 @@ dependencies = [ [[package]] name = "pkg-config" -version = "0.3.32" +version = "0.3.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7edddbd0b52d732b21ad9a5fab5c704c14cd949e5e9a1ec5929a24fded1b904c" +checksum = "19f132c84eca552bf34cab8ec81f1c1dcc229b811638f9d283dceabe58c5569e" [[package]] name = "plain" @@ -5555,7 +5565,7 @@ version = "0.18.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "60769b8b31b2a9f263dae2776c37b1b28ae246943cf719eb6946a1db05128a61" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "crc32fast", "fdeflate", "flate2", @@ -5590,9 +5600,9 @@ checksum = "c33a9471896f1c69cecef8d20cbe2f7accd12527ce60845ff44c153bb2a21b49" [[package]] name = "portable-atomic-util" -version = "0.2.6" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "091397be61a01d4be58e7841595bd4bfedb15f1cd54977d79b8271e94ed799a3" +checksum = "c2a106d1259c23fac8e543272398ae0e3c0b8d33c88ed73d0cc71b0f1d902618" dependencies = [ "portable-atomic", ] @@ -5704,7 +5714,7 @@ version = "0.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "25485360a54d6861439d60facef26de713b1e126bf015ec8f98239467a2b82f7" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "chrono", "flate2", "procfs-core", @@ -5717,7 +5727,7 @@ version = "0.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e6401bf7b6af22f78b563665d15a22e9aef27775b79b149a66ca022468a4e405" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "chrono", "hex", ] @@ -5743,9 +5753,9 @@ dependencies = [ [[package]] name = "pxfm" -version = "0.1.28" +version = "0.1.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5a041e753da8b807c9255f28de81879c78c876392ff2469cde94799b2896b9d" +checksum = "e0c5ccf5294c6ccd63a74f1565028353830a9c2f5eb0c682c355c471726a6e3f" [[package]] name = "qoi" @@ -5823,9 +5833,9 @@ checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf" [[package]] name = "rand" -version = "0.8.5" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +checksum = "5ca0ecfa931c29007047d1bc58e623ab12e5590e8c7cc53200d5202b69266d8a" dependencies = [ "libc", "rand_chacha 0.3.1", @@ -5834,9 +5844,9 @@ dependencies = [ [[package]] name = "rand" -version = "0.9.2" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6db2770f06117d490610c7488547d543617b21bfa07796d7a12f6f1bd53850d1" +checksum = "44c5af06bb1b7d3216d91932aed5265164bf384dc89cd6ba05cf59a35f5f76ea" dependencies = [ "rand_chacha 0.9.0", "rand_core 0.9.5", @@ -5919,7 +5929,7 @@ dependencies = [ "num-traits", "paste", "profiling", - "rand 0.9.2", + "rand 0.9.4", "rand_chacha 0.9.0", "simd_helpers", "thiserror 2.0.18", @@ -5950,9 +5960,9 @@ checksum = "20675572f6f24e9e76ef639bc5552774ed45f1c30e2951e1e99c59888861c539" [[package]] name = "rayon" -version = "1.11.0" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "368f01d005bf8fd9b1206fb6fa653e6c4a81ceb1466406b81792d87c5677a58f" +checksum = "fb39b166781f92d482534ef4b4b1b2568f42613b53e5b6c160e24cfbfa30926d" dependencies = [ "either", "rayon-core", @@ -6001,7 +6011,7 @@ version = "0.5.18" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", ] [[package]] @@ -6010,7 +6020,7 @@ version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f450ad9c3b1da563fb6948a8e0fb0fb9269711c9c73d9ea1de5058c79c8d643a" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", ] [[package]] @@ -6147,7 +6157,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "db09040cc89e461f1a265139777a2bde7f8d8c67c4936f700c63ce3e2904d468" dependencies = [ "base64", - "bitflags 2.11.0", + "bitflags 2.11.1", "serde", "serde_derive", "unicode-ident", @@ -6159,7 +6169,7 @@ version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4147b952f3f819eca0e99527022f7d6a8d05f111aeb0a62960c74eb283bec8fc" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "once_cell", "serde", "serde_derive", @@ -6234,7 +6244,7 @@ version = "0.38.44" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "errno", "libc", "linux-raw-sys 0.4.15", @@ -6247,7 +6257,7 @@ version = "1.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b6fe4565b9518b83ef4f91bb47ce29620ca828bd32cb7e408f0062e9930ba190" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "errno", "libc", "linux-raw-sys 0.12.1", @@ -6266,7 +6276,7 @@ version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fd3c7c96f8a08ee34eff8857b11b49b07d71d1c3f4e88f8a88d4c9e9f90b1702" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "bytemuck", "core_maths", "log", @@ -6573,7 +6583,7 @@ version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0512da38f5e2b31201a93524adb8d3136276fa4fe4aafab4e1f727a82b534cc0" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "bytemuck", "calloop", "calloop-wayland-source", @@ -6673,7 +6683,7 @@ version = "0.3.0+sdk-1.3.268.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eda41003dc44290527a59b13432d4a0379379fa074b70174882adfbdfd917844" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", ] [[package]] @@ -7069,9 +7079,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.51.1" +version = "1.52.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f66bf9585cda4b724d3e78ab34b73fb2bbaba9011b9bfdf69dc836382ea13b8c" +checksum = "b67dee974fe86fd92cc45b7a95fdd2f99a36a6d7b0d431a231178d3d670bbcc6" dependencies = [ "bytes", "libc", @@ -7458,9 +7468,9 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.23.0" +version = "1.23.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ac8b6f42ead25368cf5b098aeb3dc8a1a2c05a3eee8a9a1a68c640edbfc79d9" +checksum = "ddd74a9687298c6858e9b88ec8935ec45d22e8fd5e6394fa1bd4e99a87789c76" dependencies = [ "js-sys", "serde_core", @@ -7542,9 +7552,9 @@ dependencies = [ [[package]] name = "wasm-bindgen" -version = "0.2.117" +version = "0.2.118" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0551fc1bb415591e3372d0bc4780db7e587d84e2a7e79da121051c5c4b89d0b0" +checksum = "0bf938a0bacb0469e83c1e148908bd7d5a6010354cf4fb73279b7447422e3a89" dependencies = [ "cfg-if", "once_cell", @@ -7555,9 +7565,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-futures" -version = "0.4.67" +version = "0.4.68" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03623de6905b7206edd0a75f69f747f134b7f0a2323392d664448bf2d3c5d87e" +checksum = "f371d383f2fb139252e0bfac3b81b265689bf45b6874af544ffa4c975ac1ebf8" dependencies = [ "js-sys", "wasm-bindgen", @@ -7565,9 +7575,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.117" +version = "0.2.118" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fbdf9a35adf44786aecd5ff89b4563a90325f9da0923236f6104e603c7e86be" +checksum = "eeff24f84126c0ec2db7a449f0c2ec963c6a49efe0698c4242929da037ca28ed" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -7575,9 +7585,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.117" +version = "0.2.118" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dca9693ef2bab6d4e6707234500350d8dad079eb508dca05530c85dc3a529ff2" +checksum = "9d08065faf983b2b80a79fd87d8254c409281cf7de75fc4b773019824196c904" dependencies = [ "bumpalo", "proc-macro2", @@ -7588,9 +7598,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-shared" -version = "0.2.117" +version = "0.2.118" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39129a682a6d2d841b6c429d0c51e5cb0ed1a03829d8b3d1e69a011e62cb3d3b" +checksum = "5fd04d9e306f1907bd13c6361b5c6bfc7b3b3c095ed3f8a9246390f8dbdee129" dependencies = [ "unicode-ident", ] @@ -7623,7 +7633,7 @@ version = "0.244.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "47b807c72e1bac69382b3a6fb3dbe8ea4c0ed87ff5629b8685ae6b9a611028fe" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "hashbrown 0.15.5", "indexmap 2.14.0", "semver", @@ -7663,7 +7673,7 @@ version = "0.31.14" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "645c7c96bb74690c3189b5c9cb4ca1627062bb23693a4fad9d8c3de958260144" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "rustix 1.1.4", "wayland-backend", "wayland-scanner", @@ -7675,7 +7685,7 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "625c5029dbd43d25e6aa9615e88b829a5cad13b2819c4ae129fdbb7c31ab4c7e" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "cursor-icon", "wayland-backend", ] @@ -7697,7 +7707,7 @@ version = "0.32.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "563a85523cade2429938e790815fd7319062103b9f4a2dc806e9b53b95982d8f" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "wayland-backend", "wayland-client", "wayland-scanner", @@ -7710,7 +7720,7 @@ version = "20250721.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "40a1f863128dcaaec790d7b4b396cc9b9a7a079e878e18c47e6c2d2c5a8dcbb1" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "wayland-backend", "wayland-client", "wayland-protocols", @@ -7723,7 +7733,7 @@ version = "0.3.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6e9567599ef23e09b8dad6e429e5738d4509dfc46b3b21f32841a304d16b29c8" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "wayland-backend", "wayland-client", "wayland-protocols", @@ -7736,7 +7746,7 @@ version = "0.3.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2b6d8cf1eb2c1c31ed1f5643c88a6e53538129d4af80030c8cabd1f9fa884d91" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "wayland-backend", "wayland-client", "wayland-protocols", @@ -7749,7 +7759,7 @@ version = "0.3.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eb04e52f7836d7c7976c78ca0250d61e33873c34156a2a1fc9474828ec268234" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "wayland-backend", "wayland-client", "wayland-protocols", @@ -7774,7 +7784,7 @@ version = "0.31.13" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cc1846eb04c49182e04f4a099e2a830a2b745610bbc1d61246e206f29c7000a0" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "downcast-rs", "rustix 1.1.4", "wayland-backend", @@ -7795,9 +7805,9 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.94" +version = "0.3.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd70027e39b12f0849461e08ffc50b9cd7688d942c1c8e3c7b22273236b4dd0a" +checksum = "4f2dfbb17949fa2088e5d39408c48368947b86f7834484e87b73de55bc14d97d" dependencies = [ "js-sys", "wasm-bindgen", @@ -7826,7 +7836,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bfe68bac7cde125de7a731c3400723cadaaf1703795ad3f4805f187459cd7a77" dependencies = [ "arrayvec", - "bitflags 2.11.0", + "bitflags 2.11.1", "cfg-if", "cfg_aliases", "document-features", @@ -7857,7 +7867,7 @@ dependencies = [ "arrayvec", "bit-set", "bit-vec", - "bitflags 2.11.0", + "bitflags 2.11.1", "bytemuck", "cfg_aliases", "document-features", @@ -7917,7 +7927,7 @@ dependencies = [ "arrayvec", "ash", "bit-set", - "bitflags 2.11.0", + "bitflags 2.11.1", "block", "bytemuck", "cfg-if", @@ -7962,7 +7972,7 @@ version = "27.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "afdcf84c395990db737f2dd91628706cb31e86d72e53482320d368e52b5da5eb" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "bytemuck", "js-sys", "log", @@ -8530,9 +8540,9 @@ checksum = "d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650" [[package]] name = "winit" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "cfg_aliases", "cursor-icon", "dpi", @@ -8556,10 +8566,10 @@ dependencies = [ [[package]] name = "winit-android" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ "android-activity", - "bitflags 2.11.0", + "bitflags 2.11.1", "dpi", "ndk", "raw-window-handle", @@ -8571,9 +8581,9 @@ dependencies = [ [[package]] name = "winit-appkit" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.6.2", "dispatch2", "dpi", @@ -8593,7 +8603,7 @@ dependencies = [ [[package]] name = "winit-common" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ "memmap2 0.9.10", "objc2 0.6.4", @@ -8608,9 +8618,9 @@ dependencies = [ [[package]] name = "winit-core" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "cursor-icon", "dpi", "keyboard-types", @@ -8622,9 +8632,9 @@ dependencies = [ [[package]] name = "winit-orbital" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "dpi", "libredox", "orbclient", @@ -8638,9 +8648,9 @@ dependencies = [ [[package]] name = "winit-uikit" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "block2 0.6.2", "dispatch2", "dpi", @@ -8658,10 +8668,10 @@ dependencies = [ [[package]] name = "winit-wayland" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ "ahash", - "bitflags 2.11.0", + "bitflags 2.11.1", "calloop", "cursor-icon", "dpi", @@ -8684,10 +8694,10 @@ dependencies = [ [[package]] name = "winit-web" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ "atomic-waker", - "bitflags 2.11.0", + "bitflags 2.11.1", "concurrent-queue", "cursor-icon", "dpi", @@ -8706,9 +8716,9 @@ dependencies = [ [[package]] name = "winit-win32" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "cursor-icon", "dpi", "raw-window-handle", @@ -8722,9 +8732,9 @@ dependencies = [ [[package]] name = "winit-x11" version = "0.31.0-beta.2" -source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#a610ac9c7a72b39ff102ed4d946291618dc725b6" +source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "bytemuck", "calloop", "cursor-icon", @@ -8818,7 +8828,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9d66ea20e9553b30172b5e831994e35fbde2d165325bec84fc43dbf6f4eb9cb2" dependencies = [ "anyhow", - "bitflags 2.11.0", + "bitflags 2.11.1", "indexmap 2.14.0", "log", "serde", @@ -8991,7 +9001,7 @@ version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d039de8032a9a8856a6be89cea3e5d12fdd82306ab7c94d74e6deab2460651c5" dependencies = [ - "bitflags 2.11.0", + "bitflags 2.11.1", "dlib", "log", "once_cell", @@ -9099,7 +9109,7 @@ dependencies = [ "hex", "nix", "ordered-stream", - "rand 0.8.5", + "rand 0.8.6", "serde", "serde_repr", "sha1", diff --git a/Cargo.toml b/Cargo.toml index 74e554b..9ef9807 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "cosmic-files" -version = "1.0.9" +version = "1.0.11" authors = ["Jeremy Soller "] edition = "2024" license = "GPL-3.0-only" diff --git a/cosmic-files-applet/Cargo.toml b/cosmic-files-applet/Cargo.toml index 952b380..b20226b 100644 --- a/cosmic-files-applet/Cargo.toml +++ b/cosmic-files-applet/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "cosmic-files-applet" -version = "1.0.9" +version = "1.0.11" edition = "2024" [dependencies] diff --git a/debian/changelog b/debian/changelog index c9cdde6..bea1aee 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +cosmic-files (1.0.11) noble; urgency=medium + + * Epoch 1.0.11 version update + + -- Jeremy Soller Tue, 14 Apr 2026 11:09:44 -0600 + cosmic-files (1.0.9) noble; urgency=medium * Epoch 1.0.9 version update From 9c0eb63b8259813503ccd4ed72830553b8263ff8 Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Fri, 17 Apr 2026 12:01:28 -0600 Subject: [PATCH 16/20] Refactor trash handling to improve portability --- src/app.rs | 22 ++----- src/dialog.rs | 11 +--- src/lib.rs | 16 ++--- src/menu.rs | 3 +- src/operation/mod.rs | 4 +- src/tab.rs | 140 +++--------------------------------------- src/trash.rs | 143 +++++++++++++++++++++++++++++++++++++++++++ 7 files changed, 173 insertions(+), 166 deletions(-) create mode 100644 src/trash.rs diff --git a/src/app.rs b/src/app.rs index 2ab62a6..af0ecbe 100644 --- a/src/app.rs +++ b/src/app.rs @@ -99,6 +99,7 @@ use crate::{ self, HOVER_DURATION, HeadingOptions, ItemMetadata, Location, SORT_OPTION_FALLBACK, SearchLocation, Tab, }, + trash::{Trash, TrashExt}, zoom::{zoom_in_view, zoom_out_view, zoom_to_default}, }; @@ -1794,7 +1795,7 @@ impl App { nav_model = nav_model.insert(|b| { b.text(fl!("trash")) - .icon(icon::icon(tab::trash_helpers::trash_icon_symbolic(16))) + .icon(icon::icon(Trash::icon_symbolic(16))) .data(Location::Trash) .divider_above() }); @@ -2655,9 +2656,7 @@ impl Application for App { )); } - if matches!(location_opt, Some(Location::Trash)) - && !trash::os_limited::is_empty().unwrap_or(true) - { + if matches!(location_opt, Some(Location::Trash)) && !Trash::is_empty() { items.push(cosmic::widget::menu::Item::Button( fl!("empty-trash"), None, @@ -4237,10 +4236,8 @@ impl Application for App { .is_some_and(|loc| matches!(loc, Location::Trash)) }); if let Some(entity) = maybe_entity { - self.nav_model.icon_set( - entity, - icon::icon(tab::trash_helpers::trash_icon_symbolic(16)), - ); + self.nav_model + .icon_set(entity, icon::icon(Trash::icon_symbolic(16))); } return Task::batch([self.rescan_trash(), self.update_desktop()]); @@ -6803,14 +6800,7 @@ impl Application for App { }, ); - // TODO: Trash watching support for Windows, macOS, and other OSes - #[cfg(all( - unix, - not(target_os = "macos"), - not(target_os = "ios"), - not(target_os = "android") - ))] - match (watcher_res, trash::os_limited::trash_folders()) { + match (watcher_res, Trash::folders()) { (Ok(mut watcher), Ok(trash_bins)) => { // Watch the "bins" themselves as well as the files folder where // trashed items are placed. This allows us to avoid recursively diff --git a/src/dialog.rs b/src/dialog.rs index f9894ac..cac5907 100644 --- a/src/dialog.rs +++ b/src/dialog.rs @@ -441,13 +441,8 @@ impl Dialog { #[derive(Clone, Debug)] enum DialogPage { - NewFolder { - parent: PathBuf, - name: String, - }, - Replace { - filename: String, - }, + NewFolder { parent: PathBuf, name: String }, + Replace { filename: String }, } #[derive(Clone, Debug)] @@ -2042,7 +2037,7 @@ impl Application for App { } col = col.push( - self.tab + self.tab .view(&self.key_binds, &self.modifiers, false, &[]) .map(Message::TabMessage), ); diff --git a/src/lib.rs b/src/lib.rs index 9214a7f..644b64d 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -5,14 +5,18 @@ use cosmic::{app::Settings, iced::Limits}; use std::{env, fs, path::PathBuf, process}; use tracing_subscriber::{layer::SubscriberExt, util::SubscriberInitExt}; -use app::{App, Flags}; +use crate::{ + app::{App, Flags}, + config::{Config, State}, + tab::Location, +}; + pub mod app; mod archive; pub mod channel; pub mod clipboard; -mod context_action; -use config::Config; pub mod config; +mod context_action; pub mod dialog; mod key_bind; pub(crate) mod large_image; @@ -25,13 +29,11 @@ mod mounter; mod mouse_area; pub mod operation; mod spawn_detached; -use tab::Location; -mod zoom; - -use crate::config::State; pub mod tab; mod thumbnail_cacher; mod thumbnailer; +pub(crate) mod trash; +mod zoom; pub(crate) type FxOrderMap = ordermap::OrderMap; diff --git a/src/menu.rs b/src/menu.rs index 8db61d7..89e4a02 100644 --- a/src/menu.rs +++ b/src/menu.rs @@ -23,6 +23,7 @@ use crate::{ config::{Config, ContextActionPreset}, fl, tab::{self, HeadingOptions, Location, LocationMenuAction, SearchLocation, Tab}, + trash::{Trash, TrashExt}, }; static MENU_ID: LazyLock = @@ -192,7 +193,7 @@ pub fn context_menu<'a>( ) => { if selected_trash_only { children.push(menu_item(fl!("open"), Action::Open).into()); - if !trash::os_limited::is_empty().unwrap_or(true) { + if !Trash::is_empty() { children.push(menu_item(fl!("empty-trash"), Action::EmptyTrash).into()); } } else if let Some(entry) = selected_desktop_entry { diff --git a/src/operation/mod.rs b/src/operation/mod.rs index f9fae0d..b4a66e9 100644 --- a/src/operation/mod.rs +++ b/src/operation/mod.rs @@ -1125,7 +1125,9 @@ impl Operation { #[cfg(target_os = "macos")] Self::Restore { .. } => { // TODO: add support for macos - return OperationError::from_msg("Restoring from trash is not supported on macos"); + return Err(OperationError::from_msg( + "Restoring from trash is not supported on macos", + )); } #[cfg(not(target_os = "macos"))] Self::Restore { items } => { diff --git a/src/tab.rs b/src/tab.rs index 9d9d2a2..a350f08 100644 --- a/src/tab.rs +++ b/src/tab.rs @@ -39,7 +39,6 @@ use icu::{ use image::{DynamicImage, ImageReader}; use jiff_icu::ConvertFrom; use mime_guess::{Mime, mime}; -use regex::Regex; use rustc_hash::FxHashMap; use serde::{Deserialize, Serialize}; use std::{ @@ -84,6 +83,7 @@ use crate::{ operation::{Controller, OperationError}, thumbnail_cacher::{CachedThumbnail, ThumbnailCacher, ThumbnailSize}, thumbnailer::thumbnailer, + trash::{Trash, TrashExt}, }; use uzers::{get_group_by_gid, get_user_by_uid}; @@ -1168,133 +1168,7 @@ pub fn scan_search bool + Sync>( } } SearchLocation::Trash => { - trash_helpers::scan_search_trash(callback, ®ex); - } - } -} - -// This config statement is from trash::os_limited, inverted -#[cfg(not(any( - target_os = "windows", - all( - unix, - not(target_os = "macos"), - not(target_os = "ios"), - not(target_os = "android") - ) -)))] -mod trash_helpers { - use super::*; - - pub fn trash_entries() -> usize { - 0 - } - - pub fn trash_icon(icon_size: u16) -> widget::icon::Handle { - widget::icon::from_name("user-trash") - .size(icon_size) - .handle() - } - - pub fn trash_icon_symbolic(icon_size: u16) -> widget::icon::Handle { - widget::icon::from_name("user-trash-symbolic") - .size(icon_size) - .handle() - } - - pub fn scan_trash(_sizes: IconSizes) -> Vec { - log::warn!("viewing trash not supported on this platform"); - Vec::new() - } - - pub fn scan_search_trash bool + Sync>(callback: F, regex: &Regex) {} -} - -// This config statement is from trash::os_limited -#[cfg(any( - target_os = "windows", - all( - unix, - not(target_os = "macos"), - not(target_os = "ios"), - not(target_os = "android") - ) -))] -pub mod trash_helpers { - use super::*; - - pub fn trash_entries() -> usize { - match trash::os_limited::list() { - Ok(entries) => entries.len(), - Err(_err) => 0, - } - } - - pub fn trash_icon(icon_size: u16) -> widget::icon::Handle { - widget::icon::from_name(if trash::os_limited::is_empty().unwrap_or(true) { - "user-trash" - } else { - "user-trash-full" - }) - .size(icon_size) - .handle() - } - - pub fn trash_icon_symbolic(icon_size: u16) -> widget::icon::Handle { - widget::icon::from_name(if trash::os_limited::is_empty().unwrap_or(true) { - "user-trash-symbolic" - } else { - "user-trash-full-symbolic" - }) - .size(icon_size) - .handle() - } - - pub fn scan_trash(sizes: IconSizes) -> Vec { - let entries = match trash::os_limited::list() { - Ok(entry) => entry, - Err(err) => { - log::warn!("failed to read trash items: {err}"); - return Vec::new(); - } - }; - let mut items: Vec<_> = entries - .into_iter() - .filter_map(|entry| { - let metadata = trash::os_limited::metadata(&entry) - .inspect_err(|err| { - log::warn!("failed to get metadata for trash item {entry:?}: {err}") - }) - .ok()?; - Some(item_from_trash_entry(entry, metadata, sizes)) - }) - .collect(); - items.sort_by(|a, b| match (a.metadata.is_dir(), b.metadata.is_dir()) { - (true, false) => Ordering::Less, - (false, true) => Ordering::Greater, - _ => LANGUAGE_SORTER.compare(&a.display_name, &b.display_name), - }); - items - } - - pub fn scan_search_trash bool + Sync>(callback: F, regex: &Regex) { - let entries = match trash::os_limited::list() { - Ok(entries) => entries, - Err(err) => { - log::warn!("failed to read trash items: {err}"); - return; - } - }; - - for entry in entries { - if let Ok(metadata) = trash::os_limited::metadata(&entry).inspect_err(|err| { - log::warn!("failed to get metadata for trash item {entry:?}: {err}") - }) { - let name = entry.name.to_string_lossy(); - if regex.is_match(&name) && !callback(SearchItem::Trash(entry, metadata)) { - break; - } - } + Trash::scan_search(callback, ®ex); } } } @@ -1432,15 +1306,15 @@ pub fn scan_desktop( let display_name = Item::display_name(&name); let metadata = ItemMetadata::SimpleDir { - entries: trash_helpers::trash_entries() as u64, + entries: Trash::entries() as u64, }; let (mime, icon_handle_grid, icon_handle_list, icon_handle_list_condensed) = { ( "inode/directory".parse().unwrap(), - trash_helpers::trash_icon(sizes.grid()), - trash_helpers::trash_icon(sizes.list()), - trash_helpers::trash_icon(sizes.list_condensed()), + Trash::icon(sizes.grid()), + Trash::icon(sizes.list()), + Trash::icon(sizes.list_condensed()), ) }; @@ -1681,7 +1555,7 @@ impl Location { // Search is done incrementally Vec::new() } - Self::Trash => trash_helpers::scan_trash(sizes), + Self::Trash => Trash::scan(sizes), Self::Recents => scan_recents(sizes), Self::Network(uri, _, _) => scan_network(uri, sizes), }; diff --git a/src/trash.rs b/src/trash.rs new file mode 100644 index 0000000..0262ba9 --- /dev/null +++ b/src/trash.rs @@ -0,0 +1,143 @@ +use cosmic::widget; +use regex::Regex; +use std::{collections::HashSet, path::PathBuf}; + +use crate::{ + config::IconSizes, + tab::{Item, SearchItem}, +}; + +pub trait TrashExt { + fn is_empty() -> bool { + true + } + + fn entries() -> usize { + 0 + } + + fn folders() -> Result, trash::Error> { + Err(trash::Error::Unknown { + description: "reading trash folders not supported on this platform".into(), + }) + } + + fn scan(_sizes: IconSizes) -> Vec { + log::warn!("viewing trash not supported on this platform"); + Vec::new() + } + + fn scan_search bool + Sync>(callback: F, regex: &Regex) {} + + fn icon(icon_size: u16) -> widget::icon::Handle { + widget::icon::from_name(if Self::is_empty() { + "user-trash" + } else { + "user-trash-full" + }) + .size(icon_size) + .handle() + } + + fn icon_symbolic(icon_size: u16) -> widget::icon::Handle { + widget::icon::from_name(if Self::is_empty() { + "user-trash-symbolic" + } else { + "user-trash-full-symbolic" + }) + .size(icon_size) + .handle() + } +} + +pub struct Trash; + +// This config statement is from trash::os_limited +#[cfg(any( + target_os = "windows", + all( + unix, + not(target_os = "macos"), + not(target_os = "ios"), + not(target_os = "android") + ) +))] +impl TrashExt for Trash { + fn is_empty() -> bool { + trash::os_limited::is_empty().unwrap_or(true) + } + + fn entries() -> usize { + match trash::os_limited::list() { + Ok(entries) => entries.len(), + Err(_err) => 0, + } + } + + fn folders() -> Result, trash::Error> { + trash::os_limited::trash_folders() + } + + fn scan(sizes: IconSizes) -> Vec { + use crate::{localize::LANGUAGE_SORTER, tab::item_from_trash_entry}; + use std::cmp::Ordering; + + let entries = match trash::os_limited::list() { + Ok(entry) => entry, + Err(err) => { + log::warn!("failed to read trash items: {err}"); + return Vec::new(); + } + }; + let mut items: Vec<_> = entries + .into_iter() + .filter_map(|entry| { + let metadata = trash::os_limited::metadata(&entry) + .inspect_err(|err| { + log::warn!("failed to get metadata for trash item {entry:?}: {err}") + }) + .ok()?; + Some(item_from_trash_entry(entry, metadata, sizes)) + }) + .collect(); + items.sort_by(|a, b| match (a.metadata.is_dir(), b.metadata.is_dir()) { + (true, false) => Ordering::Less, + (false, true) => Ordering::Greater, + _ => LANGUAGE_SORTER.compare(&a.display_name, &b.display_name), + }); + items + } + + fn scan_search bool + Sync>(callback: F, regex: &Regex) { + let entries = match trash::os_limited::list() { + Ok(entries) => entries, + Err(err) => { + log::warn!("failed to read trash items: {err}"); + return; + } + }; + + for entry in entries { + if let Ok(metadata) = trash::os_limited::metadata(&entry).inspect_err(|err| { + log::warn!("failed to get metadata for trash item {entry:?}: {err}") + }) { + let name = entry.name.to_string_lossy(); + if regex.is_match(&name) && !callback(SearchItem::Trash(entry, metadata)) { + break; + } + } + } + } +} + +// This config statement is from trash::os_limited, inverted +#[cfg(not(any( + target_os = "windows", + all( + unix, + not(target_os = "macos"), + not(target_os = "ios"), + not(target_os = "android") + ) +)))] +impl TrashExt for Trash {} From 62bfcc3550cdac1a492b1f4c040e09aa7de09bc3 Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Fri, 17 Apr 2026 12:41:02 -0600 Subject: [PATCH 17/20] Put libcosmic/desktop behind desktop feature --- Cargo.toml | 3 +-- src/app.rs | 16 ++++++++++------ src/tab.rs | 19 ++++++++++++++++--- src/thumbnailer.rs | 1 + 4 files changed, 28 insertions(+), 11 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 9ef9807..949f99d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -81,7 +81,6 @@ features = [ "about", "advanced-shaping", "autosize", - "desktop", "multi-window", "tokio", "winit", @@ -113,7 +112,7 @@ default = [ "wgpu", ] dbus-config = ["libcosmic/dbus-config"] -desktop = ["dep:cosmic-mime-apps", "dep:xdg"] +desktop = ["libcosmic/desktop", "dep:cosmic-mime-apps", "dep:xdg"] desktop-applet = [] gvfs = ["dep:gio", "dep:glib"] io-uring = ["compio/io-uring"] diff --git a/src/app.rs b/src/app.rs index af0ecbe..feca9c5 100644 --- a/src/app.rs +++ b/src/app.rs @@ -18,9 +18,7 @@ use cosmic::{ Application, ApplicationExt, Element, app::{self, Core, Task, context_drawer}, cosmic_config::{self, ConfigSet}, - cosmic_theme, - desktop::fde::DesktopEntry, - executor, + cosmic_theme, executor, iced::core::widget::operation::focusable::unfocus, iced::runtime::{clipboard, task}, iced::widget::{button::focus, scrollable::AbsoluteOffset}, @@ -835,9 +833,12 @@ impl App { // First launch apps that can be launched directly if mime == "application/x-desktop" { - // Try opening desktop application - Self::launch_desktop_entries(&paths); - continue; + #[cfg(feature = "desktop")] + { + // Try opening desktop application + Self::launch_desktop_entries(&paths); + continue; + } } else if mime == "application/x-executable" || mime == "application/vnd.appimage" { // Try opening executable for path in paths { @@ -898,7 +899,10 @@ impl App { Task::batch(tasks) } + #[cfg(feature = "desktop")] fn launch_desktop_entries(paths: &[impl AsRef]) { + use cosmic::desktop::fde::DesktopEntry; + for path in paths.iter().map(AsRef::as_ref) { match DesktopEntry::from_path::<&str>(path, None) { Ok(entry) => match entry.exec() { diff --git a/src/tab.rs b/src/tab.rs index a350f08..2aeea04 100644 --- a/src/tab.rs +++ b/src/tab.rs @@ -1,7 +1,7 @@ +#[cfg(feature = "desktop")] +use cosmic::desktop::fde::{DesktopEntry, get_languages_from_env}; use cosmic::{ - Apply, Element, cosmic_theme, - desktop::fde::{DesktopEntry, get_languages_from_env}, - font, + Apply, Element, cosmic_theme, font, iced::core::{mouse::ScrollDelta, widget::tree}, iced::{ Alignment, Border, Color, ContentFit, Length, Point, Rectangle, Size, Subscription, Vector, @@ -557,6 +557,12 @@ pub fn fs_kind(_metadata: &Metadata) -> FsKind { FsKind::Local } +#[cfg(not(feature = "desktop"))] +fn get_desktop_file_display_name(path: &Path) -> Option { + None +} + +#[cfg(feature = "desktop")] fn get_desktop_file_display_name(path: &Path) -> Option { let locales = get_languages_from_env(); let entry = match DesktopEntry::from_path(path, Some(&locales)) { @@ -570,6 +576,12 @@ fn get_desktop_file_display_name(path: &Path) -> Option { entry.name(&locales).map(|s| s.into_owned()) } +#[cfg(not(feature = "desktop"))] +fn get_desktop_file_icon(path: &Path) -> Option { + None +} + +#[cfg(feature = "desktop")] fn get_desktop_file_icon(path: &Path) -> Option { let entry = match DesktopEntry::from_path::<&str>(path, None) { Ok(ok) => ok, @@ -593,6 +605,7 @@ fn desktop_icon_handle(icon: &str, size: u16) -> widget::icon::Handle { } } +#[cfg(feature = "desktop")] pub fn parse_desktop_file(path: &Path) -> (Option, Option) { let locales = get_languages_from_env(); let entry = match DesktopEntry::from_path(path, Some(&locales)) { diff --git a/src/thumbnailer.rs b/src/thumbnailer.rs index f996f03..f7786ed 100644 --- a/src/thumbnailer.rs +++ b/src/thumbnailer.rs @@ -1,6 +1,7 @@ // Copyright 2023 System76 // SPDX-License-Identifier: GPL-3.0-only +#[cfg(feature = "desktop")] use cosmic::desktop::fde::GenericEntry; use mime_guess::Mime; use rustc_hash::FxHashMap; From 8c57060db206c13a12a97c6946663a2197529a47 Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Fri, 17 Apr 2026 12:48:39 -0600 Subject: [PATCH 18/20] Only use uzers on unix, do not fork on mac --- Cargo.toml | 2 +- src/lib.rs | 2 +- src/tab.rs | 11 ++++++----- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 949f99d..c1b75ae 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -55,7 +55,6 @@ rust-embed = "8" slotmap = "1.1.1" recently-used-xbel = "1.2.0" zip = "8" -uzers = "0.12.2" md-5 = "0.10.6" png = "0.18" jxl-oxide = { version = "0.12.5", features = ["image"] } @@ -130,6 +129,7 @@ debug = true [target.'cfg(unix)'.dependencies] fork = "0.7" +uzers = "0.12.2" [target.'cfg(target_os = "linux")'.dependencies] procfs = "0.18" diff --git a/src/lib.rs b/src/lib.rs index 644b64d..3e89861 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -191,7 +191,7 @@ pub fn main() -> Result<(), Box> { } if daemonize { - #[cfg(all(unix, not(target_os = "redox")))] + #[cfg(all(unix, not(any(target_os = "macos", target_os = "redox"))))] match fork::daemon(true, true) { Ok(fork::Fork::Child) => (), Ok(fork::Fork::Parent(_child_pid)) => process::exit(0), diff --git a/src/tab.rs b/src/tab.rs index 2aeea04..82dd03d 100644 --- a/src/tab.rs +++ b/src/tab.rs @@ -85,7 +85,6 @@ use crate::{ thumbnailer::thumbnailer, trash::{Trash, TrashExt}, }; -use uzers::{get_group_by_gid, get_user_by_uid}; pub const DOUBLE_CLICK_DURATION: Duration = Duration::from_millis(500); pub const HOVER_DURATION: Duration = Duration::from_millis(1600); @@ -2429,7 +2428,7 @@ impl Item { let mode = metadata.mode(); - let user_name = get_user_by_uid(metadata.uid()) + let user_name = uzers::get_user_by_uid(metadata.uid()) .and_then(|user| user.name().to_str().map(ToOwned::to_owned)) .unwrap_or_default(); let user_path = path.clone(); @@ -2452,7 +2451,7 @@ impl Item { )), ); - let group_name = get_group_by_gid(metadata.gid()) + let group_name = uzers::get_group_by_gid(metadata.gid()) .and_then(|group| group.name().to_str().map(ToOwned::to_owned)) .unwrap_or_default(); let group_path = path.clone(); @@ -6358,14 +6357,16 @@ impl Tab { total_size = total_size.saturating_add(metadata.len()); } let mode = metadata.mode(); + #[cfg(unix)] user_name.insert( - get_user_by_uid(metadata.uid()) + uzers::get_user_by_uid(metadata.uid()) .and_then(|user| user.name().to_str().map(ToOwned::to_owned)) .unwrap_or_default(), ); mode_user.insert(get_mode_part(mode, MODE_SHIFT_USER)); + #[cfg(unix)] group_name.insert( - get_group_by_gid(metadata.gid()) + uzers::get_group_by_gid(metadata.gid()) .and_then(|group| group.name().to_str().map(ToOwned::to_owned)) .unwrap_or_default(), ); From 4afacccc8adf2df7ef4c127f961d1cc2d20e5c89 Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Fri, 17 Apr 2026 13:31:55 -0600 Subject: [PATCH 19/20] Fix windows compilation issues --- src/archive.rs | 14 ++++++++++---- src/mime_icon.rs | 25 ++++++++++++++++++++++++- src/tab.rs | 35 +++++++++++++++++++---------------- src/thumbnail_cacher.rs | 5 ++++- src/trash.rs | 2 ++ 5 files changed, 59 insertions(+), 22 deletions(-) diff --git a/src/archive.rs b/src/archive.rs index 92024d8..ba11cbb 100644 --- a/src/archive.rs +++ b/src/archive.rs @@ -189,6 +189,8 @@ fn zip_extract>( if file.is_symlink() && (cfg!(unix) || cfg!(windows)) { let mut target = Vec::with_capacity(file.size() as usize); file.read_to_end(&mut target)?; + // File no longer needed, drop to allow reading target on windows + drop(file); #[cfg(unix)] { @@ -199,11 +201,15 @@ fn zip_extract>( #[cfg(windows)] { let Ok(target) = String::from_utf8(target) else { - return Err(ZipError::InvalidArchive("Invalid UTF-8 as symlink target")); + return Err(ZipError::InvalidArchive( + "Invalid UTF-8 as symlink target".into(), + )); }; - let target = target.into_boxed_str(); - let target_is_dir_from_archive = - archive.shared.files.contains_key(&target) && is_dir(&target); + let target_is_dir_from_archive = match password { + None => archive.by_name(&target), + Some(pwd) => archive.by_name_decrypt(&target, pwd.as_bytes()), + } + .map_or(false, |x| x.is_dir()); let target_path = directory.as_ref().join(OsString::from(target.to_string())); let target_is_dir = if target_is_dir_from_archive { true diff --git a/src/mime_icon.rs b/src/mime_icon.rs index 52b1a27..8d8d2e5 100644 --- a/src/mime_icon.rs +++ b/src/mime_icon.rs @@ -19,6 +19,7 @@ struct MimeIconKey { struct MimeIconCache { cache: FxHashMap>, + #[cfg(unix)] shared_mime_info: xdg_mime::SharedMimeInfo, } @@ -26,10 +27,17 @@ impl MimeIconCache { pub fn new() -> Self { Self { cache: FxHashMap::default(), + #[cfg(unix)] shared_mime_info: xdg_mime::SharedMimeInfo::new(), } } + #[cfg(not(unix))] + pub fn get(&mut self, _key: MimeIconKey) -> Option { + None + } + + #[cfg(unix)] pub fn get(&mut self, key: MimeIconKey) -> Option { self.cache .entry(key) @@ -53,6 +61,16 @@ impl MimeIconCache { static MIME_ICON_CACHE: LazyLock> = LazyLock::new(|| Mutex::new(MimeIconCache::new())); +#[cfg(not(unix))] +pub fn mime_for_path( + path: impl AsRef, + metadata_opt: Option<&fs::Metadata>, + remote: bool, +) -> Mime { + mime_guess::from_path(path).first_or_octet_stream() +} + +#[cfg(unix)] pub fn mime_for_path( path: impl AsRef, metadata_opt: Option<&fs::Metadata>, @@ -100,8 +118,13 @@ pub fn mime_icon(mime: Mime, size: u16) -> icon::Handle { } } +#[cfg(not(unix))] +pub fn parent_mime_types(_mime: &Mime) -> Option> { + None +} + +#[cfg(unix)] pub fn parent_mime_types(mime: &Mime) -> Option> { let mime_icon_cache = MIME_ICON_CACHE.lock().unwrap(); - mime_icon_cache.shared_mime_info.get_parents_aliased(mime) } diff --git a/src/tab.rs b/src/tab.rs index 82dd03d..94eacdd 100644 --- a/src/tab.rs +++ b/src/tab.rs @@ -41,6 +41,8 @@ use jiff_icu::ConvertFrom; use mime_guess::{Mime, mime}; use rustc_hash::FxHashMap; use serde::{Deserialize, Serialize}; +#[cfg(unix)] +use std::os::unix::fs::MetadataExt; use std::{ borrow::Cow, cell::Cell, @@ -51,7 +53,6 @@ use std::{ fs::{self, File, Metadata}, hash::Hash, io::{BufRead, BufReader}, - os::unix::fs::MetadataExt, path::{self, Path, PathBuf}, sync::{Arc, LazyLock, RwLock, atomic}, time::{Duration, Instant, SystemTime}, @@ -4339,6 +4340,7 @@ impl Tab { for item in self.items_opt().map_or(Vec::new(), |items| { items.iter().filter(|item| item.selected).collect() }) { + #[cfg(unix)] if let (Some(path), Some(mode)) = ( item.path_opt(), item.file_metadata() @@ -6356,22 +6358,23 @@ impl Tab { } else { total_size = total_size.saturating_add(metadata.len()); } - let mode = metadata.mode(); #[cfg(unix)] - user_name.insert( - uzers::get_user_by_uid(metadata.uid()) - .and_then(|user| user.name().to_str().map(ToOwned::to_owned)) - .unwrap_or_default(), - ); - mode_user.insert(get_mode_part(mode, MODE_SHIFT_USER)); - #[cfg(unix)] - group_name.insert( - uzers::get_group_by_gid(metadata.gid()) - .and_then(|group| group.name().to_str().map(ToOwned::to_owned)) - .unwrap_or_default(), - ); - mode_group.insert(get_mode_part(mode, MODE_SHIFT_GROUP)); - mode_other.insert(get_mode_part(mode, MODE_SHIFT_OTHER)); + { + let mode = metadata.mode(); + user_name.insert( + uzers::get_user_by_uid(metadata.uid()) + .and_then(|user| user.name().to_str().map(ToOwned::to_owned)) + .unwrap_or_default(), + ); + mode_user.insert(get_mode_part(mode, MODE_SHIFT_USER)); + group_name.insert( + uzers::get_group_by_gid(metadata.gid()) + .and_then(|group| group.name().to_str().map(ToOwned::to_owned)) + .unwrap_or_default(), + ); + mode_group.insert(get_mode_part(mode, MODE_SHIFT_GROUP)); + mode_other.insert(get_mode_part(mode, MODE_SHIFT_OTHER)); + } } } let mut mime_types: Vec<(String, u64)> = mime_type_counts.into_iter().collect(); diff --git a/src/thumbnail_cacher.rs b/src/thumbnail_cacher.rs index 719bfc6..e4d616e 100644 --- a/src/thumbnail_cacher.rs +++ b/src/thumbnail_cacher.rs @@ -1,11 +1,12 @@ use image::DynamicImage; use md5::{Digest, Md5}; use rustc_hash::FxHashMap; +#[cfg(unix)] +use std::os::unix::fs::PermissionsExt; use std::{ error::Error, fs::{self, File}, io::{self, BufReader, BufWriter}, - os::unix::fs::PermissionsExt, path::{Path, PathBuf}, sync::LazyLock, time::UNIX_EPOCH, @@ -93,6 +94,7 @@ impl ThumbnailCacher { } pub fn update_with_temp_file(&self, temp_file: NamedTempFile) -> Result<&Path, Box> { + #[cfg(unix)] fs::set_permissions(temp_file.path(), fs::Permissions::from_mode(0o600))?; self.update_thumbnail_text_metadata(temp_file.path())?; fs::rename(temp_file.path(), &self.thumbnail_path)?; @@ -127,6 +129,7 @@ impl ThumbnailCacher { pub fn create_fail_marker(&self) -> Result<(), Box> { if let Some(dir) = self.thumbnail_fail_marker_path.parent() { fs::create_dir_all(dir)?; + #[cfg(unix)] fs::set_permissions(dir, fs::Permissions::from_mode(0o700))?; } diff --git a/src/trash.rs b/src/trash.rs index 0262ba9..ce37c83 100644 --- a/src/trash.rs +++ b/src/trash.rs @@ -74,6 +74,8 @@ impl TrashExt for Trash { } } + // Not available on Windows only + #[cfg(not(target_os = "windows"))] fn folders() -> Result, trash::Error> { trash::os_limited::trash_folders() } From 9bcfe7a1f58580c713e21703e5c2fb2acd397cda Mon Sep 17 00:00:00 2001 From: Votre Nom Date: Wed, 22 Apr 2026 15:13:55 +0200 Subject: [PATCH 20/20] Cargo.toml: patch libcosmic via local path for dev builds Activates the [patch.'https://github.com/pop-os/libcosmic'] override pointing at ../libcosmic, enabling local development against a patched libcosmic checkout (e.g. to pick up WindowControlsPosition / macOS-style window controls). This branch is intentionally dev-local: do NOT merge upstream. Co-Authored-By: Claude Opus 4.7 (1M context) --- Cargo.toml | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index c1b75ae..8f81194 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -147,13 +147,12 @@ tokio = { version = "1", features = ["rt", "macros"] } # [patch.'https://github.com/pop-os/cosmic-text'] # cosmic-text = { path = "../cosmic-text" } -# [patch.'https://github.com/pop-os/libcosmic'] -# libcosmic = { path = "../libcosmic" } -# cosmic-config = { path = "../libcosmic/cosmic-config" } -# cosmic-theme = { path = "../libcosmic/cosmic-theme" } -# libcosmic = { git = "https://github.com/pop-os/libcosmic//", branch = "iced-rebase" } -# cosmic-config = { git = "https://github.com/pop-os/libcosmic//", branch = "iced-rebase" } -# cosmic-theme = { git = "https://github.com/pop-os/libcosmic//", branch = "iced-rebase" } +[patch.'https://github.com/pop-os/libcosmic'] +libcosmic = { path = "../libcosmic" } +cosmic-config = { path = "../libcosmic/cosmic-config" } +cosmic-theme = { path = "../libcosmic/cosmic-theme" } +iced_futures = { path = "../libcosmic/iced/futures" } +iced_winit = { path = "../libcosmic/iced/winit" } # [patch.'https://github.com/pop-os/smithay-clipboard']