embedding #ifdef's within macros is not portable

svn path=/trunk/KDE/kdebase/workspace/; revision=740309
icc-effect-5.14.5
Dirk Mueller 2007-11-22 23:28:34 +00:00
parent 97d274b7c3
commit e37fe7d2fb
1 changed files with 25 additions and 14 deletions

View File

@ -34,21 +34,32 @@ License. See the file "COPYING" for the exact licensing terms.
#ifndef KDE_USE_FINAL #ifndef KDE_USE_FINAL
KWIN_EFFECT_CONFIG_FACTORY KWIN_EFFECT_CONFIG_FACTORY
#endif #endif
K_PLUGIN_FACTORY_DEFINITION(EffectFactory,
registerPlugin<KWin::DesktopGridEffectConfig>("desktopgrid"); #define NON_GL_PLUGINS \
registerPlugin<KWin::DimInactiveEffectConfig>("diminactive"); registerPlugin<KWin::DesktopGridEffectConfig>("desktopgrid"); \
registerPlugin<KWin::MakeTransparentEffectConfig>("maketransparent"); registerPlugin<KWin::DimInactiveEffectConfig>("diminactive"); \
registerPlugin<KWin::PresentWindowsEffectConfig>("presentwindows"); registerPlugin<KWin::MakeTransparentEffectConfig>("maketransparent"); \
registerPlugin<KWin::ShadowEffectConfig>("shadow"); registerPlugin<KWin::PresentWindowsEffectConfig>("presentwindows"); \
registerPlugin<KWin::ThumbnailAsideEffectConfig>("thumbnailaside"); registerPlugin<KWin::ShadowEffectConfig>("shadow"); \
registerPlugin<KWin::ThumbnailAsideEffectConfig>("thumbnailaside"); \
registerPlugin<KWin::ZoomEffectConfig>("zoom"); registerPlugin<KWin::ZoomEffectConfig>("zoom");
#define GL_PLUGINS \
registerPlugin<KWin::InvertEffectConfig>("invert"); \
registerPlugin<KWin::LookingGlassEffectConfig>("lookingglass"); \
registerPlugin<KWin::MouseMarkEffectConfig>("mousemark"); \
registerPlugin<KWin::MagnifierEffectConfig>("magnifier"); \
registerPlugin<KWin::SharpenEffectConfig>("sharpen"); \
registerPlugin<KWin::TrackMouseEffectConfig>("trackmouse"); \
#ifdef HAVE_OPENGL #ifdef HAVE_OPENGL
registerPlugin<KWin::InvertEffectConfig>("invert"); K_PLUGIN_FACTORY_DEFINITION(EffectFactory,
registerPlugin<KWin::LookingGlassEffectConfig>("lookingglass"); NON_GL_PLUGINS
registerPlugin<KWin::MouseMarkEffectConfig>("mousemark"); GL_PLUGINS
registerPlugin<KWin::MagnifierEffectConfig>("magnifier");
registerPlugin<KWin::SharpenEffectConfig>("sharpen");
registerPlugin<KWin::TrackMouseEffectConfig>("trackmouse");
#endif
) )
#else
K_PLUGIN_FACTORY_DEFINITION(EffectFactory,
NON_GL_PLUGINS
)
#endif
K_EXPORT_PLUGIN(EffectFactory("kwin")) K_EXPORT_PLUGIN(EffectFactory("kwin"))