Condividi tramite


ModelingDocView Class

Definition

Important

This API is not CLS-compliant.

Base class for document windows

public ref class ModelingDocView abstract : Microsoft::VisualStudio::Modeling::Shell::ModelingWindowPane, Microsoft::VisualStudio::Shell::Interop::IVsStatusbarUser, Microsoft::VisualStudio::Shell::Interop::IVsToolboxActiveUserHook, Microsoft::VisualStudio::Shell::Interop::IVsToolboxUser
[System.CLSCompliant(false)]
public abstract class ModelingDocView : Microsoft.VisualStudio.Modeling.Shell.ModelingWindowPane, Microsoft.VisualStudio.Shell.Interop.IVsStatusbarUser, Microsoft.VisualStudio.Shell.Interop.IVsToolboxActiveUserHook, Microsoft.VisualStudio.Shell.Interop.IVsToolboxUser
public abstract class ModelingDocView : Microsoft.VisualStudio.Modeling.Shell.ModelingWindowPane, Microsoft.VisualStudio.Shell.Interop.IVsStatusbarUser, Microsoft.VisualStudio.Shell.Interop.IVsToolboxActiveUserHook, Microsoft.VisualStudio.Shell.Interop.IVsToolboxUser
[<System.CLSCompliant(false)>]
type ModelingDocView = class
    inherit ModelingWindowPane
    interface IVsStatusbarUser
    interface IVsToolboxUser
    interface IVsToolboxActiveUserHook
type ModelingDocView = class
    inherit ModelingWindowPane
    interface IVsStatusbarUser
    interface IVsToolboxUser
    interface IVsToolboxActiveUserHook
Public MustInherit Class ModelingDocView
Inherits ModelingWindowPane
Implements IVsStatusbarUser, IVsToolboxActiveUserHook, IVsToolboxUser
Inheritance
Derived
Attributes
Implements

Constructors

ModelingDocView(ModelingDocData, IServiceProvider)

Create a new view, given a DocData.

Properties

ActiveInPlaceEditWindow

May be set to provide an active in-place edit window Clipboard commands will be routed to this window.

(Inherited from ModelingWindowPane)
Content

Gets or sets the content of this tool window.

(Inherited from WindowPane)
DefaultToolboxTabName

String indicating the toolbox tab name that should be selected when this view gets focus.

DefaultToolboxTabToolboxItemsCount

Returns the toolbox items count in the default tool box tab.

DocData

Gets the document this view corresponds to.

Frame

Provides access to the IVsWindowFrame corresponding to this window. In most cases, direct access to this interface is not necessary

(Inherited from ModelingWindowPane)
HasSelectableObjects

Overridden here to return false when the docview window is closed.

HelpService

Help context managed by this window. Keywords and attributes placed in this context will have priority HelpContextType.Window.

(Inherited from ModelingWindowPane)
InitializationMode

Gets the initialization mode that is associated with this window pane.

(Inherited from WindowPane)
IsPrimaryView

True if this is the primary view of the designer. The "primary view" owns the artifact document locks that are created by the VSHost during sync'ing. If an artifact is opened in an incompatible editor (e.g. the binary editor), the primary view is closed. This should shut down all other views.

MenuService

Gets the IMenuCommandService which derived classes and hosted controls can use to add commands.

(Inherited from ModelingWindowPane)
ParentHandle (Inherited from WindowPane)
PrimarySelection

Returns the current primary selection. If one hasn't been set, returns the first object in the collection

(Inherited from ModelingWindowPane)
ProvideViewHelper

Should we attempt to install ourselves as a ViewHelper?

SelectedElements

Stores the elements currently selected in this window.

(Inherited from ModelingWindowPane)
SelectionCount

A count of the currently selected objects.

(Inherited from ModelingWindowPane)
SelectionHelpService

Help context managed by this window. Help keywords and attributes placed in this context have priority HelpContextType.Selection for document windows and HelpContextType.ToolWindowSelection for tool windows. The context is cleared on each selection change, so derived class that use this context should override OnSelectionChanged to keep it up-to-date.

(Inherited from ModelingWindowPane)
ServiceProvider

Gets the service provider local to this window frame

(Inherited from ModelingWindowPane)
TargetToolboxItemFilterAttributes

Returns a collection of filter attributes for this DocView. These attributes are used to determine items that are enabled/disabled in the toolbox.

