Public Class NestingRunningWndV

   Private WithEvents m_NestingRunningWndVM As NestingRunningWndVM

   Sub New(Owner As Window, NestingRunningWndVM As NestingRunningWndVM)
      MyBase.New(Owner)
      ' This call is required by the designer.
      InitializeComponent()
      Me.DataContext = NestingRunningWndVM
      ' Assegno al riferimento locale al VM il VM preso dal DataContext
      m_NestingRunningWndVM = NestingRunningWndVM
   End Sub

   Private Sub CloseWindow(bDialogResult As Boolean) Handles m_NestingRunningWndVM.m_CloseWindow
      Me.DialogResult = bDialogResult
   End Sub

   Private Sub Me_ContentRendered() Handles Me.ContentRendered
      m_NestingRunningWndVM.StartCalculating()
   End Sub

End Class
