Fixed windows support (Windows test couldn't work)

This commit is contained in:
meles5 2015-10-15 17:39:31 +02:00
parent 4fa2f34af4
commit 326757917c

View File

@ -63,6 +63,11 @@ def _guess_autoescape(template_name):
def resource_url(path):
# If Windows is the operating system, replace slashes with backslashes
if os.name == "nt":
path = path.replace("/", os.sep)
path = path[:-1]
image = utils.resource_filename(path)
return QUrl.fromLocalFile(image).toString(QUrl.FullyEncoded)