void checkBoxX_CheckedChangedEx(object sender, DevComponents.DotNetBar.Controls.CheckBoxXChangeEventArgs e) { if (e.EventSource != eEventSource.Code) { uint blackhandle = (e.NewChecked.Tag as Tuple <uint, uint>).Item1; uint subscribehandle = (e.NewChecked.Tag as Tuple <uint, uint>).Item2; if (e.NewChecked.Checked) { uint ret = m_viewModel.SubscribeFaceAlarm(groupPanel2.Tag.ToString(), blackhandle); if (ret > 0) { e.NewChecked.Tag = new Tuple <uint, uint>(blackhandle, ret); } else { e.NewChecked.Checked = false; } } else { m_viewModel.UnsubscribeFaceAlarm(groupPanel2.Tag.ToString(), subscribehandle); } advTree1.DataSource = m_viewModel.FaceSubscribe; } }
private void CheckBoxX_CustomModel_CheckedChanging(object sender, DevComponents.DotNetBar.Controls.CheckBoxXChangeEventArgs e) { if (!isLoadingProps && e.EventSource != eEventSource.Code) { e.Cancel = e.NewChecked.Checked || !SelectCustomModelFromBank(); } }
private void CheckBoxX_CheckingChanging(object sender, DevComponents.DotNetBar.Controls.CheckBoxXChangeEventArgs e) { e.Cancel = !isLoadingProps && e.EventSource != eEventSource.Code && e.NewChecked.Checked; }