Tabs Studio Blog (organizing Visual Studio document tabs)

August 27, 2009

Navigator add-in

Filed under: Uncategorized — Tags: — Sergey Vlasov @ 4:18 am

Navigator allows you to switch tabs using keyboard. It provides two new Visual Studio commands to activate tabs on the left and on the right of the currently selected one.

Navigator is a good example of Visual Studio commands creation in Tabs Studio’s add-in. Main Navigator class implements the EnvDTE.IDTCommandTarget interface. Commands class registers two new commands, reports their status as always enabled and checks when it is time to execute them.

Actual navigation is implemented in CommandsImpl class. Uisng the ITabsStudioEngine.GetTabs method it gets information about all tabs, determines selected tab group, determines selected tab, finds adjacent tab in TabPanel, finds active extension in adjacent tab and activates corresponding Visual Studio window using Activate method.

Assigning keyboard shortcuts to these commands in Visual Studio keyboard options I noticed that assigning, for example, Ctrl+2 in Global scope to TabsStudio.Connect.NavigateToNextTab works, but to assign Ctrl+Shift+Right Arrow it is needed to be in Text Editor scope or default Text Editor command overrides it.

Download Navigator v1.0.0 for Tabs Studio v1.5.5.

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

Gravatar
WordPress.com Logo

Please log in to WordPress.com to post a comment to your blog.

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Theme: Shocking Blue Green. Blog at WordPress.com.