71 if ( m_CombinedModality.IsNull() )
73 MITK_WARN(
"QmitkUSNavigationFreezeButton")
74 <<
"Cannot freeze the device as the device is null.";
75 this->setChecked(
false);
76 m_FreezeButtonToggle =
true;
79 m_FreezeButtonToggle = !checked;
82 mitk::NavigationDataSource::Pointer navigationDataSource = m_CombinedModality->GetNavigationDataSource();
83 if ( navigationDataSource.IsNull() )
85 MITK_WARN(
"QmitkUSNavigationFreezeButton")
86 <<
"Cannot freeze the device as the NavigationDataSource is null.";
87 this->setChecked(
false);
93 MITK_INFO <<
"Freezing";
95 m_CombinedModality->SetIsFreezed(
true);
97 if ( m_OutputIndex >= 0 )
100 navigationDataSource->Update();
105 ! navigationDataSource->GetOutput(m_OutputIndex)->IsDataValid() )
107 MITK_WARN(
"QmitkUSNavigationStepZoneMarking")(
"QmitkUSNavigationStepTumourSelection")
108 <<
"Unfreezing device as the last tracking data of the reference sensor wasn't valid.";
110 m_CombinedModality->SetIsFreezed(
false);
111 this->setChecked(
false);
120 MITK_INFO <<
"Unfreezing";