Commit Graph

3147 Commits

Author SHA1 Message Date
Johannes
0656d21d11 auto-fixed prefer-const violation 2022-06-08 17:49:21 +02:00
Logan Ramos
cfecdd5461 Adopt error no telemetry for filesystem providers. (#148832)
Adopt erorr no telemetry
2022-06-07 19:53:21 +00:00
Megan Rogge
7c22caad55 Use I prefix for task interfaces (#151350) 2022-06-07 09:27:44 -07:00
Matt Bierner
75a6ddc862 Add DataTransferItem.kind (#151384)
Fixes #150963

The new `.kind` property makes it easier to tell the type of a data transfer item
2022-06-07 08:06:00 -07:00
Rich Chiodo
2b71d11040 Fix for 151376 2022-06-06 16:06:21 -07:00
Tomer Chachamu
c6350b3800 Ensure access token comes from correct provider (#150473) 2022-05-27 22:52:12 +00:00
Matt Bierner
fd19b8567e Mark notebookContentProvider proposal as deprecated (#150493)
For https://github.com/microsoft/vscode/issues/147248

Marks the top level types in this file as deprecated. Also hooks up `registerNotebookContentProvider` to report deprecated API usage
2022-05-26 22:40:06 +00:00
Matt Bierner
528ee1ae3d Allow multiple entries with the same mimetype in dataTransfer (#150425)
Currently our data transfer implementation only allows a single entry of each mimeType. There can only be a single `image/gif` file for example.

However this doesn't match how the DOM apis work. If you drop multiple gifs into VS Code for example, the DataTransfer you get contains entries for each of the gifs.

This change allows us to also support DataTransfers that have multiple entries with the same mime type. Just like with the DOM, we support constructing these duplicate mime data transfers internally, but do not allow extensions to create them

As part of this change, I've also made a few clean ups:

- Add helpers for creating dataTransfer items
- Clarify when adding a data transfer item should `append` or `replace`
- Adopt some helper functions in a few more places
2022-05-25 18:29:28 -07:00
Matt Bierner
e4f7f6a9da Add PasteEditProvider (#107283)
For #30066

This adds a new `documentPaste` api proposal that lets extensions hook into copy and paste.

This can be used to do things such as:

- Create link when pasting an image
- Bring along imports when copy and pasting code
2022-05-25 12:27:58 +02:00
Matt Bierner
d891b49fc0 Enable file DataTransfer on tree views (#150328)
For #147481
2022-05-24 21:38:12 -07:00
Logan Ramos
d937389358 Add owners to all telemetry events (#150296) 2022-05-24 14:58:08 -04:00
Ladislau Szomoru
54cf6a154f SCMInput enablement proposed api (#150270) 2022-05-24 15:01:41 +00:00
Johannes Rieken
15d3e26a36 Merge pull request #150263 from microsoft/hediet/inline-completion-finalization 2022-05-24 16:59:56 +02:00
Johannes
0844d7c996 move USER_TASKS_GROUP_KEY into tasks.ts, out of taskService.ts, and prevent cyclic dependency
fixes https://github.com/microsoft/vscode/issues/150178
2022-05-24 16:13:37 +02:00
Alexandru Dima
339c3a9b60 Fixes #150176: Extract code related to encoded token attributes to a separate file (#150275) 2022-05-24 13:51:23 +00:00
Henning Dieterichs
9ef07308ea Finalizes inline completions 2022-05-24 12:52:19 +02:00
Peng Lyu
27ea5e48ae Merge pull request #150146 from microsoft/rebornix/source-commands
Notebook kernel source menu contribution
2022-05-23 18:11:33 -07:00
Matt Bierner
91923bab48 Cleanup data transfer types (#149774)
This change attempts to clean up our internal data transfer types

- Replace `IDataTransfer` (which was just an alias for map) with a `VSDataTransfer` helper class.

    This lets us add helpers and also restrict what you can do on a datatransfer

- Move `DataTransferDTO` types into `protocol`

- Move `DataTransferTypeConverter` into `typeConvert`

- Don't return internal types to ext host callers

     For example, previously we leaked `IDataTransfer` out into providers / controllers. Instead we should always return an instance of `vscode.DataTransfer` to extensions
2022-05-23 23:28:02 +00:00
Matt Bierner
45304da73d Finalize NotebookEditor api proposal (#149767)
* Finalize NotebookEditor api proposal

Fixes #149271

This finalizes most parts of the NotebookEditor api proposal. I haven't removed the proposal entirely as there are still a few parts being left behind:

- The deprecated properties/functions
- A few contribution points such as `notebook/cell/executePrimary`

* remove extra quote
2022-05-23 23:27:17 +00:00
rebornix
50d802e75f 💄 2022-05-20 16:40:19 -07:00
rebornix
8d503ffaf4 connection state in another pr 2022-05-20 16:35:46 -07:00
rebornix
9d49470ac6 Merge remote-tracking branch 'origin/main' into rebornix/controller-connection 2022-05-20 15:49:23 -07:00
Joao Moreno
ffb7b00100 Merge commit 'ae2202631366eea0aaed6f881f87c2b44ae1b647' into sandy081/policy 2022-05-18 20:12:22 +02:00
Matt Bierner
18cf3d01ed Polish notebook workspace edit (#149734)
- Add `insertCells` helper
- Add a `newNotebookMetadata` property for setting the metadata for the entire notebook
- Add a `NotebookEdit.updateNotebookMetadata` helper
- Remove the previous `WorkspaceEdit.updateNotebookMetadata` function since you can now use `NotebookEdit.updateNotebookMetadata`
2022-05-17 12:13:44 -07:00
Matt Bierner
116c10e0ee Add drop into editor option (#147049)
* Add drop into editor option

This change adds a new `enableDropIntoEditor` editor option that enables/disables dropping an extermal resources into an editor

Previously this option was exposed `IEditorConstructionOptions`, however this did not correctly disable drop into editor when dragging and dropping unknown types (such as dragging emoji from the MacOS emoji panel)

With this change, disabling `workbench.editor.dropIntoEditor.enabled` should fully disable the new drop into behavior

* Move drop into editor from workbench to editor

This moves the `dropIntoEditorContribution` from the workbench layer to the platform layer

As part of this change, I also add to move `extractEditorsDropData` up to `platform` so that it could be used from the `editor` layer

This change also enables drop into for the SCM message box

* Fixing monaco errors

* Revert id change
2022-05-17 11:35:04 -07:00
Matt Bierner
1c7ab35761 Rename to DocumentOnDropEditProvider (#149730)
This change renames `DocumentOnDropProvider` to `DocumentOnDropEditProvider`. This new name aligns with the existing `DocumentFormattingEditProvider`
2022-05-17 09:26:54 -07:00
Matt Bierner
3f531a7de3 Add notebookWorkspaceEdit api proposal (#149128)
* Add notebookWorkspaceEdit api proposal

Splits a new `notebookWorkspaceEdit` out of the existing `notebookEditorEdit` proposal.

The notebookWorkspaceEdit reflects the api that we believe should be finalized instead of `notebookEditorEdit`. It lets extensions use workspaceedits to change cells in a notebook or replace the metadata for a notebook document

As part of this change, I've also marked all of the `notebookEditorEdit` apis as deprecated (except for `replaceNotebookMetadata` which exists in the new proposal too)

* Export type from extHost
2022-05-16 11:25:14 -07:00
rebornix
64030273a6 remove main thread proxy kenrel 2022-05-16 11:24:05 -07:00
Matt Bierner
cfbf3d5dd7 Refine notebookEditor proposal (#149656)
For #149271

- `NotebookEditor.document` -> `NotebookEditor.notebook`

- Add `selection` to for setting primary selections. Matches `TextDocument.selection`

- Deprecate `showNotebookDocument`
2022-05-16 11:17:36 -07:00
rebornix
bd99c998a1 Remove proxy controller. 2022-05-15 18:56:22 -07:00
Johannes
aa706918c1 only match against notebook uri when document selector specificies notebook type, fixes https://github.com/microsoft/vscode/issues/149363 2022-05-13 09:29:57 +02:00
Sandeep Somavarapu
5eb8bee367 Merge branch 'main' into sandy081/policy 2022-05-13 08:39:05 +02:00
Matt Bierner
67014adc30 Remove the textDocumentNotebook API proposal (#149277)
* Remove the textDocumentNotebook API proposal

All consumers have now been migrated off of this proposal, so it is safe to remove from our code

* Remove deprecated api usage from test
2022-05-12 08:59:11 +02:00
rebornix
7e34708dcc prepare for removing proxy kernel. 2022-05-11 11:46:20 -07:00
Sandeep Somavarapu
ce60d548e2 - add tests
- fix scenarios causing tests failures
- check for duplicate policy names
2022-05-11 16:16:11 +02:00
Sandeep Somavarapu
e4c04ea2e9 - Introduce policy model with file policy
- Introduce policy configuration using policy model
- Use policy configuration while reading, inspecting and writing configuration
- Adopt json settings editor
2022-05-10 13:49:31 +02:00
Tyler James Leonhardt
2d9244c330 Finalize InputBoxMessageSeverity API (#148961) 2022-05-06 14:37:40 -07:00
Alex Ross
02b59c6e3a Comments widget doesn't reveal nicely (#148897)
Fixes #148774
2022-05-06 15:18:01 +02:00
Henning Dieterichs
f98ae66391 Merge pull request #148767 from microsoft/hediet/inline-completion-update
Updates inlineCompletions proposal from inlineCompletionsNew proposal.
2022-05-05 13:51:21 +02:00
Henning Dieterichs
bae40168ae Fixes issues from code review 2022-05-05 09:54:41 +02:00
Henning Dieterichs
3b08d52d0b Updates inlineCompletions proposal from inlineCompletionsNew proposal.
Also moves InlineCompletionList.commands to inlineCompletionsAdditions proposal.
2022-05-05 07:49:38 +02:00
Matt Bierner
93fd393a0e Add API proposal for reading files in data transfer (#148596)
* Add experimental support for reading files in data transfer

Adds a new `DataTransfer.asFile` method which lets you get file objects from a `DataTransfer`. This is currently only hooked up for drop into editors.

A few follow ups:

- Right now the file data is also read eagerly when it is transfered to the extension host. Before shipping this we would make this happen lazily instead
- The drop into editor api does not provide a nice way to do anything with the dropped files.

    We should at least support returning a `WorkspaceEdit`. However `WorkspaceEdit` only supports text files, so we would also need to add an API that lets it deal with binary files

* Make `asFile` return a value instead of a promise

`asFile().data()` already returns a promise so `asFile` doesn't also need to be async

* Trying resolving data files transfer lazily

* Cleaning up code for lazy drop

* Remove testing code

* Remove unneeded buffer serialize

* 💄
2022-05-04 12:59:27 -07:00
Jason Williams
e19f09713b Enable globs on tasks otherwise fallback to default - fixes #88106 (#141230)
* use glob on tasks otherwise fallback to default

* add support for test commands also

* try to find one globbed task otherwise fallback to defaults

* - get relativePath (but fallback to absolute if outside of workspace)
- bring back json schema

* Refactor and reduce duplicate code

* remove glob, make isDefault a string or boolean

* update taskConfig

* - rebase
- type updates
- splitPerGroupType should check explicitly for true on isDefault
- hygiene check

* Remove task glob from API

* Task group DTO updates

* Make sure globs run ahead of default task if there's multiple globs matching

* Style and name changes

* More naming and code re-use

* Glob doesn't work when only 1 glob match

Co-authored-by: Alex Ross <alros@microsoft.com>
2022-05-03 09:56:24 +02:00
沈鸿飞
19e728a2c0 In addition to WebviewPanel, let WebviewView also support transferring of TypedArrays (#148429) 2022-04-30 17:53:37 -04:00
Alex Dima
0ca6fff829 Fixes #148043 2022-04-25 19:42:39 +02:00
Johannes
e7bc9bb5fc don't return duplicates from vscode.extensions.allAcrossExtensionHosts, add ExtensionIdentifierSet fyi @alexdima 2022-04-22 12:43:25 +02:00
Logan Ramos
aa69f3d762 Fix #15178 Finalize tabs API 🎉 2022-04-21 11:08:12 -04:00
Johannes
ad4470522e propose extensions.allAcrossExtensionHosts and related APIs, https://github.com/microsoft/vscode/issues/145307 2022-04-21 14:45:46 +02:00
Alexandru Dima
7ea39549f5 Merge pull request #147761 from microsoft/alex/extensions-on-all-hosts
Send all extension descriptions to all extension hosts
2022-04-20 17:03:11 +03:00
Alex Dima
0b2c629d21 Remove left-over console log calls 2022-04-20 17:01:58 +03:00