Common
This commit is contained in:
parent
f9b8c1eb43
commit
4228f55bdc
|
@ -500,7 +500,7 @@ where
|
||||||
if dry_run {
|
if dry_run {
|
||||||
infos.push(format!("dry_run - would delete file: {:?}", i.get_path()));
|
infos.push(format!("dry_run - would delete file: {:?}", i.get_path()));
|
||||||
} else {
|
} else {
|
||||||
if let Err(e) = std::fs::remove_file(i.get_path()) {
|
if let Err(e) = fs::remove_file(i.get_path()) {
|
||||||
errors.push(format!("Cannot delete file: {:?} - {e}", i.get_path()));
|
errors.push(format!("Cannot delete file: {:?} - {e}", i.get_path()));
|
||||||
failed_to_remove_files += 1;
|
failed_to_remove_files += 1;
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -305,8 +305,7 @@ impl Directories {
|
||||||
self.reference_directories.iter().any(|e| path.starts_with(e))
|
self.reference_directories.iter().any(|e| path.starts_with(e))
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn is_excluded(&self, path: impl AsRef<Path>) -> bool {
|
pub fn is_excluded(&self, path: &Path) -> bool {
|
||||||
let path = path.as_ref();
|
|
||||||
#[cfg(target_family = "windows")]
|
#[cfg(target_family = "windows")]
|
||||||
let path = normalize_windows_path(path);
|
let path = normalize_windows_path(path);
|
||||||
// We're assuming that `excluded_directories` are already normalized
|
// We're assuming that `excluded_directories` are already normalized
|
||||||
|
|
|
@ -108,7 +108,7 @@ export component LeftSidePanel {
|
||||||
HorizontalLayout {
|
HorizontalLayout {
|
||||||
alignment: start;
|
alignment: start;
|
||||||
Button {
|
Button {
|
||||||
enabled: GuiState.active_tab != CurrentTab.Settings && GuiState.available_subsettings;
|
visible: GuiState.active_tab != CurrentTab.Settings && GuiState.available_subsettings;
|
||||||
min-width: 20px;
|
min-width: 20px;
|
||||||
min-height: 20px;
|
min-height: 20px;
|
||||||
max-height: self.width;
|
max-height: self.width;
|
||||||
|
@ -122,7 +122,7 @@ export component LeftSidePanel {
|
||||||
HorizontalLayout {
|
HorizontalLayout {
|
||||||
alignment: end;
|
alignment: end;
|
||||||
Button {
|
Button {
|
||||||
enabled: GuiState.active_tab != CurrentTab.Settings;
|
visible: GuiState.active_tab != CurrentTab.Settings;
|
||||||
min-width: 20px;
|
min-width: 20px;
|
||||||
min-height: 20px;
|
min-height: 20px;
|
||||||
max-height: self.width;
|
max-height: self.width;
|
||||||
|
|
Loading…
Reference in a new issue