public RulerForm(RulerInfo rulerInfo) { this.Init(rulerInfo); RulerApplicationContext context = RulerApplicationContext.CurrentContext; context.RegisterRuler(this); }
protected override void OnFormClosed(FormClosedEventArgs e) { lock (RulerApplicationContext.CurrentContext) { base.OnFormClosed(e); RulerApplicationContext context = RulerApplicationContext.CurrentContext; context.UnregisterRuler(this); } }
public RulerForm(RulerApplicationContext context, RulerInfo rulerInfo) { _context = context; _info = rulerInfo; this.Init(); }
public RulerForm(RulerApplicationContext context) { _context = context; _info = RulerInfo.GetDefaultRulerInfo(); this.Init(); }