Exemple #1
0
        void OnTreeviewSelectionChanged(object sender, EventArgs e)
        {
            bool selected = ytreeviewRef.Selection.CountSelectedRows() > 0;

            buttonSelect.Sensitive = selected;
            buttonEdit.Sensitive   = ButtonMode.HasFlag(ReferenceButtonMode.CanEdit) && selected;
            buttonDelete.Sensitive = ButtonMode.HasFlag(ReferenceButtonMode.CanDelete) && selected;
        }
Exemple #2
0
 protected void OnYtreeviewRefRowActivated(object o, RowActivatedArgs args)
 {
     if (Mode == OrmReferenceMode.Select || Mode == OrmReferenceMode.MultiSelect)
     {
         buttonSelect.Click();
     }
     else if (ButtonMode.HasFlag(ReferenceButtonMode.CanEdit))
     {
         buttonEdit.Click();
     }
 }