I would like to have
- one background thread which will copy the files through the
SHFileOperationfunction, always only oneSHFileOperationat the time (but I want it to be in the thread) - I need the UI output, so I need to use the
FOF_SIMPLEPROGRESSflag and pass something to theWndmember
I have two questions
- is it safe to call the
SHFileOperationwithFOF_SIMPLEPROGRESSflag (for user interaction) from the thread other than main ? - if yes, what handle should I pass into the
Wndmember ? I've tried the handle of the main form, but when e.g. the overwrite confirmation dialog pops up and you confirm it, the main form is sent to the background, what is really strange
Note:
I have a queue for these operations, so only one SHFileOperation is performed at the time (after it's finished, the thread continues to the other action, what might be the next SHFileOperation)
Thanks a lot