Exemple #1
0
 public override void Assign(RepositoryItem item)
 {
     BeginUpdate();
     try {
         base.Assign(item);
         RepositoryItemToggleSwitch source = item as RepositoryItemToggleSwitch;
         if (source == null)
         {
             return;
         }
         OnText   = source.OnText;
         OffText  = source.OffText;
         OnImage  = source.OnImage;
         OffImage = source.OffImage;
         Events.AddHandler(_toggled, source.Events[_toggled]);
     }
     finally {
         EndUpdate();
     }
 }
Exemple #2
0
 static ToggleSwitch()
 {
     RepositoryItemToggleSwitch.RegisterCustomEdit();
 }