Commit Graph

230 Commits

Author SHA1 Message Date
Matt Bierner
42e0c43645 Use resource map for storing formatting options
Try to normalize file cases on case-insensitive file systems
2018-07-25 17:47:06 -07:00
Matt Bierner
edc6b2acdd Always invoke quick fix command
Make sure we always invoke the applyCodeActionCommand. This is needed for telemetry to be sent properly
2018-07-25 17:29:35 -07:00
Matt Bierner
9e6a525723 Fixing fix all not applying correct commands on edit 2018-07-25 17:27:03 -07:00
Matt Bierner
690744c3c6 Only return a single all code action per quick fix fixId
Fixes #55065
2018-07-25 17:19:33 -07:00
Matt Bierner
ccf9f4badd Use VersionDependentRegistration 2018-07-25 17:19:33 -07:00
Matt Bierner
5347a06a46 Don't convert diagnostic set to array 2018-07-25 17:19:33 -07:00
Matt Bierner
8531a230e5 Use flatten in a few places to improve readability 2018-07-20 17:58:43 -07:00
Matt Bierner
f500f659e6 Create links for files section in tsconfig 2018-07-20 17:52:01 -07:00
Matt Bierner
91d55c965a Make sure we disable suggestions properly 2018-07-20 14:32:21 -07:00
Matt Bierner
9fb3229377 Use single diagnostic collection for js and ts
Refactors the ts DiagnosticManager to be shared between language providers.  To do this:

- Make sure we always maintain a complete list of diagnostics in the extension. But only update the vscode.DiagnosticCollection with the ones we care about

- Add the concept of a diagnostic language. This is needed now that we only have a single collection. Use the diagnostic language to determine which diagnostics to filter out using `typescript.validate` and `javascript.validate`

- Add a diagnosticSetting class to track settings for different languages (js and ts)

Fixes #54359
2018-07-20 14:16:28 -07:00
Matt Bierner
44cd521ced Finalize definition link (#54424)
Finalize the definition link api

- Gives fields more explicit names (target and origin)
- Moves api to vscode.d.ts
- Makes other definition providers (such as type definition provider and implementation provider) also return definition links

Fixes #54101
2018-07-18 16:32:27 -07:00
Matt Bierner
533c6deb79 Move cancellation files to own dir
Fixes #53423
2018-07-18 14:28:55 -07:00
Matt Bierner
b9bc23bb58 Only exec server call in try catch 2018-07-18 14:28:54 -07:00
Matt Bierner
3331d725e5 Use toFileLocationRequestArgs 2018-07-18 14:28:54 -07:00
Matt Bierner
708b16a96c Remove unused property 2018-07-18 14:28:54 -07:00
Matt Bierner
6c2818d42e Clean up provideDocumentSymbols
- Returned undefined instead of empty array
- Only execute server call in try catch
2018-07-18 14:28:54 -07:00
Matt Bierner
4c003dbbc1 Remove old navtree call
This API has been replaced with navbar. The code related to navbar is not being tested and a very small number of users are using < 2.1 in their workspaces
2018-07-18 14:28:54 -07:00
Matt Bierner
966bec8650 Reducing scope of try catch to just exec
We want to be alerted if an exception is thrown outside of execute
2018-07-18 14:28:54 -07:00
Matt Bierner
b6e9dc253b Fix visual match for string types
Fixes #53962
2018-07-16 16:46:08 -07:00
Matt Bierner
f5c36f4bb8 Add telemetry on organize imports
This is needed to understand if users are running this action and how we can improve discoverablity
2018-07-16 13:00:46 -07:00
Matt Bierner
cbcafcc284 Don't enable commit characters when isNewIdentifierLocation is true
Fixes #54386
2018-07-16 13:00:46 -07:00
Matt Bierner
eaa535ff3e Use properties for commitCharacters 2018-07-13 11:42:58 -07:00
Matt Bierner
b179deefe5 Only use isNewIdentifierLocation to disable commit characers instead of all suggestions
Fixes #54267
2018-07-13 09:17:14 -07:00
Matt Bierner
b64ff63750 Remove extra await 2018-07-13 09:17:14 -07:00
Matt Bierner
ba9c869b6a Organize all imports in ts extension 2018-07-12 16:32:18 -07:00
Matt Bierner
0986ab3633 Move resource map to utils 2018-07-12 16:30:34 -07:00
Matt Bierner
dc08cbdfa9 Also support regular json files for tsconfig document links 2018-07-12 16:25:14 -07:00
Matt Bierner
cb9ad4f8be Add link provider for jsconfig and tsconfig files
Fixes #16905
Fixes #54215
2018-07-12 16:11:30 -07:00
Matt Bierner
4dc63b5061 Fix duplicate config requests sometimes being sent to TS
Fixes #54088
2018-07-12 16:11:30 -07:00
Matt Bierner
659d646e55 Use destructuring 2018-07-12 16:11:30 -07:00
Matt Bierner
23d9f2cea6 Don't create empty arrays to signal no return types 2018-07-12 16:11:30 -07:00
Matt Bierner
a7fb144e95 Use Typescript's CompletionInfo.isNewIdentifierLocation
Fixes #52499
2018-07-11 14:30:21 -07:00
Matt Bierner
e1d50f119d Move execute into geterror class 2018-07-11 14:19:34 -07:00
Matt Bierner
f3af5502e7 Convert GetErrRequest to class 2018-07-11 14:19:34 -07:00
Matt Bierner
46db7d9d3b tagCompletion -> tagClosing 2018-07-11 14:19:34 -07:00
Matt Bierner
bd3beec042 Extract getInsertionPositions 2018-07-11 14:19:34 -07:00
Matt Bierner
6c99578088 Hook up CancellationToken 2018-07-11 14:19:34 -07:00
Matt Bierner
97734e3a39 Reduce nested statements 2018-07-11 14:19:34 -07:00
Matt Bierner
2e8e41c06d Prefix private members with _ 2018-07-11 14:19:34 -07:00
Matt Bierner
1dcb248d30 Clear auto closing tag timeout
This should already be effectively canceled but no reason to fire it
2018-07-11 14:19:33 -07:00
Matt Bierner
860138b2b2 Remove normalizePath from BufferSyncSupport 2018-07-10 17:13:55 -07:00
Matt Bierner
f5e7c01028 Use resource map for pending diagnostics 2018-07-10 17:13:55 -07:00
Matt Bierner
84100f37c6 Request diagnostics on synced buffer 2018-07-10 17:13:55 -07:00
Matt Bierner
2adafad5ae Extract duplicated triggerDiagnostics code to function 2018-07-10 17:13:55 -07:00
Matt Bierner
5a6e122a58 Extract PendingDiagnostics to own class 2018-07-10 17:13:55 -07:00
Matt Bierner
bc627a5a83 Remove duplicate code for creating FormattingRequestArgs 2018-07-10 17:13:55 -07:00
Matt Bierner
585c650411 Remove cyle around requestDiagnostic 2018-07-10 17:13:54 -07:00
Matt Bierner
d68d22f961 Pass in method directly instead of lambda for some events 2018-07-10 15:03:52 -07:00
Matt Bierner
0178fc2824 Make sure we clean up config change registration 2018-07-10 15:03:52 -07:00
Matt Bierner
cbbb21c765 Don't try closing for cases like <div>> when user has just typed last > 2018-07-10 15:03:51 -07:00