Posts

Showing posts from December, 2014

Couple of quick 'diff' examples

For files list only: diff -qr Source1 Source2  > ~/diff_files Actual contents diff; Can be opened with Kompare: diff -Naur Source1 Source2 > ~/diff_contents

Adventures in Threading

Link to source So after stumbling for a while I managed to crack Qt's moveToThread(). Source at above link. Its has working code for big file copy in thread. We have only left one small problem, and that is if the function we are calling on thread start has any arguments to pass, then we won't be able to directly connect it to thread's started() signal. So in this case we should subclass thread and pass the arguments to the custom thread object and then inside it emit an appropriate signal to call the main class's function. It seems like such a complex way to do such a simple task like "run this function on a separate thread!" :D