コード例 #1
0
ファイル: ReflectNew.cs プロジェクト: swaros/projector
        private GroupQuery getGroupQuery(ReflectionScriptDefines refObject, Object parent)
        {
            if (this.obReferences.ContainsKey(refObject.name))
            {
                Object hValue = obReferences[refObject.name];
                if (hValue is GroupQuery)
                {
                    GroupQuery exists = (GroupQuery)hValue;

                    try
                    {
                        //exists.Show();
                        //exists.BringToFront();
                        //exists.Show();
                        exists.imHere = true;
                        return(exists);
                    }
                    catch (ObjectDisposedException disposed)
                    {
                        this.obReferences.Remove(refObject.name);
                    }
                }
            }

            GroupQuery grQuery = new GroupQuery();

            grQuery.Name = refObject.name;

            if (parent is MdiForm)
            {
                MdiForm mdi = (MdiForm)parent;
                mdi.addSubWindow(grQuery, refObject.name);
            }
            //grQuery.Show();

            if (!this.obReferences.ContainsKey(refObject.name))
            {
                this.obReferences.Add(refObject.name, grQuery);
            }
            return(grQuery);
        }
コード例 #2
0
ファイル: ReflectNew.cs プロジェクト: swaros/projector
        private queryBrowser getQueryBrowser(ReflectionScriptDefines refObject, Object parent)
        {
            queryBrowser browser = new queryBrowser();

            browser.Name        = refObject.name;
            browser.ScriptIdent = refObject.name;

            if (parent is MdiForm)
            {
                MdiForm      mdi        = (MdiForm)parent;
                queryBrowser existingQb = (queryBrowser)mdi.getQueryForm(refObject.name);
                if (null == existingQb)
                {
                    mdi.addQueryWindow(browser);
                }
                else
                {
                    return(existingQb);
                }
            }

            return(browser);
        }
コード例 #3
0
ファイル: ReflectNew.cs プロジェクト: swaros/projector
        private ReflectForm getForm(ReflectionScriptDefines refObject, Object parent)
        {
            ReflectForm newForm;

            newForm = (ReflectForm)this.getExistingObject(refObject.name);
            string objToken = refObject.name;

            if (newForm == null)
            {
                newForm = new ReflectForm();
            }
            newForm.ScriptIdent = refObject.name;
            newForm.Name        = objToken;
            if (parent is MdiForm)
            {
                MdiForm mdi = (MdiForm)parent;
                mdi.addSubWindow(newForm, refObject.name);
            }
            else if (parent is Form)
            {
                this.showRForm(newForm, refObject.name);
            }
            else if (parent is ReflectionScript)
            {
                ReflectionScript parScr = (ReflectionScript)parent;
                if (parScr.SetupBoolValue(ReflectionScript.SETUP_PREVIEW))
                {
                    this.showRForm(newForm, refObject.name);
                }
            }
            else
            {
                this.showRForm(newForm, refObject.name);
            }
            this.addObject(refObject.name, newForm);
            return(newForm);
        }