kcmultidialog.h
/*
Copyright (c) 2000 Matthias Elter <elter@kde.org>
Copyright (c) 2003 Daniel Molkentin <molkentin@kde.org>
Copyright (c) 2003 Matthias Kretz <kretz@kde.org>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public License
along with this library; see the file COPYING.LIB. If not, write to
the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA.
*/
#ifndef KCMULTIDIALOG_H
#define KCMULTIDIALOG_H
#include <qptrdict.h>
#include <kdialogbase.h>
#include <klocale.h>
#include <kservice.h>
class KCModuleProxy;
class KCModuleInfo;
class KUTILS_EXPORT KCMultiDialog : public KDialogBase
{
Q_OBJECT
public:
KCMultiDialog( QWidget *parent=0, const char *name=0, bool modal=false );
KCMultiDialog( int dialogFace, const QString & caption, QWidget * parent = 0,
const char * name = 0, bool modal = false );
KCMultiDialog( int dialogFace, const KGuiItem &user2,
const KGuiItem &user3=KGuiItem(), int buttonMask=User2,
const QString &caption=i18n("Configure"), QWidget *parent=0,
const char *name=0, bool modal=false ) KDE_DEPRECATED;
// KDE4 remove the user3 argument, and instead initialize it to KStdGuiItem::adminMode.
virtual ~KCMultiDialog();
void addModule(const QString& module, bool withfallback=true);
void addModule(const KCModuleInfo& moduleinfo, QStringList
parentmodulenames = QStringList(), bool withfallback=false);
void removeAllModules();
void show();
signals:
void configCommitted();
void configCommitted( const QCString & instanceName );
protected slots:
virtual void slotDefault();
virtual void slotUser1();
virtual void slotApply();
virtual void slotOk();
virtual void slotHelp();
private slots:
void slotAboutToShow(QWidget *);
void clientChanged(bool state);
void disableRModeButton();
void rootExit();
void dialogClosed();
private:
void init();
void apply();
struct CreatedModule
{
KCModuleProxy * kcm;
KService::Ptr service;
/* KDE 4 Move to Private class */
};
typedef QValueList<CreatedModule> ModuleList;
ModuleList m_modules;
typedef QMap<KService::Ptr, KCModuleProxy*> OrphanMap;
OrphanMap m_orphanModules;
QPtrDict<QStringList> moduleParentComponents;
QString _docPath;
int dialogface;
class KCMultiDialogPrivate;
KCMultiDialogPrivate *d;
};
#endif //KCMULTIDIALOG_H
// vim: sw=4 sts=4 et
klocale.h
KDialogBase
KGuiItem
KCModuleInfo
A class that provides information about a KCModule.
Definition: kcmoduleinfo.h:49
KCModuleProxy
Encapsulates a KCModule for embedding.
Definition: kcmoduleproxy.h:68
KCMultiDialog
A method that offers a KDialogBase containing arbitrary KControl Modules.
Definition: kcmultidialog.h:43

KDE Home | KDE Accessibility Home | Description of Access Keys