Correct slashes for file drops on Windows
This commit is contained in:
parent
cfeb6dbeee
commit
4ede1f618c
@ -229,7 +229,7 @@ class ConfigDialog(QtGui.QDialog):
|
||||
data = event.mimeData()
|
||||
urls = data.urls()
|
||||
if urls and urls[0].scheme() == 'file':
|
||||
dropfilepath = unicode(event.mimeData().urls()[0].toLocalFile())
|
||||
dropfilepath = os.path.abspath(unicode(event.mimeData().urls()[0].toLocalFile()))
|
||||
if dropfilepath[-4:].lower() == ".exe":
|
||||
self.executablepathCombobox.setEditText(dropfilepath)
|
||||
else:
|
||||
|
||||
@ -432,7 +432,7 @@ class MainWindow(QtGui.QMainWindow):
|
||||
data = event.mimeData()
|
||||
urls = data.urls()
|
||||
if urls and urls[0].scheme() == 'file':
|
||||
dropfilepath = unicode(event.mimeData().urls()[0].toLocalFile())
|
||||
dropfilepath = os.path.abspath(unicode(event.mimeData().urls()[0].toLocalFile()))
|
||||
if rewindFile == False:
|
||||
self._syncplayClient._player.openFile(dropfilepath)
|
||||
else:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user