// Note that the parent folder must be expanded before any of its subfolders become visible.
// Therefore, some URLs in m_restoredExpandedUrls might not be visible yet
// -> we expand the first visible URL we find in m_restoredExpandedUrls.
- foreach(const KUrl& url, m_urlsToExpand) {
+ foreach (const KUrl& url, m_urlsToExpand) {
const int index = m_items.value(url, -1);
if (index >= 0) {
m_urlsToExpand.remove(url);
connect(notifier, SIGNAL(deviceRemoved(QString)), this, SLOT(slotDeviceRemoved(QString)));
const QList<Solid::Device>& deviceList = Solid::Device::listFromQuery(m_predicate);
- foreach(const Solid::Device& device, deviceList) {
+ foreach (const Solid::Device& device, deviceList) {
m_availableDevices << device.udi();
}
}
m_clearTerminal = true;
KPluginFactory* factory = 0;
KService::Ptr service = KService::serviceByDesktopName("konsolepart");
- if(service) {
+ if (service) {
factory = KPluginLoader(service->library()).factory();
}
m_konsolePart = factory ? (factory->create<KParts::ReadOnlyPart>(this)) : 0;
void ApplyViewPropsJob::slotEntries(KIO::Job*, const KIO::UDSEntryList& list)
{
- foreach(const KIO::UDSEntry& entry, list) {
+ foreach (const KIO::UDSEntry& entry, list) {
const QString name = entry.stringValue(KIO::UDSEntry::UDS_NAME);
- if ((name != ".") && (name != "..") && entry.isDir()) {
+ if (name != QLatin1String(".") && name != QLatin1String("..") && entry.isDir()) {
++m_progress;
KUrl url(m_dir);
// Note that the upgrade to the correct plugin is done already in KFilePreviewGenerator. However, if Konqueror is
// opened in web browsing mode and the Settings dialog is opened, we might end up here before KFilePreviewGenerator's
// constructor is ever called -> the plugin replacement should be done here as well.
- if(m_enabledPreviewPlugins.contains(QLatin1String("jpegrotatedthumbnail"))) {
+ if (m_enabledPreviewPlugins.contains(QLatin1String("jpegrotatedthumbnail"))) {
m_enabledPreviewPlugins.removeAll(QLatin1String("jpegrotatedthumbnail"));
m_enabledPreviewPlugins.append(QLatin1String("jpegthumbnail"));
globalConfig.writeEntry("Plugins", m_enabledPreviewPlugins);