Patch for drFileDialog
Brought to you by:
drpython
1) wx.CallAfter (self.cboExtension.SetMark, 0, 0)
callafter: else (on windows) the field stays
marked.
2) wx.CallAfter (self.lstFiles.SetItemState, 0,
wx.LIST_STATE_SELECTED|wx.LIST_STATE_FOCUSED ,
wx.LIST_STATE_SELECTED|wx.LIST_STATE_FOCUSED)
so at least one listctrl entry is marked gray
after initialisation
3) changed the order of creation of filedialog
elements (because of tab order)
4) in OnFileSelected:
filename = self.lstFiles.GetDirectory()
if not filename.endswith ('/'):
filename += '/'
filename += seltext
there was a bug in the root directory: up
button, until root dir => select one file => in
the file combobox appeard for example
C://boot.ini, and if you click on it, the file will be
opened two times.
Logged In: YES
user_id=796750
I will look into this, but, was there supposed to be an
attached file here? If not, What did you change the
creation of file dialog elements to (#3)?
Logged In: YES
user_id=772872
Sorry, i thought i had attached it.
) The order of creation btnok, btncancel, cboxextension
Logged In: YES
user_id=772872
(forgot click an check to upload and attach a file)
type: with i meant #3
Logged In: YES
user_id=796750
in 3.9.5,
Thanks.
Logged In: YES
user_id=772872
Sorry for reopen.
there are still aproblem in drFileDialog (attached the
patched file)
if you wanted to save a file in root dir, there also
appeard C://test.txt. (hope, there are not too much checks
with endswith)
save in root should be ok now
Logged In: YES
user_id=796750
Thanks, got it. I ended up only using the bit for btnOk,
as the rest ends up being taken care of.
(Plus I ended up using .GetPath to ensure the correct path
is used for the file existence check.)