if trying to open a unicode folder, make sure we encode to filesystem

This commit is contained in:
Damien Elmes 2011-01-22 04:27:04 +09:00
parent 39d3ffd6d3
commit 4908c3f268

View file

@ -2759,6 +2759,8 @@ to work with this version of Anki."""))
if path is None:
path = self.pluginsFolder()
if sys.platform == "win32":
if isinstance(path, unicode):
path = path.encode(sys.getfilesystemencoding())
anki.utils.call(["explorer", path], wait=False)
else:
QDesktopServices.openUrl(QUrl("file://" + path))