The accept attribute of the <input /> tag does not work
Unsolved
QtWebEngine
-
Setting <input type="file" id="filepicker" accept=".cpp, .html, .h, .png, .qdoc, .qml" />, then click the input button, the file dialog pops up, but the file type filter does not work.
https://doc.qt.io/qt-5/qtwebengine-webengine-customdialogs-index-html.html
-
@whatever_name
Qt widgets or QML?Anyway the docs say:
acceptedMimeTypes is ignored by the default implementation, but might be used by overrides.
For QML follow the same principle.
-
Qt widgets
Thanks @raven-worx
Overrides the chooseFiles() is a good solution for me.