-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SLVS-1457 Open ManageBindingDialog from SharedBindingGoldBar #5699
SLVS-1457 Open ManageBindingDialog from SharedBindingGoldBar #5699
Conversation
…ce between MEF components. - The circular reference was: VsSessionHost -> SharedBindingSuggestionService -> UnintrusiveBindingController -> ActiveSolutionBoundTracker -> VsSessionHost - Fixed it by removing the SharedBindingSuggestionService from VsSessionHost and instead let it show the goldbar, whenever the active solution state changed
…om VsSessionHost, which were used only by the ConnectionController (which should be deleted once the TeamExplorer will be deleted)
…geBindingDialog once the "Bind" button in the goldbar is clicked.
using SonarQube.Client; | ||
|
||
namespace SonarLint.VisualStudio.Integration.MefServices | ||
{ | ||
internal interface ISharedBindingSuggestionService | ||
public interface ISharedBindingSuggestionService : IDisposable |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I am not mistaken this is not necessary to be public
, it can be internal
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It has to be accessible to the SonarLintIntegrationPackage, that's why the interface is public
Quality Gate passedIssues Measures |
SLVS-1457
It should have been easy: just instantiate the ManageBindingDialog in the SharedBindingSuggestionService and pass it to the goldbar. But it was a mess, because once you start adding the reference to IConnectedModeBindingServices you have a circular reference that crashes the app at runtime (the circular reference was VsSessionHost -> SharedBindingSuggestionService -> UnintrusiveBindingController -> ActiveSolutionBoundTracker -> VsSessionHost)
So I had to restructure the logic to break the circular refernce.