windows: Remove unnecessay helper function (#30764)
Release Notes: - N/A
This commit is contained in:
parent
58ba833792
commit
4b7b5db58c
1 changed files with 1 additions and 9 deletions
|
@ -137,10 +137,7 @@ fn add_recent_folders(
|
||||||
let tasks: IObjectCollection =
|
let tasks: IObjectCollection =
|
||||||
CoCreateInstance(&EnumerableObjectCollection, None, CLSCTX_INPROC_SERVER)?;
|
CoCreateInstance(&EnumerableObjectCollection, None, CLSCTX_INPROC_SERVER)?;
|
||||||
|
|
||||||
for folder_path in entries
|
for folder_path in entries.iter().filter(|path| !removed.contains(path)) {
|
||||||
.iter()
|
|
||||||
.filter(|path| !is_item_in_array(path, removed))
|
|
||||||
{
|
|
||||||
let argument = HSTRING::from(
|
let argument = HSTRING::from(
|
||||||
folder_path
|
folder_path
|
||||||
.iter()
|
.iter()
|
||||||
|
@ -181,11 +178,6 @@ fn add_recent_folders(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline]
|
|
||||||
fn is_item_in_array(item: &SmallVec<[PathBuf; 2]>, removed: &Vec<SmallVec<[PathBuf; 2]>>) -> bool {
|
|
||||||
removed.iter().any(|removed_item| removed_item == item)
|
|
||||||
}
|
|
||||||
|
|
||||||
fn create_shell_link(
|
fn create_shell_link(
|
||||||
argument: HSTRING,
|
argument: HSTRING,
|
||||||
description: HSTRING,
|
description: HSTRING,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue