src/vs/workbench/services/dialogs/browser/abstractFileDialogService.ts/AbstractFileDialogService/defaultFilePath
class AbstractFileDialogService:	async defaultFilePath(schemeFilter = this.getSchemeFilterForWindow()): Promise<URI> {

		// Check for last active file first...
		let candidate = this.historyService.getLastActiveFile(schemeFilter);

		// ...then for last active file root
		if (!candidate) {
			candidate = this.historyService.getLastActiveWorkspaceRoot(schemeFilter);
		} else {
			candidate = candidate && resources.dirname(candidate);
		}

		if (!candidate) {
			candidate = await this.pathService.userHome({ preferLocal: schemeFilter === Schemas.file });
		}

		return candidate;
	}