Exemplo n.º 1
0
        protected override void AddHandler(object sender, EventArgs e)
        {
            var record = new TSPoint();

            using (var dlg = new TSPointEditDlg()) {
                dlg.SetContext(fModel, record);

                if (dlg.ShowModal())
                {
                    fModel.TSDB.AddPoint(record);
                    UpdateContent();
                }
            }
        }
Exemplo n.º 2
0
        protected override void EditHandler(object sender, EventArgs e)
        {
            var record = ListView.GetSelectedTag <TSPoint>();

            if (record == null)
            {
                return;
            }

            using (var dlg = new TSPointEditDlg()) {
                dlg.SetContext(fModel, record);

                if (dlg.ShowModal())
                {
                    fModel.TSDB.UpdatePoint(record);
                    UpdateContent();
                }
            }
        }