void Aveva.ApplicationFramework.IAddin.Start(ServiceManager serviceManager)
        {
            mServiceManager	= serviceManager;
            mWindowManager	= (WindowManager)serviceManager.GetService(typeof(WindowManager));
            mCommandBarManager	= (CommandBarManager)serviceManager.GetService(typeof(CommandBarManager));

            mCommandBarManager.RootTools.ToolAdded+=new ToolEventHandler(RootTools_ToolAdded);

            //Create an instance of Addin control
            mAddinControl = new NetGridAddinControl();

            //Add the Addin
            mAddinWindow = (DockedWindow)mWindowManager.CreateDockedWindow("Grid Control Addin", "Grid Control Addin", mAddinControl, DockedPosition.Left);
            mAddinWindow.Width = 225;

            mAddinWindow.Closing +=new System.ComponentModel.CancelEventHandler(mAddinWindow_Closing);

            //Hide
            mAddinWindow.Hide();

            //Load custom menus
            mCommandBarManager.UILoaded +=new EventHandler(mCommandBarManager_UILoaded);
        }
Exemple #2
0
        void Aveva.ApplicationFramework.IAddin.Start(ServiceManager serviceManager)
        {
            mServiceManager    = serviceManager;
            mWindowManager     = (WindowManager)serviceManager.GetService(typeof(WindowManager));
            mCommandBarManager = (CommandBarManager)serviceManager.GetService(typeof(CommandBarManager));

            mCommandBarManager.RootTools.ToolAdded += new ToolEventHandler(RootTools_ToolAdded);

            //Create an instance of Addin control
            mAddinControl = new NetGridAddinControl();

            //Add the Addin
            mAddinWindow       = (DockedWindow)mWindowManager.CreateDockedWindow("Grid Control Addin", "Grid Control Addin", mAddinControl, DockedPosition.Left);
            mAddinWindow.Width = 225;

            mAddinWindow.Closing += new System.ComponentModel.CancelEventHandler(mAddinWindow_Closing);

            //Hide
            mAddinWindow.Hide();

            //Load custom menus
            mCommandBarManager.UILoaded += new EventHandler(mCommandBarManager_UILoaded);
        }