generic: remove konqueror leftovers

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
Ivailo Monev 2024-03-15 05:02:56 +02:00
parent bbdada22fd
commit 5c1b5a284f
6 changed files with 6 additions and 40 deletions

View file

@ -28,8 +28,6 @@
#include <settings/viewmodes/viewsettingstab.h>
#include <QDBusConnection>
#include <QDBusMessage>
#include <QDir>
#include <QPushButton>
#include <QVBoxLayout>
@ -84,7 +82,6 @@ void DolphinViewModesConfigModule::save()
foreach (ViewSettingsTab* tab, m_tabs) {
tab->applySettings();
}
reparseConfiguration();
}
void DolphinViewModesConfigModule::defaults()
@ -92,13 +89,6 @@ void DolphinViewModesConfigModule::defaults()
foreach (ViewSettingsTab* tab, m_tabs) {
tab->restoreDefaultSettings();
}
reparseConfiguration();
}
void DolphinViewModesConfigModule::reparseConfiguration()
{
QDBusMessage message = QDBusMessage::createSignal("/KonqMain", "org.kde.Konqueror.Main", "reparseConfiguration");
QDBusConnection::sessionBus().send(message);
}
void DolphinViewModesConfigModule::viewModeChanged()

View file

@ -38,9 +38,6 @@ public:
virtual void save();
virtual void defaults();
private:
void reparseConfiguration();
private Q_SLOTS:
void viewModeChanged();

View file

@ -26,10 +26,8 @@
// Qt
#include <QLabel>
#include <QLayout>
#include <QtCore/QTimer>
#include <QTimer>
#include <QBoxLayout>
#include <qdbusconnection.h>
#include <qdbusmessage.h>
// KDE
#include <kbuildsycocaprogressdialog.h>
@ -398,11 +396,9 @@ void FileTypesView::save()
{
bool needUpdateMimeDb = false;
bool needUpdateSycoca = false;
bool didIt = false;
// first, remove those items which we are asked to remove.
Q_FOREACH(const QString& mime, removedList) {
MimeTypeWriter::removeOwnMimeType(mime);
didIt = true;
needUpdateMimeDb = true;
needUpdateSycoca = true; // remove offers for this mimetype
}
@ -417,7 +413,6 @@ void FileTypesView::save()
kDebug() << "Entry " << tli->name() << " is dirty. Saving.";
if (tli->mimeTypeData().sync())
needUpdateMimeDb = true;
didIt = true;
}
++it1;
}
@ -428,7 +423,6 @@ void FileTypesView::save()
kDebug() << "Entry " << tli->name() << " is dirty. Saving.";
if (tli->mimeTypeData().sync())
needUpdateMimeDb = true;
didIt = true;
}
}
@ -443,15 +437,6 @@ void FileTypesView::save()
KBuildSycocaProgressDialog::rebuildKSycoca(this);
}
if (didIt) { // TODO make more specific: only if autoEmbed changed? Well, maybe this is useful for icon and glob changes too...
// Trigger reparseConfiguration of filetypesrc in konqueror
// TODO: the same for dolphin. Or we should probably define a global signal for this.
// Or a KGlobalSettings thing.
QDBusMessage message =
QDBusMessage::createSignal("/KonqMain", "org.kde.Konqueror.Main", "reparseConfiguration");
QDBusConnection::sessionBus().send(message);
}
updateDisplay(typesLV->currentItem());
}

View file

@ -22,9 +22,7 @@
#include "mimetypewriter.h"
// Qt
#include <qdbusconnection.h>
#include <qdbusmessage.h>
#include <QtCore/QFile>
#include <QFile>
// KDE
#include <kapplication.h>
@ -80,10 +78,6 @@ void FileTypeDialog::save()
MimeTypeWriter::runUpdateMimeDatabase();
if (servicesDirty)
KBuildSycocaProgressDialog::rebuildKSycoca(this);
// Trigger reparseConfiguration of filetypesrc in konqueror
QDBusMessage message =
QDBusMessage::createSignal("/KonqMain", "org.kde.Konqueror.Main", "reparseConfiguration");
QDBusConnection::sessionBus().send(message);
}
}

View file

@ -325,7 +325,7 @@ bool KShortUriFilter::filterUri( KUriFilterData& data ) const
exists = ( KDE::stat( path, &buff ) == 0 );
if ( !exists ) {
// Support for name filter (/foo/*.txt), see also KonqMainWindow::detectNameFilter
// Support for name filter (/foo/*.txt)
// If the app using this filter doesn't support it, well, it'll simply error out itself
int lastSlash = path.lastIndexOf( '/' );
if ( lastSlash > -1 && path.indexOf( ' ', lastSlash ) == -1 ) // no space after last slash, otherwise it's more likely command-line arguments

View file

@ -315,7 +315,7 @@ void KonqPopupMenuTest::testViewDirectory()
beflags |= KonqPopupMenu::ShowUrlOperations;
beflags |= KonqPopupMenu::ShowProperties;
// KonqMainWindow says: doTabHandling = !openedForViewURL && ... So we don't add tabhandling here
// doTabHandling = !openedForViewURL && ... So we don't add tabhandling here
KonqPopupMenu::ActionGroupMap actionGroups;
actionGroups.insert("preview", m_previewActions->actions());
@ -359,7 +359,7 @@ void KonqPopupMenuTest::testViewReadOnlyDirectory()
beflags |= KonqPopupMenu::ShowUrlOperations;
beflags |= KonqPopupMenu::ShowProperties;
// KonqMainWindow says: doTabHandling = !openedForViewURL && ... So we don't add tabhandling here
// doTabHandling = !openedForViewURL && ... So we don't add tabhandling here
KonqPopupMenu::ActionGroupMap actionGroups;
actionGroups.insert("preview", m_previewActions->actions());
@ -430,7 +430,7 @@ void KonqPopupMenuTest::testHtmlPage()
beflags |= KonqPopupMenu::ShowNavigationItems;
KonqPopupMenu::ActionGroupMap actionGroups;
// KonqMainWindow says: doTabHandling = !openedForViewURL && ... So we don't add tabhandling here
// doTabHandling = !openedForViewURL && ... So we don't add tabhandling here
// TODO we could just move that logic to KonqPopupMenu...
//actionGroups.insert("tabhandling", m_tabHandlingActions->actions());
actionGroups.insert("preview", m_previewActions->actions());