A fast file manager for Windows and macOS that never freezes: tabs, dual panes, archives as folders, Quick Look-style previews. A File Explorer and Finder alternative written in Rust.
Rust archive-managerdesktop-appdual-paneexplorer-alternativefile-browserfile-explorerfile-managerfluent-designgpu-acceleratedgpuimacosmicaproductivityquick-lookrustrust-guitabswindowswindows-11windows-explorer
settings: split Windows placeholder icons by folders/files and preview pane
NKrN229a1072e391d
diff --git a/crates/rf-app/src/ctx_menu.rs b/crates/rf-app/src/ctx_menu.rsindex 38ffe337..1cb95219 100644--- a/crates/rf-app/src/ctx_menu.rs+++ b/crates/rf-app/src/ctx_menu.rs@@ -352,7 +352,8 @@ impl FolderView {// Settings › "Windows' icons while pictures load": while that one is on its way, the icon its row shows (one per type,// most often at hand already), or none; never ours.or_else(|| {- if !crate::settings::windows_placeholder_icons() {+ let first_is_dir = single_dir || items.first().is_some_and(|p| p.is_dir());+ if !crate::settings::windows_placeholder_icons_for(first_is_dir) {return None;}Some(items.first().and_then(|p| self.row_icon_of(p, cx)).map(MenuIcon::Image).unwrap_or(MenuIcon::None))diff --git a/crates/rf-app/src/folder_view.rs b/crates/rf-app/src/folder_view.rsindex 50c425a7..31b05ce8 100644--- a/crates/rf-app/src/folder_view.rs+++ b/crates/rf-app/src/folder_view.rs@@ -1497,7 +1497,7 @@ impl FolderView {.child(div().flex_shrink_0().on_mouse_down(MouseButton::Left, cx.listener(|this, _: &MouseDownEvent, _, _| this.icon_hit = true)).child(download_marked(link_marked(faded(match &shell_icon {Some(im) => img(im.clone()).size(px(16.)).flex_shrink_0().into_any_element(),- None => crate::settings::loading_icon(icons::icon_for(cat), px(16.), theme::kind_color(cat, p.dark)),+ None => crate::settings::loading_icon(icons::icon_for(cat), px(16.), theme::kind_color(cat, p.dark), is_dir),}, dim, px(16.)),px(16.),e.link,@@ -3970,7 +3970,7 @@ impl FolderView {});// Settings › "Windows' icons while pictures load": until the tile's own picture comes, Windows' icon for the type (one for// every plain folder, one per file type) instead of ours- let placeholder = thumb.is_none() && cx.global::<crate::settings::Settings>().windows_placeholder_icons;+ let placeholder = thumb.is_none() && cx.global::<crate::settings::Settings>().windows_placeholder_icons.applies(e.is_dir());let thumb = if placeholder {self.parent_of(ei).map(|d| d.to_path_buf()).and_then(|d| self.images.update(cx, |c, cx| c.windows_icon(&d, e, thumb_px, cx)))} else {@@ -3986,7 +3986,7 @@ impl FolderView {let (fw, fh) = if iw >= ih { (visual_px, visual_px * (ih / iw)) } else { (visual_px * (iw / ih), visual_px) };(img(im).w(fw).h(fh).flex_shrink_0().object_fit(ObjectFit::Contain).when(is_thumb, |i| i.rounded(px(4.))).into_any_element(), visual_px)}- None => (crate::settings::loading_icon(icons::icon_for(cat), visual_px * 0.6, theme::kind_color(cat, p.dark)), visual_px * 0.6),+ None => (crate::settings::loading_icon(icons::icon_for(cat), visual_px * 0.6, theme::kind_color(cat, p.dark), e.is_dir()), visual_px * 0.6),};let visual = faded(visual, dim, drawn_px);// a video's thumbnail looked like a picture's: a small play mark in its corner (issue 452)@@ -6438,7 +6438,7 @@ impl FolderView {.child(div().flex_shrink_0().on_mouse_down(MouseButton::Left, cx.listener(|this, _: &MouseDownEvent, _, _| this.icon_hit = true)).child(download_marked(link_marked(faded(match &shell_icon {Some(im) => img(im.clone()).size(px(16.)).flex_shrink_0().into_any_element(),- None => crate::settings::loading_icon(icons::icon_for(cat), px(16.), theme::kind_color(cat, p.dark)),+ None => crate::settings::loading_icon(icons::icon_for(cat), px(16.), theme::kind_color(cat, p.dark), e.is_dir()),}, dim, px(16.)),px(16.),e.link,@@ -7167,8 +7167,9 @@ impl FolderView {crate::icon_theme::image_names(cat, ext)};let picture = item_icon(cx, &r.target, &names, cat, ext, is_dir, 16.);+ let use_win = windows_icons.applies(is_dir);// Settings › "Windows' icons while pictures load": Windows' own icon for the item's type, as the lists show, instead of ours- let picture = match (picture, windows_icons, r.target.parent()) {+ let picture = match (picture, use_win, r.target.parent()) {(None, true, Some(dir)) => self.images.update(cx, |c, cx| c.windows_icon(dir, &e, crate::image_cache::ICON_PX, cx)),(picture, _, _) => picture,};@@ -7189,7 +7190,7 @@ impl FolderView {.cursor_pointer()// (with Windows' icons, nothing of ours stands in for one still on its way).child(match picture {- None if windows_icons => div().size(px(16.)).flex_shrink_0().into_any_element(),+ None if use_win => div().size(px(16.)).flex_shrink_0().into_any_element(),picture => home_icon(picture, icons::icon_for(cat), 16., Some(theme::kind_color(cat, p.dark))),}).child(div().w(px(260.)).flex_shrink_0().overflow_hidden().text_ellipsis().whitespace_nowrap().child(shown))@@ -7723,7 +7724,7 @@ fn static_column(.when(!on, |d| d.hover(|s| s.bg(hover)).text_color(pal.text_secondary)).child(match &shell_icon {Some(im) => img(im.clone()).size(px(16.)).flex_shrink_0().into_any_element(),- None => crate::settings::loading_icon(icons::icon_for(cat), px(16.), theme::kind_color(cat, pal.dark)),+ None => crate::settings::loading_icon(icons::icon_for(cat), px(16.), theme::kind_color(cat, pal.dark), is_dir),}).child(div().flex_1().min_w_0().overflow_hidden().text_ellipsis().whitespace_nowrap().child(crate::rtl::display_text(&shown_name(e, show_ext)))).when(is_dir, |d| d.child(Icon::new(L::ChevronRight).size(px(12.)).text_color(pal.text_tertiary)))diff --git a/crates/rf-app/src/i18n_en.rs b/crates/rf-app/src/i18n_en.rsindex 947f8254..41a0bfb6 100644--- a/crates/rf-app/src/i18n_en.rs+++ b/crates/rf-app/src/i18n_en.rs@@ -925,6 +925,9 @@ pub const EN: &[(&str, &str)] = &[("Öğeleri tek tıklamayla aç", "Open items with a single click"),("Asla", "Never"),("Yalnızca klasörler", "Folders only"),+ ("Yalnızca dosyalar", "Files only"),+ ("Yukarıdakiyle aynı", "Same as above"),+ ("Önizleme panelinde küçük resmi olmayan öğeler için Windows simgeleri", "Windows' icons in the preview pane for items without a thumbnail"),("Her zaman", "Always"),("Klasörleri yeni sekmede aç", "Open folders in a new tab"),("Silmeden önce onay iste", "Confirm before deleting"),diff --git a/crates/rf-app/src/preview.rs b/crates/rf-app/src/preview.rsindex c36b2cfa..ddc50773 100644--- a/crates/rf-app/src/preview.rs+++ b/crates/rf-app/src/preview.rs@@ -1116,9 +1116,10 @@ impl Render for Preview {} else {self.hide_host();let thumb = self.thumb_or_hold(&dir, &e, PREVIEW_PX, cx);- // Settings › "Windows' icons while pictures load": what has no picture shows Windows' own big icon for its type (a- // folder's, a program's own), as Explorer's preview pane does, instead of ours- let windows_icon = if thumb.is_none() && cx.global::<crate::settings::Settings>().windows_placeholder_icons {+ // Settings › "Windows' icons while pictures load" › "Preview pane": what has no picture shows Windows' own big icon for its+ // type (a folder's, a program's own), as Explorer's preview pane does, instead of ours+ let preview_win_icons = cx.global::<crate::settings::Settings>().effective_windows_preview_icons().applies(e.is_dir());+ let windows_icon = if thumb.is_none() && preview_win_icons {self.images.update(cx, |c, cx| c.windows_icon(&dir, &e, 256, cx))} else {None@@ -1126,7 +1127,8 @@ impl Render for Preview {let visual: AnyElement = match (thumb, windows_icon) {(Some(im), _) => img(im).w_full().map(|i| if fill { i.h_full() } else { i.h(px(220.)) }).object_fit(ObjectFit::Contain).into_any_element(),(None, Some(icon)) => img(icon).size(px(128.)).object_fit(ObjectFit::Contain).into_any_element(),- (None, None) => crate::settings::loading_icon(icons::icon_for(cat), px(96.), theme::kind_color(cat, p.dark)),+ (None, None) if preview_win_icons => div().size(px(96.)).flex_shrink_0().into_any_element(),+ (None, None) => Icon::new(icons::icon_for(cat)).size(px(96.)).flex_shrink_0().text_color(theme::kind_color(cat, p.dark)).into_any_element(),};div().w_full()diff --git a/crates/rf-app/src/settings.rs b/crates/rf-app/src/settings.rsindex 1dac5716..cbbf5cde 100644--- a/crates/rf-app/src/settings.rs+++ b/crates/rf-app/src/settings.rs@@ -311,6 +311,89 @@ pub enum ClickPref {Always,}+/// Settings › Files & folders › "Windows' icons while pictures load": which items show Windows' icon for their type (a folder's, a+/// file type's, a custom one) until their own picture comes, and in the preview pane when they have none (issue 695).+///+/// Backwards-compatible with the original boolean setting: `false` loads as [`Self::Off`] and `true` loads as [`Self::All`], and those+/// two save back as booleans so older builds keep reading the file unchanged.+#[derive(Debug, Clone, Copy, PartialEq, Eq, Default)]+pub enum PlaceholderIconsPref {+ #[default]+ Off,+ Folders,+ Files,+ All,+}++impl PlaceholderIconsPref {+ /// Whether an item (`is_dir`: folder vs file/image) uses Windows' icon while its own picture loads.+ pub fn applies(self, is_dir: bool) -> bool {+ match self {+ Self::Off => false,+ Self::Folders => is_dir,+ Self::Files => !is_dir,+ Self::All => true,+ }+ }++ pub fn as_u8(self) -> u8 {+ match self {+ Self::Off => 0,+ Self::Folders => 1,+ Self::Files => 2,+ Self::All => 3,+ }+ }++ pub fn from_u8(v: u8) -> Self {+ match v {+ 1 => Self::Folders,+ 2 => Self::Files,+ 3 => Self::All,+ _ => Self::Off,+ }+ }+}++impl Serialize for PlaceholderIconsPref {+ fn serialize<S: serde::Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error> {+ match self {+ Self::Off => serializer.serialize_bool(false),+ Self::Folders => serializer.serialize_str("folders"),+ Self::Files => serializer.serialize_str("files"),+ Self::All => serializer.serialize_bool(true),+ }+ }+}++impl<'de> Deserialize<'de> for PlaceholderIconsPref {+ fn deserialize<D: serde::Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error> {+ struct Visitor;+ impl serde::de::Visitor<'_> for Visitor {+ type Value = PlaceholderIconsPref;++ fn expecting(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {+ f.write_str("a boolean or one of \"off\", \"folders\", \"files\", \"all\"")+ }++ fn visit_bool<E: serde::de::Error>(self, v: bool) -> Result<Self::Value, E> {+ Ok(if v { PlaceholderIconsPref::All } else { PlaceholderIconsPref::Off })+ }++ fn visit_str<E: serde::de::Error>(self, v: &str) -> Result<Self::Value, E> {+ match v.trim().to_ascii_lowercase().as_str() {+ "off" | "none" | "never" | "false" => Ok(PlaceholderIconsPref::Off),+ "folders" | "folder" => Ok(PlaceholderIconsPref::Folders),+ "files" | "file" => Ok(PlaceholderIconsPref::Files),+ "all" | "both" | "always" | "true" => Ok(PlaceholderIconsPref::All),+ _ => Err(E::invalid_value(serde::de::Unexpected::Str(v), &self)),+ }+ }+ }+ deserializer.deserialize_any(Visitor)+ }+}+#[derive(Debug, Clone, Copy, PartialEq, Eq, Serialize, Deserialize, Default)]#[serde(rename_all = "lowercase")]pub enum IdePref {@@ -868,9 +951,13 @@ pub struct Settings {/// Names starting with "." count as hidden when off.pub show_dot_files: bool,pub show_thumbnails: bool,- /// Until an item's own picture comes, and in the preview pane for what has none, Windows' icon for its type (a folder's, a file- /// type's, a custom one) instead of ours; while Windows' icon is on its way, nothing (issue 695).- pub windows_placeholder_icons: bool,+ /// Until an item's own picture comes, Windows' icon for its type (a folder's, a file type's, a custom one) instead of ours;+ /// while Windows' icon is on its way, nothing (issue 695).+ pub windows_placeholder_icons: PlaceholderIconsPref,+ /// Independent override for Windows' icons in the preview pane (items without a thumbnail). `None` follows+ /// [`Self::windows_placeholder_icons`] so existing configurations keep their behaviour unchanged.+ #[serde(default, skip_serializing_if = "Option::is_none")]+ pub windows_preview_icons: Option<PlaceholderIconsPref>,/// The bookmarks bar under the address bar (`bookmarks`, issue 694).pub bookmarks_bar: bool,/// A bookmark dragged along the bar takes its new place while it is dragged, the others making room, as tabs do in a browser,@@ -1376,7 +1463,8 @@ impl Default for Settings {show_system_files: false,show_dot_files: true,show_thumbnails: true,- windows_placeholder_icons: false,+ windows_placeholder_icons: PlaceholderIconsPref::Off,+ windows_preview_icons: None,bookmarks_bar: false,bookmarks_live_drag: true,bookmarks_bar_tab_height: false,@@ -1537,7 +1625,7 @@ static ICON_PACK: std::sync::OnceLock<parking_lot::RwLock<String>> = std::sync::static HG_SURFACE: AtomicU8 = AtomicU8::new(HG_DEFAULT[4]);static SOLID: std::sync::atomic::AtomicBool = std::sync::atomic::AtomicBool::new(false);static HOME_RECENT_OWN_MENU: std::sync::atomic::AtomicBool = std::sync::atomic::AtomicBool::new(false);-static WINDOWS_PLACEHOLDER_ICONS: std::sync::atomic::AtomicBool = std::sync::atomic::AtomicBool::new(false);+static WINDOWS_PLACEHOLDER_ICONS: AtomicU8 = AtomicU8::new(0);static SOLID_CLEARTYPE: std::sync::atomic::AtomicBool = std::sync::atomic::AtomicBool::new(false);static EXPLORER_METRICS: std::sync::atomic::AtomicBool = std::sync::atomic::AtomicBool::new(false);static COMPACT_MENUS: std::sync::atomic::AtomicBool = std::sync::atomic::AtomicBool::new(false);@@ -1569,14 +1657,19 @@ pub fn home_recent_own_menu() -> bool {}/// Settings › "Windows' icons while pictures load", read where there is no `App` at hand.-pub fn windows_placeholder_icons() -> bool {- WINDOWS_PLACEHOLDER_ICONS.load(Ordering::Relaxed)+pub fn windows_placeholder_icons() -> PlaceholderIconsPref {+ PlaceholderIconsPref::from_u8(WINDOWS_PLACEHOLDER_ICONS.load(Ordering::Relaxed))}-/// The picture of an item whose own (Windows') icon has not come yet: ours, or with `windows_placeholder_icons` an empty box of its-/// size, so that nothing of ours shows for a moment before Windows' icon.-pub fn loading_icon(icon: gpui_kit::assets::IconName, size: Pixels, color: Hsla) -> AnyElement {- if windows_placeholder_icons() {+/// Whether Windows' placeholder icons are enabled for an item of this kind (`is_dir`: folder vs file/image).+pub fn windows_placeholder_icons_for(is_dir: bool) -> bool {+ windows_placeholder_icons().applies(is_dir)+}++/// The picture of an item whose own (Windows') icon has not come yet: ours, or when `windows_placeholder_icons` applies to this item+/// kind an empty box of its size, so that nothing of ours shows for a moment before Windows' icon.+pub fn loading_icon(icon: gpui_kit::assets::IconName, size: Pixels, color: Hsla, is_dir: bool) -> AnyElement {+ if windows_placeholder_icons_for(is_dir) {div().size(size).flex_shrink_0().into_any_element()} else {gpui_kit::component::Icon::new(icon).size(size).flex_shrink_0().text_color(color).into_any_element()@@ -1894,6 +1987,11 @@ impl Settings {[self.hg_frost, self.hg_tint, self.hg_refraction, self.hg_saturation, self.hg_surface] = HG_DEFAULT;}+ /// Which items use Windows' icons in the preview pane: the independent override when set, otherwise [`Self::windows_placeholder_icons`].+ pub fn effective_windows_preview_icons(&self) -> PlaceholderIconsPref {+ self.windows_preview_icons.unwrap_or(self.windows_placeholder_icons)+ }+/// For "Import settings".pub fn parse_lenient_pub(text: &str) -> Result<Settings, toml::de::Error> {Self::parse_lenient(text)@@ -1927,7 +2025,7 @@ impl Settings {rf_core::format::set_binary_prefixes(self.binary_prefixes);SOLID.store(self.backdrop == BackdropPref::Solid, Ordering::Relaxed);HOME_RECENT_OWN_MENU.store(self.menu.home_recent_own_menu, Ordering::Relaxed);- WINDOWS_PLACEHOLDER_ICONS.store(self.windows_placeholder_icons, Ordering::Relaxed);+ WINDOWS_PLACEHOLDER_ICONS.store(self.windows_placeholder_icons.as_u8(), Ordering::Relaxed);SOLID_CLEARTYPE.store(self.solid_cleartype, Ordering::Relaxed);EXPLORER_METRICS.store(self.windows_file_explorer_theme && self.explorer_metrics, Ordering::Relaxed);COMPACT_MENUS.store(self.windows_file_explorer_theme && self.compact_menus, Ordering::Relaxed);@@ -2423,6 +2521,52 @@ theme = \"dark\"assert!(s.show_hidden);assert_eq!(s.theme, super::ThemePref::Dark);}++ #[test]+ fn placeholder_icons_applies_by_item_kind() {+ use super::PlaceholderIconsPref as P;+ assert!(!P::Off.applies(true) && !P::Off.applies(false));+ assert!(P::Folders.applies(true) && !P::Folders.applies(false));+ assert!(!P::Files.applies(true) && P::Files.applies(false));+ assert!(P::All.applies(true) && P::All.applies(false));+ for pref in [P::Off, P::Folders, P::Files, P::All] {+ assert_eq!(P::from_u8(pref.as_u8()), pref);+ }+ assert_eq!(P::from_u8(99), P::Off);+ }++ #[test]+ fn placeholder_icons_round_trip_and_legacy_booleans() {+ use super::PlaceholderIconsPref as P;+ // legacy booleans still load and save as booleans+ assert_eq!(Settings::parse_lenient("windows_placeholder_icons = false\n").unwrap().windows_placeholder_icons, P::Off);+ assert_eq!(Settings::parse_lenient("windows_placeholder_icons = true\n").unwrap().windows_placeholder_icons, P::All);+ assert!(toml::to_string_pretty(&Settings { windows_placeholder_icons: P::Off, ..Default::default() }).unwrap().contains("windows_placeholder_icons = false"));+ assert!(toml::to_string_pretty(&Settings { windows_placeholder_icons: P::All, ..Default::default() }).unwrap().contains("windows_placeholder_icons = true"));+ // string modes round-trip cleanly+ for (pref, expected) in [(P::Folders, "windows_placeholder_icons = \"folders\""), (P::Files, "windows_placeholder_icons = \"files\"")] {+ let text = toml::to_string_pretty(&Settings { windows_placeholder_icons: pref, ..Default::default() }).unwrap();+ assert!(text.contains(expected), "{text}");+ assert_eq!(Settings::parse_lenient(&text).unwrap().windows_placeholder_icons, pref);+ }+ assert_eq!(Settings::parse_lenient("windows_placeholder_icons = \"off\"\n").unwrap().windows_placeholder_icons, P::Off);+ assert_eq!(Settings::parse_lenient("windows_placeholder_icons = \"all\"\n").unwrap().windows_placeholder_icons, P::All);+ // unknown value falls back to Off without losing neighbouring fields+ let bad = Settings::parse_lenient("windows_placeholder_icons = \"bogus\"\nshow_hidden = true\n").unwrap();+ assert_eq!(bad.windows_placeholder_icons, P::Off);+ assert!(bad.show_hidden);+ // preview pane override defaults to following windows_placeholder_icons and leaves no key until set+ let legacy_on = Settings::parse_lenient("windows_placeholder_icons = true\n").unwrap();+ assert_eq!(legacy_on.windows_preview_icons, None);+ assert_eq!(legacy_on.effective_windows_preview_icons(), P::All);+ assert!(!toml::to_string_pretty(&legacy_on).unwrap().contains("windows_preview_icons"));+ let split = Settings { windows_placeholder_icons: P::Folders, windows_preview_icons: Some(P::Off), ..Default::default() };+ assert_eq!(split.effective_windows_preview_icons(), P::Off);+ let split_text = toml::to_string_pretty(&split).unwrap();+ assert!(split_text.contains("windows_preview_icons = false"), "{split_text}");+ let split_back = Settings::parse_lenient(&split_text).unwrap();+ assert_eq!((split_back.windows_placeholder_icons, split_back.windows_preview_icons), (P::Folders, Some(P::Off)));+ }}/// Starts or stops the name index when the setting changes. The first start waits a few secondsdiff --git a/crates/rf-app/src/settings_view.rs b/crates/rf-app/src/settings_view.rsindex ad0ea8a6..ad7e6b23 100644--- a/crates/rf-app/src/settings_view.rs+++ b/crates/rf-app/src/settings_view.rs@@ -15,7 +15,7 @@ use crate::fluent_menu::{self, Item, Menu, MenuIcon};use crate::select_box::{Choice, select_box};use crate::i18n::Lang;use crate::settings::{- self, AnimPref, BackdropPref, ClickPref, DatePref, DefaultView, DeletePref, IconThemePref, IdePref, RendererPref, Settings, StartupPref,+ self, AnimPref, BackdropPref, ClickPref, DatePref, DefaultView, DeletePref, IconThemePref, IdePref, PlaceholderIconsPref, RendererPref, Settings, StartupPref,ThemePref,};use crate::t;@@ -2946,12 +2946,43 @@ fn files(p: &Palette, s: &Settings, cx: &mut App) -> Vec<AnyElement> {));v.push(card(p, L::FileType, t!("Dosya uzantılarını göster"), None, sw("ext", p, s.show_extensions, |s, v| s.show_extensions = v)));v.push(card(p, L::Image, t!("Küçük resimleri göster"), None, sw("thumbs", p, s.show_thumbnails, |s, v| s.show_thumbnails = v)));- v.push(card(+ let placeholder_choices = || {+ vec![+ (PlaceholderIconsPref::Off, t!("Kapalı").into()),+ (PlaceholderIconsPref::Folders, t!("Yalnızca klasörler").into()),+ (PlaceholderIconsPref::Files, t!("Yalnızca dosyalar").into()),+ (PlaceholderIconsPref::All, t!("Dosyalar ve klasörler").into()),+ ]+ };+ let preview_placeholder = s.windows_preview_icons;+ v.push(expander(+ "win-icons",p,L::Image,t!("Yüklenirken Windows simgeleri"),Some(t!("Bir öğenin kendi resmi gelene kadar ve önizleme bölmesinde, rustyfiles'ın simgeleri yerine Windows'un o türün simgesi gösterilir (klasörün, dosya türünün, kişiselleştirilmiş simgenin)")),- sw("win-icons", p, s.windows_placeholder_icons, |s, v| s.windows_placeholder_icons = v),+ Some(dropdown("win-icons", p, s.windows_placeholder_icons, placeholder_choices(), |s, v| s.windows_placeholder_icons = v)),+ move || {+ vec![sub(+ &pp,+ t!("Önizleme paneli"),+ Some(t!("Önizleme panelinde küçük resmi olmayan öğeler için Windows simgeleri")),+ dropdown(+ "win-preview-icons",+ &pp,+ preview_placeholder,+ vec![+ (None, t!("Yukarıdakiyle aynı").into()),+ (Some(PlaceholderIconsPref::Off), t!("Kapalı").into()),+ (Some(PlaceholderIconsPref::Folders), t!("Yalnızca klasörler").into()),+ (Some(PlaceholderIconsPref::Files), t!("Yalnızca dosyalar").into()),+ (Some(PlaceholderIconsPref::All), t!("Dosyalar ve klasörler").into()),+ ],+ |s, v| s.windows_preview_icons = v,+ ),+ )]+ },+ cx,));v.push(card(p,