Пример #1
0
 public AddBridgeViewModel(IAddBridgeView view, ChildBridge child) : this(view)
 {
     this.WindowTitle = "编辑桥梁";
     this.BridgeId    = child.Id;
     this.BridgeName  = child.Name;
     this.BridgePile  = child.PileId;
     this.BridgeType  = this.BridgeTypeCollection.First((p) => p.Id.Equals(child.TypeId));
 }
Пример #2
0
        public ChildBridge GetEditedChildBridge(ChildBridge child)
        {
            AddBridgeWindow abw = new AddBridgeWindow(child);

            abw.Owner = Window.GetWindow(this);
            if (abw.ShowDialog().Value)
            {
                return(abw.NewChildBridge);
            }

            return(null);
        }
Пример #3
0
 public AddBridgeWindow(ChildBridge child)
 {
     InitializeComponent();
     this.m_PopupMsg  = new PopupMessage();
     this.DataContext = new AddBridgeViewModel(this, child);
 }