예제 #1
0
 public override void OnClick()
 {
     if (_dockPanelService == null)
     {
         _dockPanelService = _context.Container.GetInstance <TemplateDockPanelService>();
     }
     if (_dockPanelService.Visible == false)
     {
         _dockPanelService.Show();
         return;
     }
     else
     {
         _dockPanelService.Hide();
     }
 }
예제 #2
0
        public override void Initialize(IAppContext context)
        {
            _context       = context;
            _menuGenerator = context.Container.GetInstance <MenuGenerator>();

            //_menuListener = context.Container.GetInstance<MenuListener>();
            //_mapListener = context.Container.GetInstance<MapListener>();
            _dockPanelService = context.Container.GetInstance <TemplateDockPanelService>();

            //获取配置对象
            _pipelineConfig = context.Container.GetSingleton <PipelineConfig>();
            if (string.IsNullOrEmpty(_pipelineConfig.XmlFile))
            {
                string fileName =
                    ((ISecureContext)_context).YutaiProject.FindPlugin("4a3bcaab-9d3e-4ca7-a19d-7ee08fb0629e")
                    .ConfigXML;
                if (string.IsNullOrEmpty(fileName))
                {
                    return;
                }
                //fileName = FileHelper.GetFullPath(fileName);
                //_pipelineConfig.LoadFromXml(fileName);
            }
        }