File indexing completed on 2022-09-27 16:31:48

0001 /*
0002     SPDX-FileCopyrightText: 1998 Michael Kropfberger <michael.kropfberger@gmx.net>
0003     SPDX-License-Identifier: GPL-2.0-or-later
0004 */
0005 
0006 //
0007 // 1999-12-05 Espen Sand
0008 // Modified to use KCModule instead of the old and obsolete
0009 // KControlApplication
0010 //
0011 
0012 #include "kcmdf.h"
0013 
0014 #include <QVBoxLayout>
0015 #include <KPluginFactory>
0016 #include <kpluginfactory.h>
0017 
0018 K_PLUGIN_CLASS_WITH_JSON(KDiskFreeWidget, "kcmdf.json")
0019 
0020 KDiskFreeWidget::KDiskFreeWidget( QWidget *parent, const QVariantList &args )
0021         : KCModule( parent, args )
0022 {
0023     setButtons(Help);
0024 
0025     QVBoxLayout *topLayout = new QVBoxLayout( this );
0026     topLayout->setContentsMargins({});
0027 
0028     mKdf = new KDFWidget( this, false );
0029     topLayout->addWidget( mKdf );
0030 }
0031 
0032 KDiskFreeWidget::~KDiskFreeWidget()
0033 {
0034     mKdf->applySettings();
0035 }
0036 
0037 QString KDiskFreeWidget::quickHelp() const
0038 {
0039     return i18n("A right mouse button click opens a context menu to mount/unmount a device"
0040                 " or to open it in the file manager.");
0041 }
0042 
0043 #include "kcmdf.moc"