Exemplo n.º 1
0
        private void btn_Alerts_Add_Click(object sender, EventArgs e)
        {
            f_AddAlert faa = new f_AddAlert();

            faa.bday = bday;
            faa.ShowDialog();
            if (faa.ok)
            {
                bday.alerts.Add(faa.alert);
            }

            fillAlerts();
        }
Exemplo n.º 2
0
 private void lv_Alerts_DoubleClick(object sender, EventArgs e)
 {
     if (lv_Alerts.FocusedItem != null)
     {
         f_AddAlert fa = new f_AddAlert();
         fa.edit  = true;
         fa.bday  = bday;
         fa.alert = lv_Alerts.FocusedItem.Tag as Alert;
         fa.ShowDialog();
         if (fa.ok)
         {
             bday.alerts.Remove(lv_Alerts.FocusedItem.Tag as Alert);
             bday.alerts.Add(fa.alert);
         }
         fillAlerts();
     }
 }