mirror of
https://github.com/YACReader/yacreader
synced 2025-06-04 01:28:55 -04:00
fixed validation regexp for folders' names
This commit is contained in:
parent
c2f4ab403c
commit
b5f164251d
@ -1517,7 +1517,8 @@ void LibraryWindow::addFolderToCurrentIndex()
|
|||||||
tr("Folder name:"), QLineEdit::Normal,
|
tr("Folder name:"), QLineEdit::Normal,
|
||||||
"", &ok);
|
"", &ok);
|
||||||
|
|
||||||
QRegExp invalidChars("\/\\\:\*\?\"\<\>\|");//TODO this regexp is not properly written
|
//chars not supported in a folder's name: / \ : * ? " < > |
|
||||||
|
QRegExp invalidChars("\\/\\:\\*\\?\\\"\\<\\>\\|\\\\");//TODO this regexp is not properly written
|
||||||
bool isValid = !newFolderName.contains(invalidChars);
|
bool isValid = !newFolderName.contains(invalidChars);
|
||||||
|
|
||||||
if (ok && !newFolderName.isEmpty() && isValid)
|
if (ok && !newFolderName.isEmpty() && isValid)
|
||||||
|
@ -205,7 +205,6 @@ void YACReaderNavigationController::selectedIndexFromHistory(const YACReaderLibr
|
|||||||
libraryWindow->clearSearchFilter();
|
libraryWindow->clearSearchFilter();
|
||||||
}
|
}
|
||||||
|
|
||||||
//TODO more info about mi is needed (folder, lists...)
|
|
||||||
loadIndexFromHistory(sourceContainer);
|
loadIndexFromHistory(sourceContainer);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user