• Skip to content
  • Skip to link menu
KDE 4.3 API Reference
  • KDE API Reference
  • kdelibs
  • Sitemap
  • Contact Us
 

KUtils

KCModuleLoader Namespace Reference

Loads a KControl Module. More...

Enumerations

enum  ErrorReporting { None = 0, Inline = 1, Dialog = 2, Both = 3 }

Functions

KCModule * loadModule (const QString &module, ErrorReporting report, QWidget *parent=0, const QStringList &args=QStringList())
KCModule * loadModule (const KCModuleInfo &module, ErrorReporting report, QWidget *parent=0, const QStringList &args=QStringList())
KCModule * reportError (ErrorReporting report, const QString &text, const QString &details, QWidget *parent)
KDE_DEPRECATED void showLastLoaderError (QWidget *parent)
void unloadModule (const KCModuleInfo &mod)

Detailed Description

Loads a KControl Module.

KCModuleLoader tries in several ways to locate and load a KCModule. If loading fails a zero pointer is returned.
It is very unlikely KCModuleLoader is what you want and KCModuleProxy suits your needs.

Author:
Matthias Hoelzer-Kluepfel <mhk@kde.org>
Frans Englich <frans.englich@telia.com>

For internal use only.


Enumeration Type Documentation

enum KCModuleLoader::ErrorReporting

Determines the way errors are reported.

Enumerator:
None 

no error reporting is done

Inline 

the error report is shown instead of the KCModule that should have * been loaded

Dialog 

shows a dialog with the error report

Both 

does both Inline and Dialog

Definition at line 48 of file kcmoduleloader.h.


Function Documentation

KCModule * KCModuleLoader::loadModule ( const QString &  module,
ErrorReporting  report,
QWidget *  parent = 0,
const QStringList &  args = QStringList() 
)

Loads a KCModule.

If loading fails a zero pointer is returned.

Parameters:
module what module to load
report see ErrorReporting
Returns:
a pointer to the loaded KCModule

Definition at line 60 of file kcmoduleloader.cpp.

KCModule * KCModuleLoader::loadModule ( const KCModuleInfo &  module,
ErrorReporting  report,
QWidget *  parent = 0,
const QStringList &  args = QStringList() 
)

Loads a KCModule.

If loading fails a zero pointer is returned.

Parameters:
module what module to load
report see ErrorReporting
Returns:
a pointer to the loaded KCModule

Definition at line 65 of file kcmoduleloader.cpp.

KCModule * KCModuleLoader::reportError ( ErrorReporting  report,
const QString &  text,
const QString &  details,
QWidget *  parent 
)

Returns a KCModule containing the messages report and text.

Parameters:
report the type of error reporting, see ErrorReporting
text the main message
details any additional details

For internal use only.

Definition at line 162 of file kcmoduleloader.cpp.

void KCModuleLoader::showLastLoaderError ( QWidget *  parent  ) 

Display a message box explaining an error occurred and possible reasons to why.

Deprecated:
Use a constructor with ErrorReporting set to Dialog to show a message box like this function did.

Definition at line 149 of file kcmoduleloader.cpp.

void KCModuleLoader::unloadModule ( const KCModuleInfo &  mod  ) 

Unloads the module's library.

Parameters:
mod What module to unload for

Definition at line 137 of file kcmoduleloader.cpp.

KUtils

Skip menu "KUtils"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.6.1
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal