Commit 6828f33f authored by Boudewijn Rempt's avatar Boudewijn Rempt

Do not allow .kra files as file layers

Nesting .kra files is dangerous, since a .kra file can contain
file layers itself, which is not supported.

BUG:386515,394211,325686
parent 12a72b34
......@@ -43,7 +43,10 @@ KisDlgFileLayer::KisDlgFileLayer(const QString &basePath, const QString & name,
setDefaultButton(Ok);
QWidget * page = new QWidget(this);
dlgWidget.setupUi(page);
dlgWidget.wdgUrlRequester->setMimeTypeFilters(KisImportExportManager::mimeFilter(KisImportExportManager::Import));
QStringList mimes = KisImportExportManager::mimeFilter(KisImportExportManager::Import);
// Nesting .kra files is not supported, so do not offer that option. See https://bugs.kde.org/show_bug.cgi?id=386515
mimes.removeAll("application/x-krita");
dlgWidget.wdgUrlRequester->setMimeTypeFilters(mimes);
setMainWidget(page);
//dlgWidget.wdgUrlRequester->setBasePath(m_basePath);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment