+ProjectionFileDocument::~ProjectionFileDocument()
+{
+ for (BackgroundContainer::iterator i = m_vecpBackgroundSupervisors.begin();
+ i != m_vecpBackgroundSupervisors.end(); i++) {
+ (*i)->cancel();
+ }
+
+ m_vecpBackgroundSupervisors.clear();
+ delete m_pProjectionFile;
+}
+
+void
+ProjectionFileDocument::OnAddBackground (wxCommandEvent& event)
+{
+}
+
+void
+ProjectionFileDocument::OnRemoveBackground (wxCommandEvent& event)
+{
+}
+
+void
+ProjectionFileDocument::addReconstructor (BackgroundSupervisor* pRecon)
+{
+ wxCriticalSectionLocker locker (m_criticalSection);
+ m_vecpBackgroundSupervisors.push_back (pRecon);
+}
+
+void
+ProjectionFileDocument::removeReconstructor (BackgroundSupervisor* pRecon)
+{
+ wxCriticalSectionLocker locker (m_criticalSection);
+ bool bFound = false;
+ for (BackgroundContainer::iterator i = m_vecpBackgroundSupervisors.begin();
+ i != m_vecpBackgroundSupervisors.end();
+ i++)
+ if (*i == pRecon) {
+ m_vecpBackgroundSupervisors.erase(i);
+ bFound = true;
+ break;
+ }
+ if (! bFound)
+ sys_error (ERR_SEVERE, "Could not find background task [ProjectionFileDocument::removeBackgroundTask");
+}
+