I'm developing a Visual Studio Extension, made up of:
- A menu and series of commands
- A tools window
- One or more textview adornments
- A custom implementation of AysncPackage
Now, while the Tools Window and the commands are either wired up by, or have a handle on, the AsyncPackage for my extension, what I cannot figure out is HOW I get a handle to the self-same AsyncPackage from one or more of my text adornments.
For example, my Tools Window extends ToolWindowPane, which has a hook to the Package via the Package's ProvideToolWindow attribute. My commands are constructed inside the Package itself, so passing a handle to the AsyncPackage is simple enough.
What I cannot work out is HOW you get a reference to this AsyncPackage inside any of my TextAdornments.
Any help?