Skip to content

Commit

Permalink
Merge pull request #795 from Xnot/win-filechooser-initialdir-fix
Browse files Browse the repository at this point in the history
Normalize path when passing args to windows filechooser
  • Loading branch information
akshayaurora authored Jan 8, 2025
2 parents 181a94b + ceafe1b commit a4e231d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion plyer/platforms/win/filechooser.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
import win32gui
import win32con
import pywintypes
from os.path import dirname, splitext, join, isdir
from os.path import dirname, splitext, join, isdir, normpath


class Win32FileChooser:
Expand Down Expand Up @@ -66,6 +66,7 @@ def run(self):
args = {}

if self.path:
self.path = normpath(self.path)
if isdir(self.path):
args["InitialDir"] = self.path
else:
Expand Down

0 comments on commit a4e231d

Please sign in to comment.