Exemplo n.º 1
0
        private void backgroundWorker1_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            SR2DClassBound dataBound = new SR2DClassBound(database, networkControl, vars);

            MainForm mainForm = new MainForm(dataBound, this);

            mainForm.Show();

            this.Visible = false;
        }
Exemplo n.º 2
0
        public foodTypeInfoForm(foodTypeForm fTF, SR2DClassBound cB, DataRow refDR)
        {
            InitializeComponent();

            this.fTF   = fTF;
            this.cB    = cB;
            this.db    = cB.db;
            this.refDR = refDR;

            init();
        }
Exemplo n.º 3
0
        public foodTypeAddForm(foodTypeForm fTF, SR2DClassBound cB)
        {
            InitializeComponent();

            this.fTF = fTF;
            this.cB  = cB;
            this.db  = cB.db;

            othersFoodTypeIDs = new List <int>();

            fillChListbox();
        }
Exemplo n.º 4
0
        public foodAddForm(foodForm fF, SR2DClassBound cB)
        {
            InitializeComponent();

            this.fF = fF;
            this.cB = cB;
            this.db = cB.db;

            foodTypeIDs = new List <int>();

            fill();
        }
Exemplo n.º 5
0
        public foodModifyForm(foodForm fF, SR2DClassBound cB, DataRow refDR)
        {
            InitializeComponent();

            this.fF    = fF;
            this.cB    = cB;
            this.db    = cB.db;
            this.refDR = refDR;

            foodTypeIDs = new List <int>();

            fill();
        }
Exemplo n.º 6
0
        public userInfosForm(SR2DClassBound cB, userForm cF, DataRow dr)
        {
            InitializeComponent();

            this.cF             = cF;
            this.cB             = cB;
            this.db             = cB.db;
            this.networkControl = cB.networkControler;

            this.dr = dr;

            load();
        }
Exemplo n.º 7
0
        public userForm(MainForm mF, SR2DClassBound cB)
        {
            InitializeComponent();

            this.mF = mF;

            this.cB             = cB;
            this.db             = cB.db;
            this.networkControl = cB.networkControler;

            fillGridView();

            db.Ds.DatasetUpdatedEvent += new SR2DDataset.EventHandler(update);
        }
Exemplo n.º 8
0
        public foodTypeModifyForm(foodTypeForm fTF, SR2DClassBound cB, DataRow refDR)
        {
            InitializeComponent();

            this.fTF   = fTF;
            this.cB    = cB;
            this.db    = cB.db;
            this.refDR = refDR;

            othersFoodTypeInitialState = new List <CheckState>();
            othersFoodTypeIDs          = new List <int>();

            fill();
        }
Exemplo n.º 9
0
        public foodTypeForm(foodForm fF, SR2DClassBound cB)
        {
            InitializeComponent();

            this.fF = fF;
            this.cB = cB;
            this.db = cB.db;

            db.Ds.DatasetUpdatedEvent += new SR2DDataset.EventHandler(update);

            setServiceMode();

            fillGridView();
        }
Exemplo n.º 10
0
        public MainForm(SR2DClassBound cB, initForm iF)
        {
            InitializeComponent();

            this.cB = cB;

            this.database         = cB.db;
            this.networkControler = cB.networkControler;

            database.Ds.DatasetUpdatedEvent += new SR2DDataset.EventHandler(update);

            updateHUD();

            this.iF = iF;
        }
Exemplo n.º 11
0
        public foodForm(MainForm baseForm, SR2DClassBound cB)
        {
            InitializeComponent();

            this.networkControler = cB.networkControler;

            this.db       = cB.db;
            this.baseForm = baseForm;
            this.cB       = cB;

            this.Height = baseForm.Height - 150;
            this.Width  = baseForm.Width - 200;

            this.CenterToParent();

            db.Ds.DatasetUpdatedEvent += new SR2DDataset.EventHandler(update);

            setServiceMode();

            fillGridView();
        }
Exemplo n.º 12
0
        public ServiceManagerForm(MainForm mF, SR2DClassBound cB)
        {
            InitializeComponent();

            this.cB = cB;
            this.db = cB.db;

            this.mF = mF;

            db.Ds.DatasetUpdatedEvent += new SR2DDataset.EventHandler(update);

            #region INIT_CHARTS
            var mapper = Mappers.Xy <MeasureModel>()
                         .X(model => model.DateTime.Ticks) //use DateTime.Ticks as X
                         .Y(model => model.Value);         //use the value property as Y

            //lets save the mapper globally.
            Charting.For <MeasureModel>(mapper);

            //the ChartValues property will store our values array
            reserv  = new ChartValues <MeasureModel>();
            retired = new ChartValues <MeasureModel>();

            cartesianChart1.Series = new SeriesCollection
            {
                new LineSeries
                {
                    Values         = reserv,
                    PointGeometry  = null,
                    LineSmoothness = 0.5
                }
            };

            cartesianChart1.DataTooltip = null;



            cartesianChart1.AxisX.Add(new Axis
            {
                DisableAnimations = false,
                LabelFormatter    = value => new System.DateTime((long)value).ToString("HH:mm:ss"),
                Separator         = new Separator
                {
                    Step = TimeSpan.FromSeconds(60).Ticks
                }
            });

            cartesianChart1.AxisY.Add(new Axis
            {
                Separator = new Separator
                {
                    Step = 1,
                }
            });

            cartesianChart1.AxisY[0].MinValue = 0;

            SetAxisLimits(System.DateTime.Now, cartesianChart1);

            cartesianChart2.Series = new SeriesCollection
            {
                new LineSeries
                {
                    Values         = retired,
                    PointGeometry  = null,
                    LineSmoothness = 0.5
                }
            };

            cartesianChart2.DataTooltip = null;



            cartesianChart2.AxisX.Add(new Axis
            {
                DisableAnimations = false,
                LabelFormatter    = value => new System.DateTime((long)value).ToString("HH:mm:ss"),
                Separator         = new Separator
                {
                    Step = TimeSpan.FromSeconds(60).Ticks
                }
            });

            cartesianChart2.AxisY.Add(new Axis
            {
                Separator = new Separator
                {
                    Step = 1,
                }
            });

            cartesianChart2.AxisY[0].MinValue = 0;

            SetAxisLimits(System.DateTime.Now, cartesianChart2);

            guiUpdate();

            timer = new Timer
            {
                Interval = 5000
            };
            timer.Tick += timerOnTick;

            timer.Start();

            #endregion

            #region INIT_LIST

            objectListView1.CellEditActivation = ObjectListView.CellEditActivateMode.DoubleClick;
            objectListView1.ShowGroups         = true;
            objectListView1.Sort(2);

            populateDispList();

            updatePrep();

            #endregion

            setServiceMode();
        }