ToolboxService

Provides access to the toolbox service

Window

Gets the window associated with this window pane.

(Inherited from WindowPane)

Methods

BaseLoadView()

To be called when the associated DocData is finished loading or reloading, primarily from DocView.LoadView(). Performs any basic initialization required after loading a new DocData into the view.

CommitPendingEditForCommand(CommandID)

Gives derived classes a chance to commit outstanding edits before a command is executed. This is called frequently, so only lightweight processing should be done here. This is preferable to IVsWindowPaneCommit.CommitPendingEdit, because it allows derived classes to make the decision to commit for some commands but not others.

(Inherited from ModelingWindowPane)
CountAllObjects()

mplementation of ISelectionContainer interface.

(Inherited from ModelingWindowPane)
CountObjects(UInt32, UInt32)

Implementation of ISelectionContainer interface.

(Inherited from ModelingWindowPane)
CountSelectedObjects()

Implementation of ISelectionContainer interface.

(Inherited from ModelingWindowPane)
Dispose()

Disposes the window pane and its resources.

(Inherited from WindowPane)
Dispose(Boolean)

Called by the shell when our tool window is closed.

DoSelectObjects(UInt32, Object[], UInt32)

Derived classes should override to support selection via ISelectionContainer.SelectObjects. For instance, The drop-down above the VS property browser uses this mechanism, as does automation.

(Inherited from ModelingWindowPane)
GetAllObjects(UInt32, Object[])

ISelectionContainer.GetObjects (All).

(Inherited from ModelingWindowPane)
GetComponentSelected(Object)

Returns true iff obj is currently selected.

(Inherited from ModelingWindowPane)
GetContainerSelected(Object)

Implementation identical to GetComponentSelected.

(Inherited from ModelingWindowPane)
GetObjects(UInt32, UInt32, Object[])

Implementation of ISelectionContainer interface.

(Inherited from ModelingWindowPane)
GetSelectedComponents()

Returns a read-only collection of currently selected components.

(Inherited from ModelingWindowPane)
GetSelectedObjects(UInt32, Object[])

ISelectionContainer.GetObjects (Selected).

(Inherited from ModelingWindowPane)
GetService(Type)

Override to return our menu command service implementation.

(Inherited from ModelingWindowPane)
GetSite(Guid, IntPtr)

Implementation of IObjectWithSite.

(Inherited from ModelingWindowPane)
Hide()

Hides this window.

(Inherited from ModelingWindowPane)
Initialize()

Overriden to publish context bag. For editors, general context should be associated with the SEID

InterceptDataObject(IDataObject)

Called by toolbox when the input data object is about to go into a drag-drop operation. This method allows the input data object to be substituted by the returned data object, which will go into the drag-drop operation instead. The base implementation returns null, which means no substitution of the input data object.

IsDataObjectSupported(IDataObject)
IsSupported(IDataObject)

Implementation of IVsToolboxUser interface. Determines if we support the referenced data object.

ItemPicked(IDataObject)

Implementation of IVsToolboxUser interface. Sends notification that an item in the toolbox is selected through a left-click, or by pressing Enter.

LoadUIState(Stream)

Override to load previously saved state of the pane

(Inherited from WindowPane)
LoadView()

Called when the associated DocData is finished loading or reloading.
Derived classes should perform any initialization that requires the DocData to be loaded here.

OnClose()

Called when window is closed. Overridden here to remove our objects from the selection context so that the property browser doesn't call back on our objects after the window is closed.

(Inherited from ModelingWindowPane)
OnCreate()
OnSelectionChanged(EventArgs)

Called when the selection changes. Derived classes that override this method should make sure to call the base class so event listeners are notified.

(Inherited from ModelingWindowPane)
OnSelectionChanging(EventArgs)

Called prior to a selection change. Derived classes that override this method should make sure to call the base class so event listeners are notified.

(Inherited from ModelingWindowPane)
OnToolboxItemSelected(IDataObject)
OnToolboxSelectionChanged()
PreProcessMessage(Message)

Allows us to handle window messages.

(Inherited from ModelingWindowPane)
SaveUIState(Stream)

Override to save custom state information to be used later when the pane is reconstructed.

(Inherited from WindowPane)
SelectObjects(UInt32, Object[], UInt32)

