Skip to content
Snippets Groups Projects
Commit c5a19d95 authored by Samuel Jones's avatar Samuel Jones
Browse files

Re #23570 Reduce calls to fillrows()

parent b080f742
No related branches found
No related tags found
No related merge requests found
...@@ -44,8 +44,8 @@ ProjectRecoveryPresenter::~ProjectRecoveryPresenter() { ...@@ -44,8 +44,8 @@ ProjectRecoveryPresenter::~ProjectRecoveryPresenter() {
bool ProjectRecoveryPresenter::startRecoveryView() { bool ProjectRecoveryPresenter::startRecoveryView() {
try { try {
m_openView = RecoveryView;
m_recView = new ProjectRecoveryView(m_mainWindow, this); m_recView = new ProjectRecoveryView(m_mainWindow, this);
m_openView = RecoveryView;
m_recView->exec(); m_recView->exec();
} catch (...) { } catch (...) {
return true; return true;
...@@ -65,8 +65,8 @@ bool ProjectRecoveryPresenter::startRecoveryView() { ...@@ -65,8 +65,8 @@ bool ProjectRecoveryPresenter::startRecoveryView() {
bool ProjectRecoveryPresenter::startRecoveryFailure() { bool ProjectRecoveryPresenter::startRecoveryFailure() {
try { try {
m_openView = FailureView;
m_failureView = new RecoveryFailureView(m_mainWindow, this); m_failureView = new RecoveryFailureView(m_mainWindow, this);
m_openView = FailureView;
m_failureView->exec(); m_failureView->exec();
} catch (...) { } catch (...) {
return true; return true;
...@@ -182,4 +182,9 @@ void ProjectRecoveryPresenter::changeStartMantidToCancelLabel() { ...@@ -182,4 +182,9 @@ void ProjectRecoveryPresenter::changeStartMantidToCancelLabel() {
} }
} }
void ProjectRecoveryPresenter::fillAllRows() { m_model->fillRows(); } void ProjectRecoveryPresenter::fillAllRows() {
\ No newline at end of file // Only allow this to run once, first run will have value RecoveryView
if (m_openView == RecoveryView) {
m_model->fillRows();
}
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment