IVsUIShell.SetupToolbar Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Called by VSPackage that creates a tool window in order to attach a toolbar to the tool window.
public:
int SetupToolbar(IntPtr hwnd, Microsoft::VisualStudio::Shell::Interop::IVsToolWindowToolbar ^ ptwt, [Runtime::InteropServices::Out] Microsoft::VisualStudio::Shell::Interop::IVsToolWindowToolbarHost ^ % pptwth);
public int SetupToolbar (IntPtr hwnd, Microsoft.VisualStudio.Shell.Interop.IVsToolWindowToolbar ptwt, out Microsoft.VisualStudio.Shell.Interop.IVsToolWindowToolbarHost pptwth);
abstract member SetupToolbar : nativeint * Microsoft.VisualStudio.Shell.Interop.IVsToolWindowToolbar * IVsToolWindowToolbarHost -> int
Public Function SetupToolbar (hwnd As IntPtr, ptwt As IVsToolWindowToolbar, ByRef pptwth As IVsToolWindowToolbarHost) As Integer
Parameters
- hwnd
-
IntPtr
nativeint
[in] Handle to the window in which the toolbar is to be set up.
- ptwt
- IVsToolWindowToolbar
[in] Pointer to the IVsToolWindowToolbar interface for the new toolbar.
- pptwth
- IVsToolWindowToolbarHost
[out] Pointer to the IVsToolWindowToolbarHost interface.
Returns
If the method succeeds, it returns S_OK. If it fails, it returns an error code.
Remarks
COM Signature
From vsshell.idl:
HRESULT IVsUIShell::SetupToolbar(
[in] HWND hwnd,
[in] IVsToolWindowToolbar *ptwt,
[out] IVsToolWindowToolbarHost **pptwth
);