protected override void Initialize(object navigationData) { base.Initialize(navigationData); var service = (IConfigurationService)ServiceProvider.GetService(typeof(IConfigurationService)); pictureBox1.Image = service.Scope.GetImage(); var info = (Tuple <InboundFeature, InboundRule>)navigationData; _feature = info.Item1; Rule = info.Item2; txtName.ReadOnly = Rule != null; if (Rule != null) { // TODO: invoke RuleSettingsUpdate somewhere. Rule.RuleSettingsUpdated = Refresh; } if (Rule == null) { Rule = new InboundRule(null); Rule.Enabled = true; } Refresh(); }
protected override void Initialize(object navigationData) { base.Initialize(navigationData); // TODO: pictureBox1.Image var info = (Tuple <InboundFeature, InboundRule>)navigationData; _feature = info.Item1; this.Rule = info.Item2; txtName.ReadOnly = this.Rule != null; if (this.Rule != null) { // TODO: invoke RuleSettingsUpdate somewhere. this.Rule.RuleSettingsUpdated = this.Refresh; } if (this.Rule == null) { this.Rule = new InboundRule(null); Rule.Enabled = true; } this.Refresh(); }