本文整理汇总了C++中SymbolDialog::selectedFiles方法的典型用法代码示例。如果您正苦于以下问题:C++ SymbolDialog::selectedFiles方法的具体用法?C++ SymbolDialog::selectedFiles怎么用?C++ SymbolDialog::selectedFiles使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SymbolDialog
的用法示例。
在下文中一共展示了SymbolDialog::selectedFiles方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: runScanner
void ScannerPage::runScanner ()
{
QString s;
config.getData(Config::ScannerPath, s);
QString s2("*");
SymbolDialog *dialog = new SymbolDialog(this,
s,
s,
s2,
Q3FileDialog::ExistingFiles);
dialog->setCaption(tr("Select scanners to run"));
int rc = dialog->exec();
if (rc == QDialog::Accepted)
{
QStringList l = dialog->selectedFiles();
int loop;
QDir dir;
for (loop = 0; loop < (int) l.count(); loop++)
{
QFileInfo fi(l[loop]);
Scanner *sdialog = new Scanner(fi.fileName(), chartIndex);
connect(sdialog, SIGNAL(exitScanner()), this, SLOT(refreshList()));
connect(sdialog, SIGNAL(message(QString)), this, SIGNAL(message(QString)));
sdialog->show();
sdialog->scan();
delete sdialog;
}
}
delete dialog;
}
示例2: editRule
void CSV::editRule ()
{
QString s("*");
SymbolDialog *dialog = new SymbolDialog(this,
ruleDir,
ruleDir,
s,
Q3FileDialog::ExistingFiles);
dialog->setCaption(tr("Select Rule To Edit"));
int rc = dialog->exec();
if (rc == QDialog::Rejected)
{
delete dialog;
return;
}
QStringList l = dialog->selectedFiles();
delete dialog;
if (! l.count())
return;
CSVRuleDialog *rdialog = new CSVRuleDialog(this, l[0]);
rc = rdialog->exec();
delete rdialog;
}
示例3: includeRule
void FormulaEdit::includeRule ()
{
QString s("*");
QString s2, s3;
config.getData(Config::IndicatorPath, s2);
config.getData(Config::IndicatorGroup, s3);
s2.append("/" + s3);
SymbolDialog *dialog = new SymbolDialog(this,
s2,
s2,
s,
QFileDialog::ExistingFiles);
dialog->setCaption(tr("Select rule to include"));
int rc = dialog->exec();
if (rc != QDialog::Accepted)
{
delete dialog;
return;
}
QStringList selection = dialog->selectedFiles();
delete dialog;
if (! selection.count())
return;
QFileInfo fi(selection[0]);
s = "INCLUDECUS(" + fi.fileName() + ")\n";
formula->insert(s);
}
示例4: deleteRule
void CSV::deleteRule ()
{
QString s("*");
SymbolDialog *dialog = new SymbolDialog(this,
ruleDir,
ruleDir,
s,
Q3FileDialog::ExistingFiles);
dialog->setCaption(tr("Select Rules To Delete"));
int rc = dialog->exec();
if (rc == QDialog::Accepted)
{
rc = QMessageBox::warning(this,
tr("Qtstalker: Warning"),
tr("Are you sure to delete selected rules?"),
QMessageBox::Yes,
QMessageBox::No,
QMessageBox::NoButton);
if (rc == QMessageBox::No)
{
delete dialog;
return;
}
QStringList l = dialog->selectedFiles();
delete dialog;
if (! l.count())
return;
int loop;
QDir dir;
for (loop = 0; loop < (int) l.count(); loop++)
dir.remove(l[loop]);
updateRules();
}
else
delete dialog;
}
示例5: deleteScanner
void ScannerPage::deleteScanner()
{
QString s;
config.getData(Config::ScannerPath, s);
QString s2("*");
SymbolDialog *dialog = new SymbolDialog(this,
s,
s,
s2,
Q3FileDialog::ExistingFiles);
dialog->setCaption(tr("Select Scanners To Delete"));
int rc = dialog->exec();
if (rc == QDialog::Accepted)
{
rc = QMessageBox::warning(this,
tr("Qtstalker: Warning"),
tr("Are you sure to delete selected scanners?"),
QMessageBox::Yes,
QMessageBox::No,
QMessageBox::NoButton);
if (rc == QMessageBox::No)
{
delete dialog;
return;
}
QStringList l = dialog->selectedFiles();
int loop;
QDir dir;
for (loop = 0; loop < (int) l.count(); loop++)
dir.remove(l[loop]);
refreshList();
scannerSelected(QString());
}
delete dialog;
}
示例6: getSymbols
void Scanner::getSymbols ()
{
QString s;
if (! basePath->currentText().compare(tr("Chart")))
config.getData(Config::DataPath, s);
else
config.getData(Config::GroupPath, s);
QString s2("*");
SymbolDialog *dialog = new SymbolDialog(this,
s,
s,
s2,
QFileDialog::ExistingFiles);
dialog->setCaption(tr("Select symbols to scan"));
int rc = dialog->exec();
if (rc == QDialog::Accepted)
fileList = dialog->selectedFiles();
fileButton->setText(QString::number(fileList.count()) + " Symbols");
delete dialog;
}