C# Class GoogleCloudExtension.Utils.SelectionUtils

This class provides helpers to update the properties window, manage the currently selected "item".
Datei anzeigen Open project: GoogleCloudPlatform/google-cloud-visualstudio Class Usage Examples

Private Properties

Property Type Description
CreateTrackSelection ITrackSelection
GetPropertiesWindow IVsWindowFrame
TicklePropertiesWindow void

Public Methods

Method Description
ActivatePropertiesWindow ( ) : void
ClearSelection ( ) : void

Clears the selection, making the property window empty.

SelectItem ( object item ) : void

Selects the given item, showing it in the properties window.

SelectionUtils ( Microsoft.VisualStudio.Shell.ToolWindowPane owner ) : Microsoft.VisualStudio.Shell

Private Methods

Method Description
CreateTrackSelection ( IServiceProvider serviceProvider ) : ITrackSelection
GetPropertiesWindow ( IServiceProvider serviceProvider, bool forceCreate = false ) : IVsWindowFrame

Returns the properties window if it already exists.

TicklePropertiesWindow ( ) : void

This method implements a workaround for a bug in VS 2015 in which the properties window will not update the very first time is opened until it gains and loses focus. This method forces the focus to change to the properties window and then back to the owner frame to force this behavior.

Method Details

ActivatePropertiesWindow() public method

public ActivatePropertiesWindow ( ) : void
return void

ClearSelection() public method

Clears the selection, making the property window empty.
public ClearSelection ( ) : void
return void

SelectItem() public method

Selects the given item, showing it in the properties window.
public SelectItem ( object item ) : void
item object The item to be selected.
return void

SelectionUtils() public method

public SelectionUtils ( Microsoft.VisualStudio.Shell.ToolWindowPane owner ) : Microsoft.VisualStudio.Shell
owner Microsoft.VisualStudio.Shell.ToolWindowPane
return Microsoft.VisualStudio.Shell