IVsAsyncShellOpenDocument.OpenCopyOfStandardEditorAsync Method

Definition

Used to implement Window.NewWindow functionality.

public Microsoft.VisualStudio.Shell.Interop.IVsTask OpenCopyOfStandardEditorAsync (Microsoft.VisualStudio.Shell.Interop.IVsWindowFrame originalWindowFrame, Guid logicalView);
abstract member OpenCopyOfStandardEditorAsync : Microsoft.VisualStudio.Shell.Interop.IVsWindowFrame * Guid -> Microsoft.VisualStudio.Shell.Interop.IVsTask
Public Function OpenCopyOfStandardEditorAsync (originalWindowFrame As IVsWindowFrame, logicalView As Guid) As IVsTask

Parameters

originalWindowFrame
IVsWindowFrame

Pointer to the original window frame to clone.

logicalView
Guid

A Guid identifying the logical view. The default view is VSConstants.LOGVIEWID_Primary and every editor must support that view.

If the editor implements IVsMultiViewDocumentView on the document view object, then the value passed to ActivateLogicalView(Guid), which determines which view is activated when the editor window is shown.

By specifying the logical view Guid, you can request the specific view that matches the reason you are requesting the view. For example, specify VSConstants.LOGVIEWID_Debugging to get the view appropriate for debugging, or VSConstants.LOGVIEWID_TextView to get the view appropriate for the text editor (that is, a view that implements IVsCodeWindow).

Returns

A task representing the open operation. The result of the task is an IVsAsyncOpenDocumentResult object. The value of WindowFrame is a reference to a new, cloned IVsWindowFrame based on originalWindowFrame.

Remarks

The task returned by this method does not indicate that the document's view and docdata have been loaded. See DocumentLoadTask for more details.

Editors should handle cmdidNewWindow command by calling this method.

This method must be accessed on the main thread.

Applies to