Changeset View
Changeset View
Standalone View
Standalone View
src/core/kprotocolinfo.cpp
Show First 20 Lines • Show All 47 Lines • ▼ Show 20 Line(s) | 35 | { | |||
---|---|---|---|---|---|
48 | m_supportsMoving = config.readEntry("moving", false); | 48 | m_supportsMoving = config.readEntry("moving", false); | ||
49 | m_supportsOpening = config.readEntry("opening", false); | 49 | m_supportsOpening = config.readEntry("opening", false); | ||
50 | m_supportsTruncating = config.readEntry("truncating", false); | 50 | m_supportsTruncating = config.readEntry("truncating", false); | ||
51 | m_canCopyFromFile = config.readEntry("copyFromFile", false); | 51 | m_canCopyFromFile = config.readEntry("copyFromFile", false); | ||
52 | m_canCopyToFile = config.readEntry("copyToFile", false); | 52 | m_canCopyToFile = config.readEntry("copyToFile", false); | ||
53 | m_canRenameFromFile = config.readEntry("renameFromFile", false); | 53 | m_canRenameFromFile = config.readEntry("renameFromFile", false); | ||
54 | m_canRenameToFile = config.readEntry("renameToFile", false); | 54 | m_canRenameToFile = config.readEntry("renameToFile", false); | ||
55 | m_canDeleteRecursive = config.readEntry("deleteRecursive", false); | 55 | m_canDeleteRecursive = config.readEntry("deleteRecursive", false); | ||
56 | m_supportsPrivilegeExecution = config.readEntry("privilegeExecution", false); | ||||
56 | const QString fnu = config.readEntry("fileNameUsedForCopying", "FromURL"); | 57 | const QString fnu = config.readEntry("fileNameUsedForCopying", "FromURL"); | ||
57 | m_fileNameUsedForCopying = KProtocolInfo::FromUrl; | 58 | m_fileNameUsedForCopying = KProtocolInfo::FromUrl; | ||
58 | if (fnu == QLatin1String("Name")) { | 59 | if (fnu == QLatin1String("Name")) { | ||
59 | m_fileNameUsedForCopying = KProtocolInfo::Name; | 60 | m_fileNameUsedForCopying = KProtocolInfo::Name; | ||
60 | } else if (fnu == QLatin1String("DisplayName")) { | 61 | } else if (fnu == QLatin1String("DisplayName")) { | ||
61 | m_fileNameUsedForCopying = KProtocolInfo::DisplayName; | 62 | m_fileNameUsedForCopying = KProtocolInfo::DisplayName; | ||
62 | } | 63 | } | ||
63 | 64 | | |||
▲ Show 20 Lines • Show All 74 Lines • ▼ Show 20 Line(s) | 128 | { | |||
138 | m_supportsMoving = json.value(QStringLiteral("moving")).toBool(); | 139 | m_supportsMoving = json.value(QStringLiteral("moving")).toBool(); | ||
139 | m_supportsOpening = json.value(QStringLiteral("opening")).toBool(); | 140 | m_supportsOpening = json.value(QStringLiteral("opening")).toBool(); | ||
140 | m_supportsTruncating = json.value(QStringLiteral("truncating")).toBool(); | 141 | m_supportsTruncating = json.value(QStringLiteral("truncating")).toBool(); | ||
141 | m_canCopyFromFile = json.value(QStringLiteral("copyFromFile")).toBool(); | 142 | m_canCopyFromFile = json.value(QStringLiteral("copyFromFile")).toBool(); | ||
142 | m_canCopyToFile = json.value(QStringLiteral("copyToFile")).toBool(); | 143 | m_canCopyToFile = json.value(QStringLiteral("copyToFile")).toBool(); | ||
143 | m_canRenameFromFile = json.value(QStringLiteral("renameFromFile")).toBool(); | 144 | m_canRenameFromFile = json.value(QStringLiteral("renameFromFile")).toBool(); | ||
144 | m_canRenameToFile = json.value(QStringLiteral("renameToFile")).toBool(); | 145 | m_canRenameToFile = json.value(QStringLiteral("renameToFile")).toBool(); | ||
145 | m_canDeleteRecursive = json.value(QStringLiteral("deleteRecursive")).toBool(); | 146 | m_canDeleteRecursive = json.value(QStringLiteral("deleteRecursive")).toBool(); | ||
147 | m_supportsPrivilegeExecution = json.value(QStringLiteral("privilegeExecution")).toBool(); | ||||
146 | 148 | | |||
147 | // default is "FromURL" | 149 | // default is "FromURL" | ||
148 | const QString fnu = json.value(QStringLiteral("fileNameUsedForCopying")).toString(); | 150 | const QString fnu = json.value(QStringLiteral("fileNameUsedForCopying")).toString(); | ||
149 | m_fileNameUsedForCopying = KProtocolInfo::FromUrl; | 151 | m_fileNameUsedForCopying = KProtocolInfo::FromUrl; | ||
150 | if (fnu == QLatin1String("Name")) { | 152 | if (fnu == QLatin1String("Name")) { | ||
151 | m_fileNameUsedForCopying = KProtocolInfo::Name; | 153 | m_fileNameUsedForCopying = KProtocolInfo::Name; | ||
152 | } else if (fnu == QLatin1String("DisplayName")) { | 154 | } else if (fnu == QLatin1String("DisplayName")) { | ||
153 | m_fileNameUsedForCopying = KProtocolInfo::DisplayName; | 155 | m_fileNameUsedForCopying = KProtocolInfo::DisplayName; | ||
▲ Show 20 Lines • Show All 277 Lines • Show Last 20 Lines |