Cut over the window to Explorer.Host.exe so only the host writes the index.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-08-24 17:39:13 +02:00
parent 7c23bc2474
commit 48d03f794f
26 changed files with 774 additions and 59 deletions

View File

@@ -6,6 +6,8 @@ public interface IWorkbenchHost
{
IIndexingHost Indexing { get; }
ITransferHost Transfers { get; }
ISourceHost Sources { get; }
IIndexMutations Mutations { get; }
}
public interface IIndexingHost
@@ -33,4 +35,42 @@ public interface ITransferHost
void ClearFinished();
bool MoveUp(long jobId);
bool MoveDown(long jobId);
Task EnqueueCopyAsync(IReadOnlyList<string> sources, string destinationDirectory, CancellationToken cancellationToken = default)
=> Task.CompletedTask;
Task EnqueueMoveAsync(IReadOnlyList<string> sources, string destinationDirectory, CancellationToken cancellationToken = default)
=> Task.CompletedTask;
Task EnqueueDeleteAsync(IReadOnlyList<string> paths, bool permanent = false, CancellationToken cancellationToken = default)
=> Task.CompletedTask;
Task EnqueueRenameAsync(string path, string newName, CancellationToken cancellationToken = default)
=> Task.CompletedTask;
Task EnqueueEmptyRecycleBinAsync(CancellationToken cancellationToken = default)
=> Task.CompletedTask;
Task EnqueueExtractAsync(string archivePath, string destinationDirectory, CancellationToken cancellationToken = default)
=> Task.CompletedTask;
Task EnqueueCompressAsync(IReadOnlyList<string> sources, string archivePath, CancellationToken cancellationToken = default)
=> Task.CompletedTask;
Task EnqueueAddToArchiveAsync(string archivePath, IReadOnlyList<string> sources, CancellationToken cancellationToken = default)
=> Task.CompletedTask;
Task EnqueueVerifyArchiveAsync(string archivePath, CancellationToken cancellationToken = default)
=> Task.CompletedTask;
}
public interface ISourceHost
{
Task RefreshAsync(CancellationToken cancellationToken = default);
Task<Source> AddUncAsync(string path, CancellationToken cancellationToken = default);
Task<Source?> EnsureForPathAsync(string path, CancellationToken cancellationToken = default);
Task<bool> ForgetAsync(string path, CancellationToken cancellationToken = default);
}
public interface IIndexMutations
{
Task<long> UpsertSyncProfileAsync(SyncProfile profile, CancellationToken cancellationToken = default);
Task DeleteSyncProfileAsync(long id, CancellationToken cancellationToken = default);
Task<long> UpsertOperationProfileAsync(OperationProfile profile, CancellationToken cancellationToken = default);
Task DeleteOperationProfileAsync(long id, CancellationToken cancellationToken = default);
Task<long> CreateRenameBatchAsync(IReadOnlyList<RenameBatchItem> items, CancellationToken cancellationToken = default);
Task MarkRenameBatchUndoneAsync(long id, CancellationToken cancellationToken = default);
Task EnqueueHashCollisionsAsync(long? sourceId, CancellationToken cancellationToken = default);
Task UpsertRelationAsync(FileRelation relation, CancellationToken cancellationToken = default);
}