private void ReadFuseBitsCommand(object sender, ExecutedRoutedEventArgs e) { var dlg = new ReadFuseBitsWindow { DataContext = new FlasherOperationModel(_model), Owner = this }; dlg.ShowDialog(); }
private void FuseBitsWindow_OnLoaded(object sender, RoutedEventArgs e) { var dlg = new ReadFuseBitsWindow { DataContext = new FlasherOperationModel(Model), Owner = this }; dlg.ShowDialog(); var settings = Model.Config; var fuseBits = settings.Device.FuseBits; var fusesData = Model.FusesHexBoard; fuseBits.ApplyFrom(fusesData); DeviceBitsView.DataContext = new DeviceBitsModel { HexBoard = Model.FusesHexBoard.Clone(), DeviceBits = fuseBits }; }