-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #247 from renpy/fix-149
Improve diagnostic configuration
- Loading branch information
Showing
7 changed files
with
135 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { TabInputText, Uri, window } from "vscode"; | ||
|
||
/** | ||
* Gets the URIs of the tabs opened in the editor whose input is of type TabInputText. | ||
* @returns An array of URIs | ||
*/ | ||
export function getAllOpenTabInputTextUri(): Uri[] { | ||
const uris: Uri[] = []; | ||
const tabGroups = window.tabGroups.all; | ||
const tabs = tabGroups.flatMap((group) => group.tabs.map((tab) => tab)); | ||
tabs.forEach((tab) => { | ||
if (tab.input instanceof TabInputText) { | ||
uris.push(tab.input.uri); | ||
} | ||
}); | ||
return uris; | ||
} |