Changeset View
Changeset View
Standalone View
Standalone View
plugins/libarchive/libarchiveplugin.cpp
Show First 20 Lines • Show All 439 Lines • ▼ Show 20 Line(s) | 439 | #ifdef Q_OS_WIN | |||
---|---|---|---|---|---|
440 | e->setProperty("fullPath", QDir::fromNativeSeparators(QString::fromUtf16((ushort*)archive_entry_pathname_w(aentry)))); | 440 | e->setProperty("fullPath", QDir::fromNativeSeparators(QString::fromUtf16((ushort*)archive_entry_pathname_w(aentry)))); | ||
441 | #else | 441 | #else | ||
442 | e->setProperty("fullPath", QDir::fromNativeSeparators(QString::fromWCharArray(archive_entry_pathname_w(aentry)))); | 442 | e->setProperty("fullPath", QDir::fromNativeSeparators(QString::fromWCharArray(archive_entry_pathname_w(aentry)))); | ||
443 | #endif | 443 | #endif | ||
444 | 444 | | |||
445 | const QString owner = QString::fromLatin1(archive_entry_uname(aentry)); | 445 | const QString owner = QString::fromLatin1(archive_entry_uname(aentry)); | ||
446 | if (!owner.isEmpty()) { | 446 | if (!owner.isEmpty()) { | ||
447 | e->setProperty("owner", owner); | 447 | e->setProperty("owner", owner); | ||
448 | } else { | ||||
449 | e->setProperty("owner", static_cast<qlonglong>(archive_entry_uid(aentry))); | ||||
448 | } | 450 | } | ||
449 | 451 | | |||
450 | const QString group = QString::fromLatin1(archive_entry_gname(aentry)); | 452 | const QString group = QString::fromLatin1(archive_entry_gname(aentry)); | ||
451 | if (!group.isEmpty()) { | 453 | if (!group.isEmpty()) { | ||
452 | e->setProperty("group", group); | 454 | e->setProperty("group", group); | ||
455 | } else { | ||||
456 | e->setProperty("group", static_cast<qlonglong>(archive_entry_gid(aentry))); | ||||
453 | } | 457 | } | ||
454 | 458 | | |||
455 | e->compressedSizeIsSet = false; | 459 | e->compressedSizeIsSet = false; | ||
456 | e->setProperty("size", (qlonglong)archive_entry_size(aentry)); | 460 | e->setProperty("size", (qlonglong)archive_entry_size(aentry)); | ||
457 | e->setProperty("isDirectory", S_ISDIR(archive_entry_mode(aentry))); | 461 | e->setProperty("isDirectory", S_ISDIR(archive_entry_mode(aentry))); | ||
458 | 462 | | |||
459 | if (archive_entry_symlink(aentry)) { | 463 | if (archive_entry_symlink(aentry)) { | ||
460 | e->setProperty("link", QLatin1String( archive_entry_symlink(aentry) )); | 464 | e->setProperty("link", QLatin1String( archive_entry_symlink(aentry) )); | ||
▲ Show 20 Lines • Show All 118 Lines • Show Last 20 Lines |