build-system: move profile specific icons into separate QRC

This way they are available in both mobile and desktop version.
Without this, the icons weren't shown on iOS and Android.

Fixes #3214

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2022-03-12 16:18:26 -08:00
parent dddec0a5b6
commit 69cb33fd2e
5 changed files with 30 additions and 18 deletions

View file

@ -1,6 +1,7 @@
- profile: include profile editing in undo system - profile: include profile editing in undo system
- core: avoid crash with corrupted cloud storage - core: avoid crash with corrupted cloud storage
- mobile: fix profile scaling issue on high DPR devices - mobile: fix profile scaling issue on high DPR devices
- mobile: bring back profile icons
- mobile/Android: add logfiles as attachment to support emails - mobile/Android: add logfiles as attachment to support emails
- planner: make ESC (cancel plan) work when moving handles - planner: make ESC (cancel plan) work when moving handles
- dive list: make dive guide visible in dive list [#3382] - dive list: make dive guide visible in dive list [#3382]

View file

@ -335,9 +335,9 @@ endif()
set(SUBSURFACE_LINK_LIBRARIES ${SUBSURFACE_LINK_LIBRARIES} ${LIBDIVECOMPUTER_LIBRARIES} ${LIBGIT2_LIBRARIES} ${LIBUSB_LIBRARIES} ${LIBMTP_LIBRARIES}) set(SUBSURFACE_LINK_LIBRARIES ${SUBSURFACE_LINK_LIBRARIES} ${LIBDIVECOMPUTER_LIBRARIES} ${LIBGIT2_LIBRARIES} ${LIBUSB_LIBRARIES} ${LIBMTP_LIBRARIES})
if (NOT SUBSURFACE_TARGET_EXECUTABLE MATCHES "DownloaderExecutable") if (NOT SUBSURFACE_TARGET_EXECUTABLE MATCHES "DownloaderExecutable")
if(USINGQT6) if(USINGQT6)
qt_add_resources(SUBSURFACE_RESOURCES subsurface.qrc stats/statsicons.qrc desktop-widgets/qml/statsview2.qrc) qt_add_resources(SUBSURFACE_RESOURCES subsurface.qrc profile.qrc stats/statsicons.qrc desktop-widgets/qml/statsview2.qrc)
else() else()
qt5_add_resources(SUBSURFACE_RESOURCES subsurface.qrc stats/statsicons.qrc map-widget/qml/map-widget.qrc desktop-widgets/qml/statsview2.qrc) qt5_add_resources(SUBSURFACE_RESOURCES subsurface.qrc profile.qrc stats/statsicons.qrc map-widget/qml/map-widget.qrc desktop-widgets/qml/statsview2.qrc)
set(SUBSURFACE_MAPWIDGET subsurface_mapwidget) set(SUBSURFACE_MAPWIDGET subsurface_mapwidget)
endif() endif()
endif() endif()
@ -388,10 +388,12 @@ if (SUBSURFACE_TARGET_EXECUTABLE MATCHES "MobileExecutable")
) )
if(USINGQT6) if(USINGQT6)
qt_add_resources(MOBILE_RESOURCES mobile-widgets/qml/mobile-resources.qrc) qt_add_resources(MOBILE_RESOURCES mobile-widgets/qml/mobile-resources.qrc)
qt_add_resources(MOBILE_RESOURCES profile.qrc)
qt_add_resources(MOBILE_RESOURCES mobile-widgets/3rdparty/icons.qrc) qt_add_resources(MOBILE_RESOURCES mobile-widgets/3rdparty/icons.qrc)
qt_add_resources(MOBILE_RESOURCES mobile-widgets/3rdparty/kirigami/src/scenegraph/shaders/shaders.qrc) qt_add_resources(MOBILE_RESOURCES mobile-widgets/3rdparty/kirigami/src/scenegraph/shaders/shaders.qrc)
else() else()
qt5_add_resources(MOBILE_RESOURCES mobile-widgets/qml/mobile-resources.qrc) qt5_add_resources(MOBILE_RESOURCES mobile-widgets/qml/mobile-resources.qrc)
qt5_add_resources(MOBILE_RESOURCES profile.qrc)
qt5_add_resources(MOBILE_RESOURCES mobile-widgets/3rdparty/icons.qrc) qt5_add_resources(MOBILE_RESOURCES mobile-widgets/3rdparty/icons.qrc)
qt5_add_resources(MOBILE_RESOURCES mobile-widgets/3rdparty/kirigami/src/scenegraph/shaders/shaders.qrc) qt5_add_resources(MOBILE_RESOURCES mobile-widgets/3rdparty/kirigami/src/scenegraph/shaders/shaders.qrc)
endif() endif()

View file

@ -338,7 +338,8 @@ HEADERS += \
RESOURCES += mobile-widgets/qml/mobile-resources.qrc \ RESOURCES += mobile-widgets/qml/mobile-resources.qrc \
mobile-widgets/3rdparty/icons.qrc \ mobile-widgets/3rdparty/icons.qrc \
map-widget/qml/map-widget.qrc \ map-widget/qml/map-widget.qrc \
stats/statsicons.qrc stats/statsicons.qrc \
profile.qrc
android { android {
SOURCES += core/android.cpp \ SOURCES += core/android.cpp \

23
profile.qrc Normal file
View file

@ -0,0 +1,23 @@
<RCC>
<qresource prefix="/">
<!-- ************ icons used in the profile ***************** -->
<file alias="status-warning-icon">icons/warning-icon.png</file>
<file alias="status-violation-icon">icons/violation-icon.png</file>
<file alias="status-info-icon">icons/info-icon.png</file>
<file alias="bailout-icon">icons/OC.png</file>
<file alias="onCCRLoop-icon">icons/CCR.png</file>
<file alias="dive-bookmark-icon">icons/flag.svg</file>
<file alias="gaschange-icon">icons/gaschange.png</file>
<file alias="gaschange-air-icon">icons/Air_change.png</file>
<file alias="gaschange-ean-icon">icons/Nx_change.png</file>
<file alias="gaschange-trimix-icon">icons/Tmx_change.png</file>
<file alias="gaschange-oxygen-icon">icons/Oxy_change.png</file>
<file alias="gaschange-air-ICD-icon">icons/Air_changeICD.png</file>
<file alias="gaschange-ean-ICD-icon">icons/Nx_changeICD.png</file>
<file alias="gaschange-trimix-ICD-icon">icons/Tmx_changeICD.png</file>
<file alias="gaschange-oxygen-ICD-icon">icons/Oxy_changeICD.png</file>
<file alias="list-add-icon">icons/plus.png</file>
<file alias="list-remove-icon">icons/trash.png</file>
<file alias="list-remove-disabled-icon">icons/trash-forbidden.png</file>
</qresource>
</RCC>

View file

@ -22,22 +22,7 @@
<file alias="value-minimum-icon">icons/minimum.png</file> <file alias="value-minimum-icon">icons/minimum.png</file>
<file alias="value-maximum-icon">icons/maximum.png</file> <file alias="value-maximum-icon">icons/maximum.png</file>
<file alias="value-average-icon">icons/average.png</file> <file alias="value-average-icon">icons/average.png</file>
<file alias="status-warning-icon">icons/warning-icon.png</file>
<file alias="status-violation-icon">icons/violation-icon.png</file>
<file alias="status-info-icon">icons/info-icon.png</file>
<file alias="gaschange-icon">icons/gaschange.png</file>
<file alias="gaschange-air-icon">icons/Air_change.png</file>
<file alias="gaschange-ean-icon">icons/Nx_change.png</file>
<file alias="gaschange-trimix-icon">icons/Tmx_change.png</file>
<file alias="gaschange-oxygen-icon">icons/Oxy_change.png</file>
<file alias="gaschange-air-ICD-icon">icons/Air_changeICD.png</file>
<file alias="gaschange-ean-ICD-icon">icons/Nx_changeICD.png</file>
<file alias="gaschange-trimix-ICD-icon">icons/Tmx_changeICD.png</file>
<file alias="gaschange-oxygen-ICD-icon">icons/Oxy_changeICD.png</file>
<file alias="onCCRLoop-icon">icons/CCR.png</file>
<file alias="bailout-icon">icons/OC.png</file>
<file alias="salinity-warning-icon">icons/bluewarning.png</file> <file alias="salinity-warning-icon">icons/bluewarning.png</file>
<file alias="dive-bookmark-icon">icons/flag.svg</file>
<file alias="ruler-icon">icons/ruler.png</file> <file alias="ruler-icon">icons/ruler.png</file>
<file alias="poster-icon">icons/poster.png</file> <file alias="poster-icon">icons/poster.png</file>
<file>xslt/commonTemplates.xsl</file> <file>xslt/commonTemplates.xsl</file>