diff --git a/GUI/coregui/Models/OutputDataItem.cpp b/GUI/coregui/Models/OutputDataItem.cpp index 53d3d21e416ed265e7ac1ecd86edf18ff642a9ae..4a49f3ff00c20b36f2b88e32bbbcdd61066beafa 100644 --- a/GUI/coregui/Models/OutputDataItem.cpp +++ b/GUI/coregui/Models/OutputDataItem.cpp @@ -34,6 +34,8 @@ void OutputDataItem::setOutputData(OutputData<double> *data) qDebug() << "OutputDataItem::setOutputData(OutputData<double> *data)"; delete m_data; m_data = data; + m_xaxis_title = QString(data->getAxis(0)->getName().c_str()); + m_yaxis_title = QString(data->getAxis(1)->getName().c_str()); emit modified(); } } diff --git a/GUI/coregui/Views/InstrumentView.cpp b/GUI/coregui/Views/InstrumentView.cpp index 8c92ed47c6bd029c89c28e31684d357411a0004a..a5cad1326474fd45a67bc7e2c1ebdc6bb9442cd4 100644 --- a/GUI/coregui/Views/InstrumentView.cpp +++ b/GUI/coregui/Views/InstrumentView.cpp @@ -49,11 +49,9 @@ InstrumentView::InstrumentView(InstrumentModel *model, QWidget *parent) createActions(); - if(m_instrumentModel->rowCount(QModelIndex()) == 0) { + if(m_instrumentModel->rowCount(QModelIndex()) == 0) onAddInstrument(); - onAddInstrument(); - onAddInstrument(); - } + updateView(); } @@ -62,7 +60,6 @@ void InstrumentView::updateView() { qDebug() << "InstrumentView::updateView()"; m_instrumentSelector->updateSelection(); -// updateMapOfNames(); }