Wolfmyths / Myth-Mod-Manager

An easy way to swap and manage Payday 2 mods outside the game
https://modworkshop.net/mod/43276
MIT License
9 stars 4 forks source link

[Refactor] Redesigning how threaded classes are handled #32

Closed Wolfmyths closed 1 year ago

Wolfmyths commented 1 year ago

I'm fairly happy with how most of the code in the project is designed, but there is a "middle-man" issue I created with the QThreaded classes, more specifically, fileMover.py

These threaded classes are used in conjunction with QDialog widgets to show the progress of the threaded task to the user, like how fileMover.py uses progressWidget.py to display it's progress in it's task.

The biggest problem is that fileMover.py has different modes (that point to different functions within the class), and to choose that mode you need to input an argument in it's constructor function. And I have it setup so you need to also put the same mode argument in progressWidget.py's constructor so it passes it to fileMover.py.

Another issue that I have, more than one widget that is exactly like progressWidget.py. I would like to create a base class to streamline the process of creating these progress widget dialog boxes.

Recap:

Because of the way I designed these classes, this might sound confusing so don't be afraid to ask any questions if you're interested on working on this.

Wolfmyths commented 1 year ago

Fixed in latest version