Commit Graph

132 Commits

Author SHA1 Message Date
Sefa Eyeoglu
f371ec210c
Merge pull request #1052 from flowln/resource_model 2022-08-28 16:52:53 +02:00
Sefa Eyeoglu
afcd669d2f
Merge pull request #965 from flowln/fat_files_in_memory
Refactor a bit EnsureMetadataTask and calculate hashes in a incremental manner
2022-08-28 11:03:12 +02:00
flow
e7cf9932a9
refactor: simplify Mod structure
No need to keep track of pointers left and right. A single one already
gives enough headaches!

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-08-20 10:48:51 -03:00
flow
97a74d5c1f
refactor: adapt rest of the codebase to the new resource model
In order to access the ModFolderModel from the ModFolderPage, i created
a new m_model for the correct type, shadowing the m_model of type
ResourceFolderModel. This creates two shared_ptr references to the same object,
but since they will have the same lifetime, it doesn't generate a memory
leak.

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-08-20 10:47:58 -03:00
flow
ec62d8e973
refactor: move general code from mod model to its own model
This aims to continue decoupling other types of resources (e.g. resource
packs, shader packs, etc) from mods, so that we don't have to
continuously watch our backs for changes to one of them affecting the
others.

To do so, this creates a more general list model for resources, based on
the mods one, that allows you to extend it with functionality for other
resources.

I had to do some template and preprocessor stuff to get around the
QObject limitation of not allowing templated classes, so that's sadge :c

On the other hand, I tried cleaning up most general-purpose code in the
mod model, and added some documentation, because it looks nice :D

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-08-20 10:45:01 -03:00
flow
3225f514f6
refactor: move general info from Mod to Resource
This allows us to create other resources that are not Mods, but can
still share a significant portion of code.

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-08-20 10:41:59 -03:00
Sefa Eyeoglu
70a8f6743a
Merge pull request #919 from kumquat-ir/download-all-blocked 2022-08-20 12:50:01 +02:00
timoreo
c375e7b4df
Merge pull request #897 from jamierocks/atl-updating-initial 2022-08-11 08:50:05 +02:00
kumquat-ir
579582740e Merge remote-tracking branch 'origin/develop' into download-all-blocked
Signed-off-by: kumquat-ir <66188216+kumquat-ir@users.noreply.github.com>
2022-07-31 14:54:50 -04:00
LennyMcLennington
94a63e3859
Merge pull request #941 from Scrumplex/bump-cxx-standard
Bump to C++17
2022-07-30 17:10:59 +01:00
flow
631a93bcd8
refactor: add a HashUtils place for hashing stuff
Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-24 17:46:54 -03:00
Sefa Eyeoglu
c65f5f7728
Merge pull request #877 from Scrumplex/refactor-offline-accounts 2022-07-23 13:54:36 +02:00
Sefa Eyeoglu
2e94562f79
fix: treat accounts as offline, if auth servers are down
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2022-07-23 12:38:01 +02:00
Sefa Eyeoglu
c666c3e251
refactor!: bump to C++17 and C17
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2022-07-20 14:22:10 +02:00
kumquat-ir
20b1723e78 merge origin/develop
Signed-off-by: kumquat-ir <66188216+kumquat-ir@users.noreply.github.com>
2022-07-18 14:05:23 -04:00
flow
6e2869834f
feat: add mod update dialog
This subclasses the Review mods dialog to make a "Update review" one.
Also, all the necessary components built until now are put together in a
coherent unity that checks and generates metadata on-the-fly and checks for
mod updates, while giving and receiving feedback to the user.

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-17 11:33:42 -03:00
flow
b8b71c7dd2
feat: add mod update check tasks
Those tasks take a list of mods and check on the mod providers for
updates. They assume that the mods have metadata already.

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-17 11:33:42 -03:00
flow
844b245776
feat: add EnsureMetadataTask
This task is responsible for checking if the mod has metadata for a
specific provider, and create it if it doesn't.

In the context of the mod updater, this is not the best architecture,
since we do a single task for each mod. However, this way of structuring
it allows us to use it later on in more diverse scenarios.

This way we decouple this task from the mod updater, trading off some performance
(though that will be mitigated when we have a way of running arbitrary tasks
concurrently).

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-17 11:33:42 -03:00
flow
4bcf8e6975
feat: add api call to flame
Call added:
- Get Fingerprints Matches
- Get Mod File Changelog

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-17 11:33:42 -03:00
flow
0e52112016
feat: add some api calls to modrinth
Calls added:
- Get version from hash
- Get versions from hashes
- Latest version of a project from a hash, loader(s), and game version(s)
- Latest versions of multiple project from hashes, loader(s), and game version(s)

Some of those are not used yet, but may be of use later on, so we have
it if we need it :)

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-17 11:33:41 -03:00
flow
32a9545360
libs: add murmur2 library
Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-17 11:33:41 -03:00
flow
9a44c92211
feat: add MultipleOptionsTask
This is a variation of a Sequential Task, in which a subtask failing
will prompt the next one to execute, and a subtask being successful will
stop the task.

