diff --git a/images/dark/drive-harddisk-root.svg b/images/dark/drive-harddisk-root.svg
new file mode 100755
index 0000000..bc8476c
--- /dev/null
+++ b/images/dark/drive-harddisk-root.svg
@@ -0,0 +1,85 @@
+
+
diff --git a/images/dark/drive-harddisk.svg b/images/dark/drive-harddisk.svg
new file mode 100755
index 0000000..c53f4e3
--- /dev/null
+++ b/images/dark/drive-harddisk.svg
@@ -0,0 +1,85 @@
+
+
diff --git a/images/dark/drive-removable-media-usb.svg b/images/dark/drive-removable-media-usb.svg
new file mode 100755
index 0000000..18ec008
--- /dev/null
+++ b/images/dark/drive-removable-media-usb.svg
@@ -0,0 +1,93 @@
+
+
diff --git a/images/dark/folder-desktop.svg b/images/dark/folder-desktop.svg
new file mode 100755
index 0000000..f110623
--- /dev/null
+++ b/images/dark/folder-desktop.svg
@@ -0,0 +1,61 @@
+
+
diff --git a/images/dark/folder-document.svg b/images/dark/folder-document.svg
new file mode 100755
index 0000000..5cb586f
--- /dev/null
+++ b/images/dark/folder-document.svg
@@ -0,0 +1,120 @@
+
+
diff --git a/images/dark/folder-download.svg b/images/dark/folder-download.svg
new file mode 100755
index 0000000..cbd716f
--- /dev/null
+++ b/images/dark/folder-download.svg
@@ -0,0 +1,60 @@
+
+
diff --git a/images/dark/folder-home.svg b/images/dark/folder-home.svg
new file mode 100755
index 0000000..05c44fc
--- /dev/null
+++ b/images/dark/folder-home.svg
@@ -0,0 +1,59 @@
+
+
diff --git a/images/dark/folder-music.svg b/images/dark/folder-music.svg
new file mode 100755
index 0000000..ddf4877
--- /dev/null
+++ b/images/dark/folder-music.svg
@@ -0,0 +1,59 @@
+
+
diff --git a/images/dark/folder-picture.svg b/images/dark/folder-picture.svg
new file mode 100755
index 0000000..1c24813
--- /dev/null
+++ b/images/dark/folder-picture.svg
@@ -0,0 +1,59 @@
+
+
diff --git a/images/dark/folder-video.svg b/images/dark/folder-video.svg
new file mode 100755
index 0000000..c98de6a
--- /dev/null
+++ b/images/dark/folder-video.svg
@@ -0,0 +1,59 @@
+
+
diff --git a/images/dark/user-trash.svg b/images/dark/user-trash.svg
new file mode 100755
index 0000000..1ef8d84
--- /dev/null
+++ b/images/dark/user-trash.svg
@@ -0,0 +1,59 @@
+
+
diff --git a/images/folder-desktop.svg b/images/folder-desktop.svg
deleted file mode 100755
index e1b94f9..0000000
--- a/images/folder-desktop.svg
+++ /dev/null
@@ -1,6 +0,0 @@
-
diff --git a/images/drive-harddisk-root.svg b/images/light/drive-harddisk-root.svg
similarity index 100%
rename from images/drive-harddisk-root.svg
rename to images/light/drive-harddisk-root.svg
diff --git a/images/drive-harddisk.svg b/images/light/drive-harddisk.svg
similarity index 100%
rename from images/drive-harddisk.svg
rename to images/light/drive-harddisk.svg
diff --git a/images/drive-removable-media-usb.svg b/images/light/drive-removable-media-usb.svg
similarity index 100%
rename from images/drive-removable-media-usb.svg
rename to images/light/drive-removable-media-usb.svg
diff --git a/images/light/folder-desktop.svg b/images/light/folder-desktop.svg
new file mode 100755
index 0000000..621ad62
--- /dev/null
+++ b/images/light/folder-desktop.svg
@@ -0,0 +1,61 @@
+
+
diff --git a/images/folder-document.svg b/images/light/folder-document.svg
similarity index 100%
rename from images/folder-document.svg
rename to images/light/folder-document.svg
diff --git a/images/folder-download.svg b/images/light/folder-download.svg
similarity index 100%
rename from images/folder-download.svg
rename to images/light/folder-download.svg
diff --git a/images/folder-home.svg b/images/light/folder-home.svg
similarity index 100%
rename from images/folder-home.svg
rename to images/light/folder-home.svg
diff --git a/images/folder-music.svg b/images/light/folder-music.svg
similarity index 100%
rename from images/folder-music.svg
rename to images/light/folder-music.svg
diff --git a/images/folder-picture.svg b/images/light/folder-picture.svg
similarity index 100%
rename from images/folder-picture.svg
rename to images/light/folder-picture.svg
diff --git a/images/folder-video.svg b/images/light/folder-video.svg
similarity index 100%
rename from images/folder-video.svg
rename to images/light/folder-video.svg
diff --git a/images/user-trash.svg b/images/light/user-trash.svg
similarity index 100%
rename from images/user-trash.svg
rename to images/light/user-trash.svg
diff --git a/model/placesitem.cpp b/model/placesitem.cpp
index ba87969..8497d8f 100644
--- a/model/placesitem.cpp
+++ b/model/placesitem.cpp
@@ -113,7 +113,7 @@ void PlacesItem::updateDeviceInfo(const QString &udi)
if (m_device.isValid()) {
m_access = m_device.as();
m_iconName = m_device.icon();
- m_iconPath = QString("qrc:/images/%1.svg").arg(m_iconName);
+ m_iconPath = QString("%1.svg").arg(m_iconName);
m_displayName = m_device.displayName();
if (m_access) {
diff --git a/model/placesmodel.cpp b/model/placesmodel.cpp
index 5b28c33..1b8f658 100644
--- a/model/placesmodel.cpp
+++ b/model/placesmodel.cpp
@@ -37,54 +37,54 @@ PlacesModel::PlacesModel(QObject *parent)
if (QDir(homePath).exists()) {
PlacesItem *item = new PlacesItem(tr("Home"), QUrl::fromLocalFile(homePath));
- item->setIconPath("qrc:/images/folder-home.svg");
+ item->setIconPath("folder-home.svg");
m_items.append(item);
}
const QString desktopPath = QStandardPaths::writableLocation(QStandardPaths::DesktopLocation);
if (QDir(desktopPath).exists()) {
PlacesItem *item = new PlacesItem(tr("Desktop"), QUrl::fromLocalFile(desktopPath));
- item->setIconPath("qrc:/images/folder-desktop.svg");
+ item->setIconPath("folder-desktop.svg");
m_items.append(item);
}
const QString documentsPath = QStandardPaths::writableLocation(QStandardPaths::DocumentsLocation);
if (QDir(documentsPath).exists()) {
PlacesItem *item = new PlacesItem(tr("Documents"), QUrl::fromLocalFile(documentsPath));
- item->setIconPath("qrc:/images/folder-document.svg");
+ item->setIconPath("folder-document.svg");
m_items.append(item);
}
const QString downloadPath = QStandardPaths::writableLocation(QStandardPaths::DownloadLocation);
if (QDir(downloadPath).exists()) {
PlacesItem *item = new PlacesItem(tr("Downloads"), QUrl::fromLocalFile(downloadPath));
- item->setIconPath("qrc:/images/folder-download.svg");
+ item->setIconPath("folder-download.svg");
m_items.append(item);
}
const QString musicPath = QStandardPaths::writableLocation(QStandardPaths::MusicLocation);
if (QDir(musicPath).exists()) {
PlacesItem *item = new PlacesItem(tr("Music"), QUrl::fromLocalFile(musicPath));
- item->setIconPath("qrc:/images/folder-music.svg");
+ item->setIconPath("folder-music.svg");
m_items.append(item);
}
const QString picturePath = QStandardPaths::writableLocation(QStandardPaths::PicturesLocation);
if (QDir(picturePath).exists()) {
PlacesItem *item = new PlacesItem(tr("Pictures"), QUrl::fromLocalFile(picturePath));
- item->setIconPath("qrc:/images/folder-picture.svg");
+ item->setIconPath("folder-picture.svg");
m_items.append(item);
}
const QString videoPath = QStandardPaths::writableLocation(QStandardPaths::MoviesLocation);
if (QDir(videoPath).exists()) {
PlacesItem *item = new PlacesItem(tr("Videos"), QUrl::fromLocalFile(videoPath));
- item->setIconPath("qrc:/images/folder-video.svg");
+ item->setIconPath("folder-video.svg");
m_items.append(item);
}
PlacesItem *trashItem = new PlacesItem(tr("Trash"), QUrl(QStringLiteral("trash:/")));
- trashItem->setIconPath("qrc:/images/user-trash.svg");
+ trashItem->setIconPath("user-trash.svg");
m_items.append(trashItem);
QString predicateStr(
diff --git a/qml.qrc b/qml.qrc
index 8d647c7..642df45 100644
--- a/qml.qrc
+++ b/qml.qrc
@@ -15,23 +15,12 @@
images/light/go-previous.svg
images/light/grid.svg
images/light/list.svg
- images/folder-desktop.svg
- images/folder-document.svg
- images/folder-download.svg
- images/folder-home.svg
- images/folder-music.svg
- images/folder-picture.svg
- images/folder-video.svg
- images/user-trash.svg
- images/drive-removable-media-usb.svg
qml/PathBar.qml
qml/Desktop/main.qml
qml/FolderGridView.qml
qml/GlobalSettings.qml
qml/FolderGridItem.qml
qml/Dialogs/CreateFolderDialog.qml
- images/drive-harddisk.svg
- images/drive-harddisk-root.svg
images/light/checked.svg
images/dark/checked.svg
images/light/order_by_name.svg
@@ -44,5 +33,27 @@
images/light/up.svg
images/dark/up.svg
qml/Dialogs/EmptyTrashDialog.qml
+ images/light/drive-harddisk-root.svg
+ images/light/drive-harddisk.svg
+ images/light/drive-removable-media-usb.svg
+ images/light/folder-desktop.svg
+ images/light/folder-document.svg
+ images/light/folder-download.svg
+ images/light/folder-home.svg
+ images/light/folder-music.svg
+ images/light/folder-picture.svg
+ images/light/folder-video.svg
+ images/light/user-trash.svg
+ images/dark/drive-harddisk-root.svg
+ images/dark/drive-harddisk.svg
+ images/dark/drive-removable-media-usb.svg
+ images/dark/folder-desktop.svg
+ images/dark/folder-document.svg
+ images/dark/folder-download.svg
+ images/dark/folder-home.svg
+ images/dark/folder-music.svg
+ images/dark/folder-picture.svg
+ images/dark/folder-video.svg
+ images/dark/user-trash.svg
diff --git a/qml/SideBar.qml b/qml/SideBar.qml
index 05dd117..efb3353 100644
--- a/qml/SideBar.qml
+++ b/qml/SideBar.qml
@@ -20,7 +20,6 @@
import QtQuick 2.12
import QtQuick.Layouts 1.12
import QtQuick.Controls 2.12
-import QtGraphicalEffects 1.0
import FishUI 1.0 as FishUI
import Cutefish.FileManager 1.0
@@ -91,18 +90,12 @@ ListView {
spacing: FishUI.Units.smallSpacing
Image {
- height: _item.height * 0.55
+ height: 22
width: height
sourceSize: Qt.size(width, height)
- source: model.iconPath ? model.iconPath : "image://icontheme/" + model.iconName
+ // source: model.iconPath ? model.iconPath : "image://icontheme/" + model.iconName
+ source: "qrc:/images/" + (FishUI.Theme.darkMode || _item.checked ? "dark/" : "light/") + model.iconPath
Layout.alignment: Qt.AlignVCenter
-
- ColorOverlay {
- anchors.fill: parent
- source: parent
- color: _label.color
- visible: FishUI.Theme.darkMode && model.iconPath || checked
- }
}
Label {