Classes | |
class | KCMultiDialog |
class | TDECModuleContainer |
class | TDECModuleInfo |
class | TDECModuleLoader |
class | TDECModuleProxy |
class | TDECModuleProxyIface |
class | TDECModuleProxyRootDispatcher |
Macros | |
#define | KCMODULECONTAINER(modules, factoryName) |
Detailed Description
Thwse classes provide the KControl module API.
Macro Definition Documentation
◆ KCMODULECONTAINER
#define KCMODULECONTAINER | ( | modules, | |
factoryName | |||
) |
Value:
extern "C" \
{ \
TDECModule *create_## factoryName(TQWidget *parent, const char *name) \
{ \
return new TDECModuleContainer( parent, name, TQString( modules ) ); \
} \
\
bool test_## factoryName() \
{ \
TQStringList modList = TQStringList::split( ",", TQString(modules).remove( " " )); \
for ( TQStringList::Iterator it = modList.begin(); it != modList.end(); ++it ) \
{ \
if ( TDECModuleLoader::testModule( *it ) ) \
{ \
return true; \
} \
} \
return false; \
} \
}
TDECModuleContainer is a convenience class encapsulating several TDECModules.
Definition: tdecmodulecontainer.h:54
static bool testModule(const TQString &module)
Checks whether an TDECModule should be shown by running its test function.
Definition: tdecmoduleloader.cpp:230
This macro creates an factory declaration which when run creates an TDECModule with specified modules.
For example:
KCMODULECONTAINER( "kcm_fonts, kcm_keyboard,kcm_fonts", misc_modules)
#define KCMODULECONTAINER(modules, factoryName)
This macro creates an factory declaration which when run creates an TDECModule with specified modules...
Definition: tdecmodulecontainer.h:194
would create a TDECModule with three tabs, each containing one of the specified KCMs. Each use of the macro must be accompanied by a desktop file where the factory name equals the second argument in the macro(in this example, misc_modules).
The module container takes care of testing the contained modules when being shown, as well as when the module itself is asked whether it should be shown.
- Parameters
-
modules the modules to put in the container factoryName what factory name the module should have
Definition at line 194 of file tdecmodulecontainer.h.