MCPcopy Create free account
hub / github.com/Kitware/ParaView / fileIsOpened

Method fileIsOpened

Qt/Python/pqPythonTabWidget.cxx:465–478  ·  view source on GitHub ↗

-----------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

463
464//-----------------------------------------------------------------------------
465int pqPythonTabWidget::fileIsOpened(const QString& fileName) const
466{
467 const QFileInfo fileInfo(fileName);
468 for (int i = 0; i < this->count() - 1; ++i)
469 {
470 pqPythonTextArea* widget = this->getWidget<pqPythonTextArea>(i);
471 if (widget && QFileInfo(widget->getFilename()) == fileInfo)
472 {
473 return i;
474 }
475 }
476
477 return -1;
478}

Callers 1

addNewTextAreaMethod · 0.95

Calls 2

QFileInfoClass · 0.85
countMethod · 0.45

Tested by

no test coverage detected