Skip to content

Commit 4fb2dff

Browse files
committed
Wrapped up
1 parent fea0937 commit 4fb2dff

File tree

2 files changed

+12
-6
lines changed

2 files changed

+12
-6
lines changed

src/Files.App.Storage/Storables/WindowsStorage/JumpListManager.cs

+11-6
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,11 @@ private static string? AppId
2929
}
3030
}
3131

32-
public ConcurrentBag<JumpListItem> JumpListItems { get; private set; }
32+
public ConcurrentBag<JumpListItem> JumpListItems { get; private set; } = [];
33+
34+
public ConcurrentBag<JumpListItem> RemovedItems { get; private set; } = [];
35+
36+
public ConcurrentBag<JumpListItem> RejectedItems { get; private set; } = [];
3337

3438
// A special "Frequent" category managed by Windows
3539
public bool ShowFrequentCategory { get; set; }
@@ -51,7 +55,8 @@ public JumpListManager()
5155
&IID_ICustomDestinationList,
5256
(void**)pCustomDestinationList.GetAddressOf());
5357

54-
JumpListItems = [];
58+
// Should not happen but as a sanity check at an early stage
59+
hr.ThrowOnFailure();
5560
}
5661

5762
public HRESULT Save()
@@ -66,11 +71,11 @@ public HRESULT Save()
6671

6772
hr = pCustomDestinationList.Get()->BeginList(&cMinSlots, &IID_IObjectArray, (void**)pDeletedItemsObjectArray.GetAddressOf());
6873

69-
// Validate items
70-
foreach (var item in JumpListItems)
71-
{
74+
// TODO: Validate items
7275

73-
}
76+
// TODO: Group them as categories
77+
78+
// TODO: Append a custom category or to the Tasks
7479

7580
if (ShowFrequentCategory)
7681
pCustomDestinationList.Get()->AppendKnownCategory(KNOWNDESTCATEGORY.KDC_FREQUENT);

src/Files.App/GlobalUsings.cs

+1
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@
7575

7676
// Files.App.Storage
7777

78+
global using global::Files.App.Storage;
7879
global using global::Files.App.Storage.Storables;
7980
global using global::Files.App.Storage.Watchers;
8081

0 commit comments

Comments
 (0)