本文整理汇总了C++中QObjectScopedPointer::result方法的典型用法代码示例。如果您正苦于以下问题:C++ QObjectScopedPointer::result方法的具体用法?C++ QObjectScopedPointer::result怎么用?C++ QObjectScopedPointer::result使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类QObjectScopedPointer
的用法示例。
在下文中一共展示了QObjectScopedPointer::result方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: sl_showDnaAssemblyDialog
void DnaAssemblySupport::sl_showDnaAssemblyDialog()
{
DnaAssemblyAlgRegistry* registry = AppContext::getDnaAssemblyAlgRegistry();
if (registry->getRegisteredAlgorithmIds().isEmpty()) {
QMessageBox::information(QApplication::activeWindow(), tr("DNA Assembly"),
tr("There are no algorithms for DNA assembly available.\nPlease, check your plugin list.") );
return;
}
QObjectScopedPointer<DnaAssemblyDialog> dlg = new DnaAssemblyDialog(QApplication::activeWindow());
dlg->exec();
CHECK(!dlg.isNull(), );
if (QDialog::Accepted == dlg->result()) {
DnaAssemblyToRefTaskSettings s;
s.samOutput = dlg->isSamOutput();
s.refSeqUrl = dlg->getRefSeqUrl();
s.algName = dlg->getAlgorithmName();
s.resultFileName = dlg->getResultFileName();
s.setCustomSettings(dlg->getCustomSettings());
s.shortReadSets = dlg->getShortReadSets();
s.pairedReads = dlg->isPaired();
s.openView = true;
s.prebuiltIndex = dlg->isPrebuiltIndex();
Task* assemblyTask = new DnaAssemblyTaskWithConversions(s, true);
AppContext::getTaskScheduler()->registerTopLevelTask(assemblyTask);
}
}
示例2: sl_browse
void PrimerGroupBox::sl_browse() {
QObjectScopedPointer<PrimerLibrarySelector> dlg = new PrimerLibrarySelector(AppContext::getMainWindow()->getQMainWindow());
dlg->exec();
CHECK(!dlg.isNull(), );
CHECK(QDialog::Accepted == dlg->result(), );
Primer result = dlg->getResult();
primerEdit->setInvalidatedText(result.sequence);
}
示例3: sl_showConvertToSamDialog
void DnaAssemblySupport::sl_showConvertToSamDialog() {
QObjectScopedPointer<ConvertAssemblyToSamDialog> dlg = new ConvertAssemblyToSamDialog(QApplication::activeWindow());
dlg->exec();
CHECK(!dlg.isNull(), );
if (QDialog::Accepted == dlg->result()) {
Task *convertTask = new ConvertAssemblyToSamTask(dlg->getDbFileUrl(), dlg->getSamFileUrl());
AppContext::getTaskScheduler()->registerTopLevelTask(convertTask);
}
}
示例4: sl_invertedColorButton
void DotPlotDialog::sl_invertedColorButton() {
QObjectScopedPointer<QColorDialog> d = new QColorDialog(invertedColor, this);
d->exec();
CHECK(!d.isNull(), );
if (QDialog::Accepted == d->result()) {
invertedColor = d->selectedColor();
invertedCheckBox->setChecked(true);
}
updateColors();
}
示例5: sl_colorActionTriggered
void MSAOverviewContextMenu::sl_colorActionTriggered() {
QObjectScopedPointer<QColorDialog> colorDialog = new QColorDialog(graphOverview->getCurrentColor(), this);
#ifdef Q_OS_MAC
if (qgetenv("UGENE_GUI_TEST").toInt() == 1 && qgetenv("UGENE_USE_NATIVE_DIALOGS").toInt() == 0) {
colorDialog->setOption(QColorDialog::DontUseNativeDialog);
}
#endif
colorDialog->exec();
CHECK(!colorDialog.isNull(), );
if (QDialog::Accepted == colorDialog->result()) {
emit si_colorSelected(colorDialog->selectedColor());
}
}
示例6: checkMemory
bool CreatePhyTreeDialogController::checkMemory() {
SAFE_POINT(NULL != settingsWidget, "Settings widget is NULL", false);
QString msg;
const bool memCheckOk = settingsWidget->checkMemoryEstimation(msg, msa, settings);
if (!memCheckOk) {
QObjectScopedPointer<QMessageBox> mb = new QMessageBox(QMessageBox::Warning, tr("Warning"), msg, QMessageBox::Ok|QMessageBox::Cancel, this);
mb->exec();
CHECK(!mb.isNull(), false);
return (mb->result() == QMessageBox::Ok);
}
return true;
}
示例7: sl_showGenomeAssemblyDialog
void DnaAssemblySupport::sl_showGenomeAssemblyDialog() {
GenomeAssemblyAlgRegistry* registry = AppContext::getGenomeAssemblyAlgRegistry();
if (registry->getRegisteredAlgorithmIds().isEmpty()) {
QMessageBox::information(QApplication::activeWindow(), tr("Genome Assembly"),
tr("There are no algorithms for genome assembly available.\nPlease, check external tools in the settings.") );
return;
}
QObjectScopedPointer<GenomeAssemblyDialog> dlg = new GenomeAssemblyDialog(QApplication::activeWindow());
dlg->exec();
CHECK(!dlg.isNull(), );
if (QDialog::Accepted == dlg->result()) {
GenomeAssemblyTaskSettings s;
s.algName = dlg->getAlgorithmName();
s.outDir = dlg->getOutDir();
s.setCustomSettings(dlg->getCustomSettings());
s.reads = dlg->getReads();
s.openView = true;
Task* assemblyTask = new GenomeAssemblyMultiTask(s);
AppContext::getTaskScheduler()->registerTopLevelTask(assemblyTask);
}
}
示例8: sl_OK
void SendSelectionDialog::sl_OK() {
QString error = ca_c->validate();
if (!error.isEmpty()) {
QMessageBox::critical(NULL, tr("Error"), error);
return;
}
retries = retrySpinBox->value();
db = dataBase->currentText();
if(db!="cdd") {
requestParameters = "CMD=Put";
addParametr(requestParameters,ReqParams::program,db);
double eValue = evalueSpinBox->value();
if(shortSequenceCheckBox->isChecked())
eValue = 1000;
addParametr(requestParameters,ReqParams::expect,eValue);
if(false == entrezQueryEdit->text().isEmpty())
addParametr(requestParameters, ReqParams::entrezQuery, entrezQueryEdit->text());
int maxHit = quantitySpinBox->value();
addParametr(requestParameters,ReqParams::hits,maxHit);
if(megablastCheckBox->isChecked()) {
addParametr(requestParameters,ReqParams::megablast,"true");
}
addParametr(requestParameters,ReqParams::database,dbComboBox->currentText().split(" ").last());
QString filter="";
if(lowComplexityFilterCheckBox->isChecked()&&!shortSequenceCheckBox->isChecked()) {
filter.append("L");
}
if(repeatsCheckBox->isChecked()) {
filter.append("R");
}
if(lookupMaskCheckBox->isChecked()) {
filter.append("m");
}
if(!filter.isEmpty()) {
addParametr(requestParameters,ReqParams::filter,filter);
}
addParametr(requestParameters,ReqParams::gapCost,costsComboBox->currentText());
if(db == "blastn"){
addParametr(requestParameters,ReqParams::matchScore,scoresComboBox->currentText().split(" ").first());
addParametr(requestParameters,ReqParams::mismatchScore,scoresComboBox->currentText().split(" ").last());
}
if(shortSequenceCheckBox->isChecked()) {
QString wordSize = wordSizeComboBox->currentText().toInt()>7 ? "7" : wordSizeComboBox->currentText();
addParametr(requestParameters,ReqParams::wordSize, wordSize);
}
else {
addParametr(requestParameters,ReqParams::wordSize,wordSizeComboBox->currentText());
}
if(lowerCaseCheckBox->isChecked()) {
addParametr(requestParameters,ReqParams::lowCaseMask,"yes");
}
if(db=="blastp") {
if(!isAminoSeq) {
translateToAmino = true;
}
addParametr(requestParameters,ReqParams::matrix,matrixComboBox->currentText());
addParametr(requestParameters,ReqParams::service,serviceComboBox->currentText());
if(serviceComboBox->currentText()=="phi") {
addParametr(requestParameters,ReqParams::phiPattern,phiPatternEdit->text());
}
}
}
else { //CDD
requestParameters = "CMD=Put";
db = "blastp";
addParametr(requestParameters,ReqParams::program, db);
addParametr(requestParameters,ReqParams::expect, evalueSpinBox->value());
addParametr(requestParameters,ReqParams::hits,quantitySpinBox->value());
QString dbName = dbComboBox->currentText().split(" ").last();
addParametr(requestParameters,ReqParams::database, dbName.toLower());
addParametr(requestParameters,ReqParams::service, "rpsblast");
}
if(translateToAmino) {
QObjectScopedPointer<QMessageBox> msg = new QMessageBox(this);
msg->setText(tr("You chose to search nucleotide sequence in protein database. This sequence will be converted into 6 sequences(3 translations for both strands)."
"Therefore this search may take some time. Continue?"));
msg->setWindowTitle(windowTitle());
msg->setStandardButtons(QMessageBox::Yes | QMessageBox::Cancel);
msg->setDefaultButton(QMessageBox::Yes);
msg->exec();
CHECK(!msg.isNull(), );
if (msg->result() == QMessageBox::Cancel) {
return;
//.........这里部分代码省略.........