diff --git a/src/gui/ErrorBox.qml b/src/gui/ErrorBox.qml index f51fd417dce5b..10699b90b665b 100644 --- a/src/gui/ErrorBox.qml +++ b/src/gui/ErrorBox.qml @@ -70,7 +70,7 @@ Item { background: null icon.color: palette.buttonText - icon.source: "qrc:///client/theme/close.svg" + icon.source: "image://svgimage-custom-color/close.svg" visible: errorBox.showCloseButton enabled: visible diff --git a/src/gui/tray/UnifiedSearchResultNothingFound.qml b/src/gui/tray/UnifiedSearchResultNothingFound.qml index 281d20e12b137..175874e57aa39 100644 --- a/src/gui/tray/UnifiedSearchResultNothingFound.qml +++ b/src/gui/tray/UnifiedSearchResultNothingFound.qml @@ -29,7 +29,7 @@ ColumnLayout { Image { id: unifiedSearchResultsNoResultsLabelIcon - source: "qrc:///client/theme/magnifying-glass.svg" + source: "image://svgimage-custom-color/magnifying-glass.svg" sourceSize.width: Style.trayWindowHeaderHeight / 2 sourceSize.height: Style.trayWindowHeaderHeight / 2 Layout.alignment: Qt.AlignHCenter diff --git a/src/gui/tray/Window.qml b/src/gui/tray/Window.qml index c501091205d3a..ccb192781597a 100644 --- a/src/gui/tray/Window.qml +++ b/src/gui/tray/Window.qml @@ -326,7 +326,7 @@ ApplicationWindow { Image { Layout.leftMargin: 12 verticalAlignment: Qt.AlignCenter - source: Theme.darkMode ? "qrc:///client/theme/white/add.svg" : "qrc:///client/theme/black/add.svg" + source: "image://svgimage-custom-color/add.svg" sourceSize.width: Style.headerButtonIconSize sourceSize.height: Style.headerButtonIconSize } @@ -513,7 +513,7 @@ ApplicationWindow { Layout.alignment: Qt.AlignRight verticalAlignment: Qt.AlignCenter Layout.margins: Style.accountDropDownCaretMargin - source: "qrc:///client/theme/white/caret-down.svg" + source: "image://svgimage-custom-color/caret-down.svg/" sourceSize.width: Style.accountDropDownCaretSize sourceSize.height: Style.accountDropDownCaretSize Accessible.role: Accessible.PopupMenu diff --git a/src/gui/tray/activitydata.cpp b/src/gui/tray/activitydata.cpp index bc2bdda585fee..762a9cc3e4e77 100644 --- a/src/gui/tray/activitydata.cpp +++ b/src/gui/tray/activitydata.cpp @@ -165,11 +165,11 @@ OCC::Activity Activity::fromActivityJson(const QJsonObject &json, const AccountP if(!previewsData.isEmpty()) { if(activity._icon.contains(QStringLiteral("add-color.svg"))) { - activity._icon = "qrc:///client/theme/colored/add-bordered.svg"; - } else if(activity._icon.contains(QStringLiteral("delete-color.svg"))) { - activity._icon = "qrc:///client/theme/colored/delete-bordered.svg"; + activity._icon = "image://svgimage-custom-color/add.svg"; + } else if(activity._icon.contains(QStringLiteral("delete.svg"))) { + activity._icon = "image://svgimage-custom-color/delete.svg"; } else if(activity._icon.contains(QStringLiteral("change.svg"))) { - activity._icon = "qrc:///client/theme/colored/change-bordered.svg"; + activity._icon = "image://svgimage-custom-color/change.svg"; } } diff --git a/src/gui/tray/activitylistmodel.cpp b/src/gui/tray/activitylistmodel.cpp index 61c05b8d8c796..463aea390a1d4 100644 --- a/src/gui/tray/activitylistmodel.cpp +++ b/src/gui/tray/activitylistmodel.cpp @@ -226,9 +226,9 @@ QVariant ActivityListModel::data(const QModelIndex &index, int role) const }; const auto generateIconPath = [&]() { - auto colorIconPath = role == DarkIconRole ? QStringLiteral("qrc:///client/theme/white/") : QStringLiteral("qrc:///client/theme/black/"); + auto colorIconPath = QStringLiteral("image://svgimage-custom-color/");//role == DarkIconRole ? QStringLiteral("qrc:///client/theme/white/") : QStringLiteral("qrc:///client/theme/black/"); if (a._type == Activity::NotificationType && !a._talkNotificationData.userAvatar.isEmpty()) { - return QStringLiteral("qrc:///client/theme/colored/talk-bordered.svg"); + return QStringLiteral("image://svgimage-custom-color/talk-bordered.svg"); } else if (a._type == Activity::SyncResultType) { colorIconPath.append("state-error.svg"); return colorIconPath; @@ -254,14 +254,14 @@ QVariant ActivityListModel::data(const QModelIndex &index, int role) const } else { // File sync successful if (a._fileAction == "file_created") { - return a._previews.empty() ? QStringLiteral("qrc:///client/theme/colored/add.svg") - : QStringLiteral("qrc:///client/theme/colored/add-bordered.svg"); + return a._previews.empty() ? QStringLiteral("image://svgimage-custom-color/add.svg") + : QStringLiteral("image://svgimage-custom-color/add-bordered.svg"); } else if (a._fileAction == "file_deleted") { - return a._previews.empty() ? QStringLiteral("qrc:///client/theme/colored/delete.svg") - : QStringLiteral("qrc:///client/theme/colored/delete-bordered.svg"); + return a._previews.empty() ? QStringLiteral("image://svgimage-custom-color/delete.svg") + : QStringLiteral("image://svgimage-custom-color/delete-bordered.svg"); } else { return a._previews.empty() ? colorIconPath % QStringLiteral("change.svg") - : QStringLiteral("qrc:///client/theme/colored/change-bordered.svg"); + : QStringLiteral("image://svgimage-custom-color/change-bordered.svg"); } } } else { @@ -511,7 +511,7 @@ void ActivityListModel::insertOrRemoveDummyFetchingActivity() _dummyFetchingActivities._objectType = dummyFetchingActivityObjectType; _dummyFetchingActivities._subject = tr("Fetching activities …"); _dummyFetchingActivities._dateTime = QDateTime::currentDateTime(); - _dummyFetchingActivities._icon = QLatin1String("qrc:///client/theme/colored/change-bordered.svg"); + _dummyFetchingActivities._icon = QLatin1String("image://svgimage-custom-color/change-bordered.svg"); addEntriesToActivityList({_dummyFetchingActivities}); } else if (!_finalList.isEmpty() && _finalList.first()._objectType == dummyFetchingActivityObjectType) {