Ejemplo n.º 1
0
        public void SetSite(IAgUiPluginEmbeddedControlSite site)
        {
            _mPEmbeddedControlSite = site;
            _mUiPlugin             = _mPEmbeddedControlSite.Plugin as Setup;
            _mStkObjectsLibrary    = new StkObjectsLibrary();

            //EXAMPLE: Hooking to STK Exents
            CommonData.StkRoot.OnStkObjectAdded   += new IAgStkObjectRootEvents_OnStkObjectAddedEventHandler(m_root_OnStkObjectAdded);
            CommonData.StkRoot.OnStkObjectDeleted += new IAgStkObjectRootEvents_OnStkObjectDeletedEventHandler(m_root_OnStkObjectDeleted);

            CommonData.DirectoryStr = _mStkObjectsLibrary.GetScenarioDirectory();

            CommonData.SavedViewList     = new List <ViewData>();
            CommonData.InitialObjectData = SmartViewFunctions.GetObjectData();

            PopulateContextViews();
            _mPEmbeddedControlSite.Window.Width = _toolbarWidth + 5;
        }
        public void SetSite(IAgUiPluginEmbeddedControlSite site)
        {
            _mPEmbeddedControlSite = site;
            _mUiPlugin             = _mPEmbeddedControlSite.Plugin as Setup;
            _mStkObjectsLibrary    = new StkObjectsLibrary();

            //EXAMPLE: Hooking to STK Exents
            CommonData.StkRoot.OnStkObjectAdded      += new IAgStkObjectRootEvents_OnStkObjectAddedEventHandler(m_root_OnStkObjectAdded);
            CommonData.StkRoot.OnStkObjectDeleted    += new IAgStkObjectRootEvents_OnStkObjectDeletedEventHandler(m_root_OnStkObjectDeleted);
            CommonData.StkRoot.OnScenarioSave        += new IAgStkObjectRootEvents_OnScenarioSaveEventHandler(m_root_OnStkSave);
            CommonData.StkRoot.OnScenarioBeforeClose += new IAgStkObjectRootEvents_OnScenarioBeforeCloseEventHandler(m_root_OnStkScenarioClose);
            CommonData.StkRoot.OnAnimationPlayback   += new IAgStkObjectRootEvents_OnAnimationPlaybackEventHandler(m_root_OnStkAnimationPlayback);
            CommonData.StkRoot.OnAnimationPause      += new IAgStkObjectRootEvents_OnAnimationPauseEventHandler(m_root_OnStkAnimationPause);

            CommonData.DirectoryStr = _mStkObjectsLibrary.GetScenarioDirectory();

            CommonData.SavedViewList     = new List <ViewData>();
            CommonData.InitialObjectData = SmartViewFunctions.GetObjectData();

            PopulateContextViews();
            AutoSize();
        }