This way, this can be used for easily managing fallbacks with tasks. :D

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-17 11:33:41 -03:00
flow
dd6aabf9ab
feat: add ChooseProviderDialog
Allows you to prompt the user for choosing a (mod) provider. This should
be fairly independent of the mod updater logic, so it can be used for
other ends later down the road :^)

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-17 11:33:41 -03:00
kumquat-ir
6a1d611fd1 Restore ScrollMessageBox
Signed-off-by: kumquat-ir <66188216+kumquat-ir@users.noreply.github.com>
2022-07-17 02:40:27 -04:00
kumquat-ir
33e34ebb83 Add "Open All" button to blocked mods dialog
Signed-off-by: kumquat-ir <66188216+kumquat-ir@users.noreply.github.com>
2022-07-16 19:14:54 -04:00
Sefa Eyeoglu
b3b76d5d56
Merge branch 'develop' into feature/sparkle-mac
# Conflicts:
#	.github/workflows/build.yml
2022-07-10 19:38:30 +02:00
Jamie Mansfield
bf560f4594
ATLauncher: Move the UI support implementation into it's own class
This will allow it to be used in multiple locations.
2022-07-10 11:27:42 +01:00
Sefa Eyeoglu
f464b347b2
fix: install TLS plugins for release builds
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2022-07-10 12:19:15 +02:00
Sefa Eyeoglu
3e4d1c04de
fix: include TLS plugins in bundle
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2022-07-10 12:19:15 +02:00
Sefa Eyeoglu
e58158c3cd
feat: add Qt 6 support to CMake
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2022-07-10 12:19:14 +02:00
Sefa Eyeoglu
ff2cd50bfa
refactor: replace QRegExp with QRegularExpression
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2022-07-10 12:17:52 +02:00
Sefa Eyeoglu
984692dc62
refactor: fix deprecation up to Qt 5.15
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2022-07-10 12:17:52 +02:00
Sefa Eyeoglu
ffa756ccee
fix: remove tests for updater
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2022-07-06 18:13:51 +02:00
Sefa Eyeoglu
e210a4b244
Revert "fix: remove updater if it is not used"
This reverts commit 2ff0aa09e3.

Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2022-07-06 18:13:51 +02:00
Sefa Eyeoglu
04b865adae
Merge pull request #707 from Jan200101/PR/gamemode
Add Performance related settings
2022-07-06 17:11:43 +02:00
Jan200101
cad581388f
Add Performance related settings
Integrates support for Feral Gamemode, discrete GPU support for Mesa and the proprietary Nvidia driver and MangoHud support

Signed-off-by: Jan200101 <sentrycraft123@gmail.com>
2022-07-06 09:34:14 +02:00
flow
fb75c23f4e
Merge pull request #784 from Scrumplex/refactor-cmake
Refactor tests
2022-07-02 17:50:08 -03:00
timoreo
fe2e1d931f
Merge pull request #786 from flowln/concurrent_tasks_slimmed 2022-07-01 20:09:18 +02:00
timoreo
2e17e78052
Merge pull request #845 from flowln/news_in_launcher 2022-07-01 20:04:06 +02:00
flow
8e80b4bfc1
feat: add ConcurrentTask
This tasks (or rather, meta-task) has the ability to run several other
sub tasks concurrently.

Signed-off-by: flow <flowlnlnln@gmail.com>
2022-07-01 08:34:10 -03:00
flow
455e4de6f3
feat: add news reader dialog
Makes it easier to read about new blog posts! Yay :D
2022-06-25 20:15:16 -03:00
Sefa Eyeoglu
effe46db86
refactor: move away from UnitTest.cmake 2022-06-14 14:44:49 +02:00
flow
d394235ee0
refactor: Create a more clear hierarchy for some instance pages
Previously, the Shaders, Texture packs and Resource packs tabs had as
parent the ModFolderPage, making it so that making changes only to the
Mods page would require checking the id of the page for the correct one.
This was hackish and error-prone.

Now, those pages all inherit from a single class, ExternalResourcesPage,
that handles the basic behaviour of all of them, while allowing for
individual modification in code.

This is still not a clear separation, since internally, all those
resources are derived from Mods, so for now there's still some awkward
common code :/
2022-06-14 07:04:31 -03:00
Sefa Eyeoglu
2ff0aa09e3
fix: remove updater if it is not used 2022-06-12 13:39:47 +02:00
Sefa Eyeoglu
1ab00ca8b2
Merge pull request #426 from flowln/mod_perma
Add on-disk mod metadata information
2022-06-04 13:23:38 +02:00
Sefa Eyeoglu
b07c5982e1
fix: set version for Windows binaries 2022-05-29 13:09:13 +02:00
timoreo22
699ad316f0
Rework curseforge download (#611)
* Use the bulk endpoint on mod resolution for faster download
* Search on modrinth for api blocked mods
* Display a dialog for manually downloading blocked mods
2022-05-28 21:53:12 +02:00
flow
a99858c64d
refactor: move code out of ModIndex.h
Now it's in ModIndex.cpp
2022-05-23 14:43:07 -03:00
flow
d7f6b36990
test+fix: add basic tests and fix issues with it 2022-05-23 14:42:28 -03:00
flow
fab4a7a602
refactor: abstract metadata handling and clarify names 2022-05-23 14:42:28 -03:00