Implementation of ISelectionContainer interface.

(Inherited from ModelingWindowPane)
SetInfo()

Override to set status bar info.

SetSelectedComponents(ICollection, SelectionTypes)

Not used. Implemenation of ISelectionService interface.

(Inherited from ModelingWindowPane)
SetSelectedComponents(ICollection)

Pushes components into the selection container (replaces currently selected components), and notifies the shell of a selection change.

(Inherited from ModelingWindowPane)
SetSite(Object)

Implementation of IObjectWithSite.

(Inherited from ModelingWindowPane)
Show()

Shows this window.

(Inherited from ModelingWindowPane)
ShowNoActivate()

Shows this window without activating it.

(Inherited from ModelingWindowPane)

Events

SelectionChanged

This event gets fired after a selection change in this window. Clients that want notification of selection changes to this window should register an event handler.

(Inherited from ModelingWindowPane)
SelectionChanging

This event gets fired just prior to a selection change in this window. Clients that want notification of selection changes to this window should register an event handler.

(Inherited from ModelingWindowPane)
ToolboxItemSelected

Called when a toolbox item is invoked (through double-click or pressing Enter key).

ToolboxSelectionChanged

Called when toolbox selection changes (through single-click or pressing up/down arrow keys).

Explicit Interface Implementations

IOleCommandTarget.Exec(Guid, UInt32, UInt32, IntPtr, IntPtr)

Executes the specified command.

(Inherited from WindowPane)
IOleCommandTarget.QueryStatus(Guid, UInt32, OLECMD[], IntPtr)

Gets the status of the commands.

(Inherited from WindowPane)
IServiceProvider.GetService(Type)

Gets the service of the specified type.

(Inherited from WindowPane)
IVsStatusbarUser.SetInfo()

Called by the shell when it's time for us to set info on the status bar.

IVsToolboxActiveUserHook.InterceptDataObject(IDataObject, IDataObject)

Called by toolbox when the input data object is about to go into a drag-drop operation. This method allows the input data object to be substituted by the output data object, which will go into the drag-drop operation instead.

IVsToolboxActiveUserHook.ToolboxSelectionChanged(IDataObject)

Called when selection on toolbox changes (through a single-click or pressing up/down arrow keys).

IVsUIElementPane.CloseUIElementPane()

Closes the pane.

(Inherited from WindowPane)
IVsUIElementPane.CreateUIElementPane(Object)

Creates the pane.

(Inherited from WindowPane)
IVsUIElementPane.GetDefaultUIElementSize(SIZE[])

When implemented in a derived class, gets the default size of the pane.

(Inherited from WindowPane)
IVsUIElementPane.LoadUIElementState(IStream)

When implemented in a derived class, loads custom state storage.

(Inherited from WindowPane)
IVsUIElementPane.SaveUIElementState(IStream)

Stores the state of the pane to the specified stream.

(Inherited from WindowPane)
IVsUIElementPane.SetUIElementSite(IServiceProvider)

Sets the site for this window pane.

(Inherited from WindowPane)
IVsUIElementPane.TranslateUIElementAccelerator(MSG[])

Handles keyboard accelerators before the shell processes the message.

(Inherited from WindowPane)
IVsWindowPane.ClosePane()
Obsolete.

Closes the window pane. Obsolete.

(Inherited from WindowPane)
IVsWindowPane.CreatePaneWindow(IntPtr, Int32, Int32, Int32, Int32, IntPtr)
Obsolete.

Creates a window pane. Obsolete.

(Inherited from WindowPane)
IVsWindowPane.GetDefaultSize(SIZE[])
Obsolete.

Gets the default size of the window pane. Obsolete.

(Inherited from WindowPane)
IVsWindowPane.LoadViewState(IStream)
Obsolete.

Loads the saved view state. Obsolete.

(Inherited from WindowPane)
IVsWindowPane.SaveViewState(IStream)
Obsolete.

Saves the loaded view state. Obsolete.

(Inherited from WindowPane)
IVsWindowPane.SetSite(IServiceProvider)
Obsolete.

Initializes this window pane with the specified service provider. Obsolete.

(Inherited from WindowPane)
IVsWindowPane.TranslateAccelerator(MSG[])
Obsolete.

Handles the translation of navigation keys. Obsolete

(Inherited from WindowPane)

Applies to