Changeset View
Changeset View
Standalone View
Standalone View
src/widgets/kpropertiesdialog.cpp
Show First 20 Lines • Show All 1152 Lines • ▼ Show 20 Line(s) | 835 | #endif | |||
---|---|---|---|---|---|
1153 | } | 1153 | } | ||
1154 | 1154 | | |||
1155 | if (hasDirs) { // only for directories | 1155 | if (hasDirs) { // only for directories | ||
1156 | sep = new KSeparator(Qt::Horizontal, d->m_frame); | 1156 | sep = new KSeparator(Qt::Horizontal, d->m_frame); | ||
1157 | grid->addWidget(sep, curRow, 0, 1, 3); | 1157 | grid->addWidget(sep, curRow, 0, 1, 3); | ||
1158 | ++curRow; | 1158 | ++curRow; | ||
1159 | 1159 | | |||
1160 | if (isLocal) { | 1160 | if (isLocal) { | ||
1161 | KMountPoint::Ptr mp = KMountPoint::currentMountPoints().findByPath(url.toLocalFile()); | 1161 | KMountPoint::Ptr mp = KMountPoint::currentMountPoints().findByPath(url.toLocalFile()); | ||
broulik: Captailize: File System | |||||
1162 | | ||||
1163 | l = new QLabel(i18n("File System:"), d->m_frame); | ||||
1164 | grid->addWidget(l, curRow, 0, Qt::AlignRight); | ||||
This leaks, you can probably create it on the stack: QStorageInfo storageInfo(...); Also, shouldn't you pass url.toLocalFile() instead of hardcoded /? broulik: This leaks, you can probably create it on the stack:
```
QStorageInfo storageInfo(...);
```… | |||||
1165 | | ||||
1166 | l = new QLabel(d->m_frame); | ||||
1167 | grid->addWidget(l, curRow++, 2); | ||||
1168 | l->setTextInteractionFlags(Qt::TextSelectableByMouse | Qt::TextSelectableByKeyboard); | ||||
1169 | l->setText(mp->mountType()); | ||||
broulik: `QString::fromLatin1`? | |||||
1170 | | ||||
1162 | if (mp && mp->mountPoint() != QLatin1String("/")) { | 1171 | if (mp && mp->mountPoint() != QLatin1String("/")) { | ||
1163 | l = new QLabel(i18n("Mounted on:"), d->m_frame); | 1172 | l = new QLabel(i18n("Mounted on:"), d->m_frame); | ||
1164 | grid->addWidget(l, curRow, 0, Qt::AlignRight); | 1173 | grid->addWidget(l, curRow, 0, Qt::AlignRight); | ||
1165 | 1174 | | |||
1166 | l = new KSqueezedTextLabel(mp->mountPoint(), d->m_frame); | 1175 | l = new KSqueezedTextLabel(mp->mountPoint(), d->m_frame); | ||
1167 | l->setTextInteractionFlags(Qt::TextSelectableByMouse | Qt::TextSelectableByKeyboard); | 1176 | l->setTextInteractionFlags(Qt::TextSelectableByMouse | Qt::TextSelectableByKeyboard); | ||
1168 | grid->addWidget(l, curRow++, 2); | 1177 | grid->addWidget(l, curRow++, 2); | ||
1178 | | ||||
1179 | l = new QLabel(i18n("Mounted from:"), d->m_frame); | ||||
1180 | grid->addWidget(l, curRow, 0, Qt::AlignRight); | ||||
1181 | | ||||
1182 | l = new QLabel(d->m_frame); | ||||
1183 | grid->addWidget(l, curRow++, 2); | ||||
1184 | l->setTextInteractionFlags(Qt::TextSelectableByMouse | Qt::TextSelectableByKeyboard); | ||||
1185 | l->setText(mp->mountedFrom()); | ||||
1169 | } | 1186 | } | ||
1170 | } | 1187 | } | ||
1171 | 1188 | | |||
1172 | l = new QLabel(i18n("Device usage:"), d->m_frame); | 1189 | l = new QLabel(i18n("Device usage:"), d->m_frame); | ||
1173 | grid->addWidget(l, curRow, 0, Qt::AlignRight); | 1190 | grid->addWidget(l, curRow, 0, Qt::AlignRight); | ||
1174 | 1191 | | |||
1175 | d->m_capacityBar = new KCapacityBar(KCapacityBar::DrawTextOutline, d->m_frame); | 1192 | d->m_capacityBar = new KCapacityBar(KCapacityBar::DrawTextOutline, d->m_frame); | ||
1176 | d->m_capacityBar->setText(i18nc("@info:status", "Unknown size")); | 1193 | d->m_capacityBar->setText(i18nc("@info:status", "Unknown size")); | ||
▲ Show 20 Lines • Show All 2739 Lines • Show Last 20 Lines |
Captailize: File System