Condividi tramite


ITextUndoHistoryRegistry.AttachHistory(Object, ITextUndoHistory) Method

Definition

Attaches an existing ITextUndoHistory to a new context. The context must not already be mapped in this registry.

public:
 void AttachHistory(System::Object ^ context, Microsoft::VisualStudio::Text::Operations::ITextUndoHistory ^ history);
public:
 void AttachHistory(Platform::Object ^ context, Microsoft::VisualStudio::Text::Operations::ITextUndoHistory ^ history);
void AttachHistory(winrt::Windows::Foundation::IInspectable const & context, Microsoft::VisualStudio::Text::Operations::ITextUndoHistory const & history);
public void AttachHistory (object context, Microsoft.VisualStudio.Text.Operations.ITextUndoHistory history);
abstract member AttachHistory : obj * Microsoft.VisualStudio.Text.Operations.ITextUndoHistory -> unit
Public Sub AttachHistory (context As Object, history As ITextUndoHistory)

Parameters

context
Object

An arbitrary context object.

history
ITextUndoHistory

An ITextUndoHistory object to associate with the context.

Remarks

Only a weak reference is held to the context.

Applies to