SLOTs for changes triggered in XYFitCurveDock
| 187 | //**** SLOTs for changes triggered in XYFitCurveDock ***** |
| 188 | //************************************************************* |
| 189 | void XYSmoothCurveDock::dataSourceTypeChanged(int index) { |
| 190 | auto type = (XYAnalysisCurve::DataSourceType)index; |
| 191 | if (type == XYAnalysisCurve::DataSourceType::Spreadsheet) { |
| 192 | uiGeneralTab.lDataSourceCurve->hide(); |
| 193 | cbDataSourceCurve->hide(); |
| 194 | uiGeneralTab.lXColumn->show(); |
| 195 | cbXDataColumn->show(); |
| 196 | uiGeneralTab.lYColumn->show(); |
| 197 | cbYDataColumn->show(); |
| 198 | } else { |
| 199 | uiGeneralTab.lDataSourceCurve->show(); |
| 200 | cbDataSourceCurve->show(); |
| 201 | uiGeneralTab.lXColumn->hide(); |
| 202 | cbXDataColumn->hide(); |
| 203 | uiGeneralTab.lYColumn->hide(); |
| 204 | cbYDataColumn->hide(); |
| 205 | } |
| 206 | |
| 207 | CONDITIONAL_LOCK_RETURN; |
| 208 | |
| 209 | for (auto* curve : m_curvesList) |
| 210 | static_cast<XYSmoothCurve*>(curve)->setDataSourceType(type); |
| 211 | |
| 212 | enableRecalculate(); |
| 213 | } |
| 214 | |
| 215 | void XYSmoothCurveDock::xDataColumnChanged(const QModelIndex& index) { |
| 216 | CONDITIONAL_LOCK_RETURN; |
no test coverage detected