void QFRDROverviewImageDisplay::connectWidgets(QFRawDataRecord *current, QFRawDataRecord *old) { disconnect(cmbImage, SIGNAL(currentIndexChanged(int)), this, SLOT(displayImage())); disconnect(player, SIGNAL(showFrame(int)), this, SLOT(showFrame(int))); if (old) { this->current=NULL; disconnect(old, SIGNAL(rawDataChanged()), this, SLOT(rawDataChanged())); } QFRDRAdditionalImagesInterface* m=qobject_cast<QFRDRAdditionalImagesInterface*>(current); cmbImage->clear(); this->current=current; if (m&¤t) { connect(current, SIGNAL(rawDataChanged()), this, SLOT(rawDataChanged())); if (m) { for (int i=0; i<m->getAdditionalImagesCount(); i++) { cmbImage->addItem(QIcon(":/imaging_fcs/image.png"), m->getAdditionalImagesName(i)); } } QFRDRImageStackInterface* mv=dynamic_cast<QFRDRImageStackInterface*>(current); if (mv) { for (int i=0; i<mv->getImageStackCount(); i++) { cmbImage->addItem(QIcon(":/imaging_fcs/video.png"), mv->getImageStackDescription(i)); } } cmbImage->setCurrentIndex(current->getProperty("imfcs_invrimgdisp_image", 0).toInt()); player->setPosition(current->getProperty("imfcs_invrimgdisp_playpos", 0).toInt()); connect(cmbImage, SIGNAL(currentIndexChanged(int)), this, SLOT(displayImage())); connect(player, SIGNAL(showFrame(int)), this, SLOT(showFrame(int))); }
void QFRDRImagingFCSCountrateDisplay::connectWidgets(QFRawDataRecord *current, QFRawDataRecord *old) { if (old) { this->current=NULL; disconnect(old, SIGNAL(rawDataChanged()), this, SLOT(rawDataChanged())); } QFRDRImagingFCSData* m=qobject_cast<QFRDRImagingFCSData*>(current); if (m) { this->current=current; connect(current, SIGNAL(rawDataChanged()), this, SLOT(rawDataChanged())); } displayData(); }
void Image::setRawData(const QByteArray &rawData) { if (rawData == m_rawData) return; m_rawData = rawData; emit rawDataChanged(); }
void Subtitle::setRawData(const QByteArray &data) { // compare the whole content is not a good idea if (priv->raw_data.size() == data.size()) return; priv->raw_data = data; emit rawDataChanged(); priv->url.clear(); priv->file_name.clear(); }
void QFRDRFCSCrossCorrelationEditor::connectWidgets(QFRawDataRecord* current, QFRawDataRecord* old) { if (old) { writeSettings(); disconnect(old, 0, this, 0); disconnect(cmbFCCSCorrected, SIGNAL(currentIndexChanged(int)), this, SLOT(replotData())); disconnect(spinCCFAmplitudeRangeMin, SIGNAL(valueChanged(double)), this, SLOT(replotData())); disconnect(spinCCFAmplitudeRangeMax, SIGNAL(valueChanged(double)), this, SLOT(replotData())); disconnect(spinCrosstalk, SIGNAL(valueChanged(double)), this, SLOT(replotData())); } QFRDRFCSData* m=qobject_cast<QFRDRFCSData*>(current); correlationMaskTools->setRDR(current); if (m) { readSettings(); cmbRunDisplay->setCurrentIndex(m->getProperty("FCS_RUN_DISPLAY", ProgramOptions::getConfigValue("fcscrossdataeditor/run_display", 0)).toInt()); cmbFCCSCorrected->setCurrentIndex(m->getProperty("fcscrossdataeditor/fccs_mode", ProgramOptions::getConfigValue("fcscrossdataeditor/fccs_mode", 0)).toInt()); spinCrosstalk->setValue(m->getProperty("fcscrossdataeditor/crosstalk", ProgramOptions::getConfigValue("fcscrossdataeditor/crosstalk", 0)).toDouble()); spinCCFAmplitudeRangeMin->setValue(m->getProperty("fcscrossdataeditor/range_min", ProgramOptions::getConfigValue("fcscrossdataeditor/range_min", 10)).toDouble()); spinCCFAmplitudeRangeMax->setValue(m->getProperty("fcscrossdataeditor/range_max", ProgramOptions::getConfigValue("fcscrossdataeditor/range_max", 15)).toDouble()); connect(current, SIGNAL(rawDataChanged()), this, SLOT(rawDataChanged())); runs->setCurrent(current); sliders->disableSliderSignals(); sliders->set_min(0); sliders->set_max(m->getCorrelationN()); sliders->set_userMin(current->getProperty("fcscorreditor_datacut_min", 0).toInt()); sliders->set_userMax(current->getProperty("fcscorreditor_datacut_max", m->getCorrelationN()).toInt()); sliders->enableSliderSignals(); connect(cmbFCCSCorrected, SIGNAL(currentIndexChanged(int)), this, SLOT(replotData())); connect(spinCCFAmplitudeRangeMin, SIGNAL(valueChanged(double)), this, SLOT(replotData())); connect(spinCCFAmplitudeRangeMax, SIGNAL(valueChanged(double)), this, SLOT(replotData())); connect(spinCrosstalk, SIGNAL(valueChanged(double)), this, SLOT(replotData())); } else { // runs.setCurrent(current); } //readSettings(); }