refactor(RD): clear up sorting methods
This refactors the sorting methods to join every bit of it into a single list, easing maintanance. It also removes the weird index contraint on the list of methods by adding an index field to the DS that holds the method. Lastly, it puts the available methods on their respective API, so other resources on the same API can re-use them later on. Signed-off-by: flow <flowlnlnln@gmail.com>
This commit is contained in:
parent
c8eca4fb85
commit
36571c5e22
17 changed files with 93 additions and 61 deletions
|
@ -52,14 +52,14 @@ class ResourcePage : public QWidget, public BasePage {
|
|||
|
||||
[[nodiscard]] bool setCurrentPack(ModPlatform::IndexedPack);
|
||||
[[nodiscard]] auto getCurrentPack() const -> ModPlatform::IndexedPack;
|
||||
|
||||
[[nodiscard]] auto getDialog() const -> const ResourceDownloadDialog* { return m_parent_dialog; }
|
||||
|
||||
[[nodiscard]] auto getModel() const -> ResourceModel* { return m_model; }
|
||||
|
||||
protected:
|
||||
ResourcePage(ResourceDownloadDialog* parent, BaseInstance&);
|
||||
|
||||
void addSortings();
|
||||
|
||||
public slots:
|
||||
virtual void updateUi();
|
||||
virtual void updateSelectionButton();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue