| 302 | } |
| 303 | |
| 304 | QStringList OpenProjectDialog::projectManagerForFile(const QString& file) const |
| 305 | { |
| 306 | QStringList ret; |
| 307 | for (auto it = m_projectFilters.begin(), end = m_projectFilters.end(); it != end; ++it) { |
| 308 | const QString& manager = it.key(); |
| 309 | for (const QString& filterexp : it.value()) { |
| 310 | QRegExp exp( filterexp, Qt::CaseSensitive, QRegExp::Wildcard ); |
| 311 | if ( exp.exactMatch(file) ) { |
| 312 | ret.append(manager); |
| 313 | } |
| 314 | } |
| 315 | } |
| 316 | if ( file.endsWith(ShellExtension::getInstance()->projectFileExtension()) ) { |
| 317 | ret.append(QStringLiteral("<built-in>")); |
| 318 | } |
| 319 | return ret; |
| 320 | } |
| 321 | |
| 322 | void OpenProjectDialog::openPageAccepted() |
| 323 | { |