-
Notifications
You must be signed in to change notification settings - Fork 31
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 #103 from spouliot/reload
Add 'Reload Assembly' command
- Loading branch information
Showing
4 changed files
with
61 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
/*--------------------------------------------------------------------------------------------- | ||
* Copyright (c) Microsoft Corporation. All rights reserved. | ||
* Licensed under the MIT License. See License.txt in the project root for license information. | ||
*--------------------------------------------------------------------------------------------*/ | ||
|
||
import * as vscode from "vscode"; | ||
import { DecompiledTreeProvider } from "../decompiler/DecompiledTreeProvider"; | ||
import { MemberNode } from "../decompiler/MemberNode"; | ||
|
||
export function registerReloadAssembly( | ||
decompiledTreeProvider: DecompiledTreeProvider | ||
) { | ||
return vscode.commands.registerCommand( | ||
"ilspy.reloadAssembly", | ||
async (node: MemberNode) => { | ||
if (!node) { | ||
vscode.window.showInformationMessage( | ||
'Please use context menu: right-click on the assembly node then select "Reload Assembly"' | ||
); | ||
return; | ||
} | ||
await decompiledTreeProvider.reloadAssembly(node.assembly); | ||
} | ||
); | ||
} |
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