mirror of
https://github.com/iDescriptor/iDescriptor.git
synced 2026-06-21 19:35:49 +08:00
fix null folderIcon
This commit is contained in:
@@ -34,6 +34,7 @@
|
||||
<file>resources/icons/ClarityEyeHideLine.png</file>
|
||||
<file>resources/icons/ClarityEyeLine.png</file>
|
||||
<file>resources/icons/MaterialSymbolsLightImageOutlineSharp.png</file>
|
||||
<file>resources/icons/MaterialSymbolsFolder.png</file>
|
||||
<file>qml/MapView.qml</file>
|
||||
<file>resources/iphone.png</file>
|
||||
<file>resources/ios-wallpapers/iphone-ios4.png</file>
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 8.4 KiB |
@@ -221,9 +221,15 @@ void AfcExplorerWidget::loadPath(const QString &path)
|
||||
QListWidgetItem *item =
|
||||
new QListWidgetItem(QString::fromStdString(entry.name));
|
||||
item->setData(Qt::UserRole, entry.isDir);
|
||||
if (entry.isDir)
|
||||
item->setIcon(QIcon::fromTheme("folder"));
|
||||
else {
|
||||
if (entry.isDir) {
|
||||
QIcon folderIcon = QIcon::fromTheme("folder");
|
||||
if (folderIcon.isNull()) {
|
||||
item->setIcon(
|
||||
QIcon(":/resources/icons/MaterialSymbolsFolder.png"));
|
||||
} else {
|
||||
item->setIcon(folderIcon);
|
||||
}
|
||||
} else {
|
||||
QIcon fileIcon = QIcon::fromTheme("text-x-generic");
|
||||
if (fileIcon.isNull()) {
|
||||
item->setIcon(
|
||||
|
||||
Reference in New Issue
Block a user