Exemplo n.º 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);
 }
Exemplo n.º 2
0
 public void displayFormulaProperties(FormulaEditorWindow form, IEIBControl controlObject)
 {
     try
     {
         if (form.SelectedNode != null)
         {
             if(form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.DefaultValue))
             {
                 form.formulaText.Text = controlObject.DefaultValue;
             }
             if(form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnClick))
             {
                 form.formulaText.Text = controlObject.OnClickValue;
             }
             else if(form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.Exiting))
             {
                 form.formulaText.Text = controlObject.ExitingValue;
             }
             else if(form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.Entering))
             {
                 form.formulaText.Text = controlObject.EnteringValue;
             }
             else if (form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnDoubleClick))
             {
                 form.formulaText.Text = controlObject.OnDoubleClick;
             }
         }
     }
     catch (Exception exp)
     {
         Console.Write(exp.StackTrace);
     }
 }
Exemplo n.º 3
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);
 }
Exemplo n.º 4
0
        public void displayFormulaProperties(FormulaEditorWindow form, IEIBControl controlObject)
        {
            try
            {
                form.designTree.Nodes[0].Nodes.RemoveByKey("OnCheck");
                form.designTree.Nodes[0].Nodes.RemoveByKey("GlobalScripts");
                form.designTree.Nodes[0].Nodes.RemoveByKey("OnOpen");
                form.designTree.Nodes[0].Nodes.RemoveByKey("OnSelect");
                form.designTree.Nodes[0].Nodes.RemoveByKey("OnChanging");
                if (controlObject is EIBCheckbox)
                {
                    if (!form.designTree.Nodes[0].Nodes.ContainsKey("OnCheck"))
                    {
                        System.Windows.Forms.TreeNode treeNode_onCheck = new System.Windows.Forms.TreeNode("OnCheck");
                        treeNode_onCheck.Name = "OnCheck";
                        form.designTree.Nodes[0].Nodes.Add(treeNode_onCheck);
                    }
                }
                if (controlObject is EIBPanel)
                {
                    if (!form.designTree.Nodes[0].Nodes.ContainsKey("GlobalScripts"))
                    {
                        System.Windows.Forms.TreeNode treeNode_globalScripts = new System.Windows.Forms.TreeNode("GlobalScripts");
                        treeNode_globalScripts.Name = "GlobalScripts";
                        form.designTree.Nodes[0].Nodes.Add(treeNode_globalScripts);
                    }
                }
                if (controlObject is EIBTreeNode)
                {
                    if (!form.designTree.Nodes[0].Nodes.ContainsKey("OnOpen"))
                    {
                        System.Windows.Forms.TreeNode treeNode_onOpen = new System.Windows.Forms.TreeNode("OnOpen");
                        treeNode_onOpen.Name = "OnOpen";
                        form.designTree.Nodes[0].Nodes.Add(treeNode_onOpen);
                    }
                }
                if (controlObject is EIBTreeView)
                {
                    if (!form.designTree.Nodes[0].Nodes.ContainsKey("OnSelect"))
                    {
                        System.Windows.Forms.TreeNode treeNode_onSelect = new System.Windows.Forms.TreeNode("OnSelect");
                        treeNode_onSelect.Name = "OnSelect";
                        form.designTree.Nodes[0].Nodes.Add(treeNode_onSelect);
                    }
                }
                if (controlObject is EIBGrid)
                {
                    if (!form.designTree.Nodes[0].Nodes.ContainsKey("OnSelect"))
                    {
                        System.Windows.Forms.TreeNode treeNode_onSelect = new System.Windows.Forms.TreeNode("OnSelect");
                        treeNode_onSelect.Name = "OnSelect";
                        form.designTree.Nodes[0].Nodes.Add(treeNode_onSelect);
                    }
                }
                if (controlObject is EIBCombobox)
                {
                    if (!form.designTree.Nodes[0].Nodes.ContainsKey("OnChanging"))
                    {
                        System.Windows.Forms.TreeNode treeNode_onChanging = new System.Windows.Forms.TreeNode("OnChanging");
                        treeNode_onChanging.Name = "OnChanging";
                        form.designTree.Nodes[0].Nodes.Add(treeNode_onChanging);
                    }
                    if (!form.designTree.Nodes[0].Nodes.ContainsKey("OnOpen"))
                    {
                        System.Windows.Forms.TreeNode treeNode_onOpen = new System.Windows.Forms.TreeNode("OnOpen");
                        treeNode_onOpen.Name = "OnOpen";
                        form.designTree.Nodes[0].Nodes.Add(treeNode_onOpen);
                    }

                }
                if (controlObject is EIBTextBox)
                {
                    if (!form.designTree.Nodes[0].Nodes.ContainsKey("OnChanging"))
                    {
                        System.Windows.Forms.TreeNode treeNode_onChanging = new System.Windows.Forms.TreeNode("OnChanging");
                        treeNode_onChanging.Name = "OnChanging";
                        form.designTree.Nodes[0].Nodes.Add(treeNode_onChanging);
                    }
                }
                if (form.SelectedNode != null)
                {
                    if(form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.DefaultValue))
                    {
                        form.formulaText.Text = controlObject.DefaultValue;
                    }
                    if(form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnClick))
                    {
                        form.formulaText.Text = controlObject.OnClickValue;
                    }
                    else if(form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.Exiting))
                    {
                        form.formulaText.Text = controlObject.ExitingValue;
                    }
                    else if(form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.Entering))
                    {
                        form.formulaText.Text = controlObject.EnteringValue;
                    }
                    else if (form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnDoubleClick))
                    {
                        form.formulaText.Text = controlObject.OnDoubleClick;
                    }
                    else if (form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnDrop))
                    {
                        form.formulaText.Text = controlObject.OnDrop;
                    }
                    else if (form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnFocus))
                    {
                        form.formulaText.Text = controlObject.OnFocus;
                    }
                    else if (form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnBlur))
                    {
                        form.formulaText.Text = controlObject.OnBlur;
                    }
                    else if (form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnEventCreate))
                    {
                        form.formulaText.Text = controlObject.OnEventCreateValue;
                    }
                    else if (form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnEventEdit))
                    {
                        form.formulaText.Text = controlObject.OnEventEditValue;
                    }
                    else if (form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnEventUpdate))
                    {
                        form.formulaText.Text = controlObject.OnEventUpdateValue;
                    }
                    else if (form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnChange))
                    {
                        form.formulaText.Text = controlObject.OnChange;
                    }
                    else if (form.SelectedNode.Name.Trim().Equals(FormDesignerConstants.OnOK))
                    {
                        form.formulaText.Text = controlObject.OnOK;
                    }
                }
            }
            catch (Exception exp)
            {
                Console.Write(exp.StackTrace);
            }
        }