Beispiel #1
0
 public FormDesigner()
 {
     this.UniqueID       = "application" + projectCOunter;
     propertyWindow      = new PropertyWindow();
     projectExplorer     = new ProjectExplorer(this);
     dataPatternExplorer = new DataPatternExlorer(this);
     displayNameExplorer = new DisplayNameExplorer(this);
     webServiceExplorer  = new EIBFormDesigner.Designer.WebServiceExplorer.WebServiceExplorer(this);
     eventManager        = getEventManagerInstance();
     DragDropHandler.Initialize(eventManager, this);
     this.Disposed += new EventHandler(FormDesigner_Disposed);
     InitializeComponent();
     ToolBoxWindow.form = this;
     toolBoxWindow      = new ToolBoxWindow();
     startupImage       = new StartupHIC();
     formulaEditor      = new FormulaEditorWindow(this);
     workEditor         = new WorkflowEditorWindow(this);
     buildtool          = new EIBFormDesigner.Build.BuildTool(this);
     buildwindow        = new BuildWindow(this);
     setFromPatternsForACL();
     //UserAdmin.UserAdminConstants.CompanyId = company;
     //UserAdmin.UserAdminConstants.CompanyName = company;
     history = new UndoRedoHistory <ControlPool>(controlpool);
     this.SetStyle(ControlStyles.DoubleBuffer, true);
     this.SetStyle(ControlStyles.UserPaint, true);
     this.SetStyle(ControlStyles.AllPaintingInWmPaint, true);
 }
Beispiel #2
0
 public IUIEventManager getEventManagerInstance()
 {
     if (eventManager == null)
     {
         eventManager = new UIEventManager(this);
     }
     return(eventManager);
 }
Beispiel #3
0
        private static bool m_IsSimpleDrag = false;                     // Is this a simple drag?

        /// <summary>
        /// Initializes the DragDropHandler
        /// </summary>
        public static void Initialize(IUIEventManager eManager, EIBFormDesigner.Designer.FormDesigner designer)
        {
            eventManager = eManager;
            form         = designer;
            if (m_Initialized)
            {
                return;
            }

            int idx = 0;

            // Collection of DataFormats from the app.config file
            NameValueCollection nvc =
                (NameValueCollection)ConfigurationSettings.GetConfig(m_DFSection);

            if (nvc == null)
            {
                throw new Exception("Invalid section requested during Initialization.");
            }

            // Store the collection in our internal collection
            for (idx = 0; idx < nvc.Count; idx++)
            {
                // Get the custom string for our new DataFormat
                // and generate a new DataFormat for it
                DataFormats.Format frmt = DataFormats.GetFormat(nvc[idx]);

                // Store the new DataFormat by object type
                m_htDataFormats.Add(nvc.GetKey(idx), frmt);
            }

            // Collection of DataFormatParents from the app.config file
            nvc = (NameValueCollection)ConfigurationSettings.GetConfig(m_DFPSection);

            // Store the collection in our internal collection
            for (idx = 0; idx < nvc.Count; idx++)
            {
                // Store the DataFormatParent mappins by parent object type
                // The value is a string[] of DataFormats that can be DragDropped
                // on the parent
                m_htDFParents.Add(nvc.GetKey(idx),
                                  ((string)nvc[idx]).Split(new Char[] { ',' }));
            }

            m_Initialized = true;
        }
Beispiel #4
0
 public FormDesigner()
 {
     this.UniqueID = "application" + projectCOunter;
     propertyWindow = new PropertyWindow();
     projectExplorer = new ProjectExplorer(this);
     dataPatternExplorer = new DataPatternExlorer(this);
     displayNameExplorer = new DisplayNameExplorer(this);
     webServiceExplorer = new EIBFormDesigner.Designer.WebServiceExplorer.WebServiceExplorer(this);
     eventManager = getEventManagerInstance();
     DragDropHandler.Initialize(eventManager, this);
     this.Disposed += new EventHandler(FormDesigner_Disposed);
     InitializeComponent();
     ToolBoxWindow.form = this;
     toolBoxWindow = new ToolBoxWindow();
     startupImage = new StartupHIC();
     formulaEditor = new FormulaEditorWindow(this);
     workEditor = new WorkflowEditorWindow(this);
     buildtool = new EIBFormDesigner.Build.BuildTool(this);
     buildwindow = new BuildWindow(this);
     setFromPatternsForACL();
     //UserAdmin.UserAdminConstants.CompanyId = company;
     //UserAdmin.UserAdminConstants.CompanyName = company;
     history = new UndoRedoHistory<ControlPool>(controlpool);
     this.SetStyle(ControlStyles.DoubleBuffer, true);
     this.SetStyle(ControlStyles.UserPaint, true);
     this.SetStyle(ControlStyles.AllPaintingInWmPaint, true);
 }
Beispiel #5
0
 public IUIEventManager getEventManagerInstance()
 {
     if (eventManager == null)
     {
         eventManager = new UIEventManager(this);
     }
     return eventManager;
 }
Beispiel #6
0
        /// <summary>
        /// Initializes the DragDropHandler
        /// </summary>
        public static void Initialize(IUIEventManager eManager, EIBFormDesigner.Designer.FormDesigner designer)
        {
            eventManager = eManager;
            form = designer;
            if (m_Initialized)
                return;

            int idx = 0;

            // Collection of DataFormats from the app.config file
            NameValueCollection nvc =
                (NameValueCollection)ConfigurationSettings.GetConfig(m_DFSection);

            if (nvc == null)
                throw new Exception("Invalid section requested during Initialization.");

            // Store the collection in our internal collection
            for (idx = 0; idx < nvc.Count; idx++)
            {
                // Get the custom string for our new DataFormat
                // and generate a new DataFormat for it
                DataFormats.Format frmt = DataFormats.GetFormat(nvc[idx]);

                // Store the new DataFormat by object type
                m_htDataFormats.Add(nvc.GetKey(idx), frmt);
            }

            // Collection of DataFormatParents from the app.config file
            nvc = (NameValueCollection)ConfigurationSettings.GetConfig(m_DFPSection);

            // Store the collection in our internal collection
            for (idx = 0; idx < nvc.Count; idx++)
            {
                // Store the DataFormatParent mappins by parent object type
                // The value is a string[] of DataFormats that can be DragDropped
                // on the parent
                m_htDFParents.Add(nvc.GetKey(idx),
                    ((string)nvc[idx]).Split(new Char[] { ',' }));
            }

            m_Initialized = true;
        }
Beispiel #7
0
 public PanelStackController(IPanelStackSystem stackSystem, IPanelViewContainer viewContainer, IUIEventManager eventManager = null)
 {
     panelStackSystem  = stackSystem;
     container         = viewContainer;
     this.eventManager = eventManager;
 }
        private static PanelStackController CreateStackController(IPanelStackSystem stackSystem = null, IPanelViewContainer viewContainer = null, IUIEventManager eventManager = null)
        {
            if (stackSystem == null)
            {
                stackSystem = new FakePanelStackSystem();
            }

            if (viewContainer == null)
            {
                viewContainer = new FakeViewContainer();
            }

            if (eventManager == null)
            {
                eventManager = new FakeUIEventManager();
            }

            return(new PanelStackController(stackSystem, viewContainer, eventManager));
        }