plyer
plyer copied to clipboard
Switch to MaxFile arg to increase Windows filechooser buffer
In d87c446, a workaround to long filenames crashing the Windows filechooser was added by appending \x00
to the File
arg. This works because pywin32 takes the max of MaxFile
and the length of File
as the buffer size. However it would be more appropriate to directly use the MaxFile
arg, as that's its intended purpose. Additionally, this will allow users to pass the buffer_size
parameter if they are using really long file names and wish to override the buffer size.