void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.MyToolWindow = ((Microsoft.MIEngine.CoreRegisters.ARM.CoreRegistersWindowControl)(target));
                return;

            case 2:
                this.RegistersView = ((System.Windows.Controls.DataGrid)(target));
                return;
            }
            this._contentLoaded = true;
        }
Example #2
0
        public CoreRegistersWindow(IServiceProvider svcProvider)
            : base(svcProvider)
        {
            Caption = "CoreRegistersWindow";

            ThreadHelper.ThrowIfNotOnUIThread( );
            var debugger = ( IVsDebugger )GetService(typeof(SVsShellDebugger));

            Debug.Assert(debugger != null);

            // This is the user control hosted by the tool window; Note that, even if this class implements IDisposable,
            // we are not calling Dispose on this object. This is because ToolWindowPane calls Dispose on
            // the object returned by the Content property. Setting it on a private field and overriding the
            // Content property avoids the problem of calling a virtual in the constructor.
            ContentControl = new CoreRegistersWindowControl(new CoreRegistersViewModel(debugger));
        }