mirror of
https://invent.kde.org/system/dolphin
synced 2024-08-22 01:40:02 +00:00
Use only enabled preview plugins in InformationPanelContent and ToolTipManager.
This commit is contained in:
parent
d691aa96f2
commit
0811bf4a2b
|
@ -8,11 +8,13 @@
|
|||
|
||||
#include <KIO/JobUiDelegate>
|
||||
#include <KIO/PreviewJob>
|
||||
#include <KConfigGroup>
|
||||
#include <KIconEffect>
|
||||
#include <KIconLoader>
|
||||
#include <KJobWidgets>
|
||||
#include <KLocalizedString>
|
||||
#include <KSeparator>
|
||||
#include <KSharedConfig>
|
||||
#include <KStringHandler>
|
||||
#include <QPainterPath>
|
||||
|
||||
|
@ -184,7 +186,8 @@ void InformationPanelContent::refreshPixmapView()
|
|||
// can be shown within a short timeframe.
|
||||
m_outdatedPreviewTimer->start();
|
||||
|
||||
QStringList plugins = KIO::PreviewJob::availablePlugins();
|
||||
const KConfigGroup globalConfig(KSharedConfig::openConfig(), "PreviewSettings");
|
||||
const QStringList plugins = globalConfig.readEntry("Plugins", KIO::PreviewJob::defaultPlugins());
|
||||
m_previewJob = new KIO::PreviewJob(KFileItemList() << m_item,
|
||||
QSize(m_preview->width(), m_preview->height()),
|
||||
&plugins);
|
||||
|
|
|
@ -10,7 +10,9 @@
|
|||
|
||||
#include <KIO/JobUiDelegate>
|
||||
#include <KIO/PreviewJob>
|
||||
#include <KConfigGroup>
|
||||
#include <KJobWidgets>
|
||||
#include <KSharedConfig>
|
||||
#include <KToolTipWidget>
|
||||
#include <KIconLoader>
|
||||
|
||||
|
@ -132,7 +134,8 @@ void ToolTipManager::startContentRetrieval()
|
|||
// Request a preview of the item
|
||||
m_fileMetaDataWidget->setPreview(QPixmap());
|
||||
|
||||
QStringList plugins = KIO::PreviewJob::availablePlugins();
|
||||
const KConfigGroup globalConfig(KSharedConfig::openConfig(), "PreviewSettings");
|
||||
const QStringList plugins = globalConfig.readEntry("Plugins", KIO::PreviewJob::defaultPlugins());
|
||||
KIO::PreviewJob* job = new KIO::PreviewJob(KFileItemList() << m_item,
|
||||
QSize(256, 256),
|
||||
&plugins);
|
||||
|
|
Loading…
Reference in a new issue