Commit graph

15 commits

Author SHA1 Message Date
Dominik Riebeling
8c55ce62b9 rbutil: Move bootloader file check to base class.
Avoid constructing the bootloader file path in the caller. Pass filename
list and mountpoint separately so it can directly fall back to the
mountpoint.

Change some functions to use references instead of creating temporary
objects.

Change-Id: I09c9d755553a32de3d02a42a8ce1fcb94f831b2a
2022-04-17 23:21:19 +02:00
Dominik Riebeling
04e22d8719 rbutil: Replace use of QRegExp with QRegularExpression.
Change-Id: Ie89057a9857bc66612cb15fef81d3ca6c3e71b4c
2022-03-20 20:12:20 +01:00
Dominik Riebeling
7a2fdf3fd6 rbutil: Handle SSL certificate errors on first request.
Qt uses the systems certificate store. On old(er) systems the root
certificate might not be present, so checking the certificate from the
rockbox.org server might fail.

On startup we try to download the build-info file. If this fails with a
certificate error allow the user to temporarily accept the rockbox.org
certificate for all successive requests.

Change-Id: I459e12d53286aaedea4db659d90a5e057c56801f
2022-03-19 16:57:41 +01:00
Dominik Riebeling
a0459de4d5 rbutil: HttpGet: Return NetworkError in done signal.
Return the status value instead of simply a bool.

Change-Id: I2bffaac0087418656e80c74dc352011a4ea32ab1
2022-03-19 09:19:11 +01:00
Dominik Riebeling
ce70e34476 rbutil: Fix ipodpatcher bootloader uninstall.
Fix mountpoint not passed and sectorbuf not initialized properly.

Change-Id: Ifa9d9e159767b20a51841ee422be59feca95c757
2022-03-12 22:46:07 +01:00
Dominik Riebeling
1ff11b627b rbutil: Fix bootloader uninstall availability.
The logic for disabling the uninstall button was wrong.

Change-Id: Icec4b70a7323bb6ae275e7b88fff414450ba4566
2022-03-12 22:46:07 +01:00
Dominik Riebeling
8d462a1edd rbutil: Rework Logo display.
Replace QLabel with QSvgWidget so the widget draws the svg directly
instead of first creating a pixmap from it.

This also avoids an issue when building with mxe which causes the image
to not show due to a missing svg plugin (which doesn't happen for svg
icons.)

Change-Id: Ic4e265f0567984d1ffe7a3e1cc641df27755e90b
2022-02-28 20:37:32 +01:00
Aidan MacDonald
cbb57fe714 rbutil: allow checking bootloader installer capabilities
Instead of checking for certain hardcoded strings, fetch
the actual capability bitmask by instantiating an installer
and querying it.

Change-Id: I7883d9c1e90da37ee7c0189732ac626685adbfa1
2022-01-02 15:50:17 -05:00
Dominik Riebeling
f53f1fbafa rbutil: Fix some more issues found by clazy.
Change-Id: I0a1a849ecea4b4666b08ccb050eb17918e90a258
2021-12-28 17:57:04 +01:00
Dominik Riebeling
1ad4faa334 rbutil: Modernize connect() calls.
Auto fixed by clazy.

Change-Id: Iea16d892fd81c151f0081f7476acc5eda62afc25
2021-12-26 19:50:19 +01:00
Dominik Riebeling
35bc4590ae rbutil: Remove ProgressLogger interface class.
Since we're using signals to connect to the Logger we don't need an
interface class, and the only thing still used was the log level enum.
Put those values in a dedicated header instead.

Change-Id: Ic3aee14ba13b81e283b477d11b1c15a5c26ffeab
2021-12-26 11:05:25 +01:00
Dominik Riebeling
01e245417e rbutil: Fix various issues found by clazy.
Change-Id: I91ca2baed34f0f3b561602f95f66bbd4e17e74ab
2021-12-25 19:59:57 +01:00
Dominik Riebeling
6ff75b475c rbutil: Modernize connect() calls.
Auto fixed by clazy.

Change-Id: Ib7cce8c0a85f8f915263980bf5d2508a4b19bbe3
2021-12-25 17:47:14 +01:00
Dominik Riebeling
9e28474e47 rbutil: Replace QRegExp with QRegularExpression.
The former is not part of Qt6 anymore, while the latter has been
introduced with Qt5. We don't support Qt4 anymore, so move to
QRegularExpression.

Change-Id: Icc15ef422790f3740660c5581294aa0536f46b1f
2021-12-24 18:05:53 +01:00
Dominik Riebeling
c876d3bbef rbutil: Merge rbutil with utils folder.
rbutil uses several components from the utils folder, and can be
considered part of utils too. Having it in a separate folder is an
arbitrary split that doesn't help anymore these days, so merge them.

This also allows other utils to easily use libtools.make without the
need to navigate to a different folder.

Change-Id: I3fc2f4de19e3e776553efb5dea5f779dfec0dc21
2021-12-24 18:05:53 +01:00
Renamed from rbutil/rbutilqt/rbutilqt.cpp (Browse further)