Exemplo n.º 1
0
        public static GraphForm CreateNewWindow(Form mdiParent, DataSource dataSource, bool giveFocus)
        {
            // create a new window with this data source
            GraphForm graphForm = new GraphForm(dataSource);

            graphForm.MdiParent = mdiParent;
            graphForm.ShowData(0);               // show chromatogram
            graphForm.Show();
            if (giveFocus)
            {
                graphForm.Activate();
            }
            return(graphForm);
        }
Exemplo n.º 2
0
        public GraphForm OpenGraph( bool giveFocus )
        {
            GraphForm graphForm = new GraphForm(this);
            graphForm.ZedGraphControl.PreviewKeyDown += new PreviewKeyDownEventHandler( graphForm_PreviewKeyDown );
            graphForm.ItemGotFocus += new EventHandler( form_GotFocus );
            graphForm.Show( DockPanel, DockState.Document );
            if( giveFocus )
                graphForm.Activate();

            return graphForm;
        }