Compare Page Revisions
« Older Revision - Back to Page History - Current Revision
Connect
public void OnConnection(object application, ext_ConnectMode connectMode, object addInInst, ref Array custom) { InitAddIn(application, connectMode, addInInst); } //------------------------------------------------------------------------------------------------- public void OnDisconnection(ext_DisconnectMode disconnectMode, ref Array custom) { if (disconnectMode != ext_DisconnectMode.ext_dm_UISetupComplete) { DeleteToolbar(); } } //------------------------------------------------------------------------------------------------- public void QueryStatus(string commandName, vsCommandStatusTextWanted neededText, ref vsCommandStatus status, ref object commandText) { if(neededText == vsCommandStatusTextWanted.vsCommandStatusTextWantedNone) { bool bEnabled = true; bool bHidden = false; QueryStatus(commandName, ref bEnabled, ref bHidden); status = (vsCommandStatus)( vsCommandStatus.vsCommandStatusSupported | (bEnabled? vsCommandStatus.vsCommandStatusEnabled : 0) | (bHidden? vsCommandStatus.vsCommandStatusInvisible : 0) ); return; } } //------------------------------------------------------------------------------------------------- public void Exec(string commandName, vsCommandExecOption executeOption, ref object varIn, ref object varOut, ref bool handled) { handled = false; if(executeOption == vsCommandExecOption.vsCommandExecOptionDoDefault) { Execute(commandName, ref handled); } }
ScrewTurn Wiki version 3.0.1.400. Some of the icons created by FamFamFam. Except where noted, all contents Copyright © 1999-2024, Patrick Jasinski.