X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fuisupport%2Factioncollection.cpp;h=b752cfb748960630f59ca804e628511600d9132e;hp=8a5d6067ed34885910b694bdb9973d032d5d4823;hb=e32fd68ac69cada52a65598d4781f1cc735145fc;hpb=ba934ceb1bfe30d01d5fb5c072c3197f8080be04 diff --git a/src/uisupport/actioncollection.cpp b/src/uisupport/actioncollection.cpp index 8a5d6067..b752cfb7 100644 --- a/src/uisupport/actioncollection.cpp +++ b/src/uisupport/actioncollection.cpp @@ -1,5 +1,5 @@ /*************************************************************************** - * Copyright (C) 2005-08 by the Quassel Project * + * Copyright (C) 2005-09 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * @@ -20,6 +20,8 @@ * Parts of this implementation are based on KDE's KActionCollection. * ***************************************************************************/ +#ifndef HAVE_KDE + #include #include @@ -51,6 +53,7 @@ QList ActionCollection::actions() const { Action *ActionCollection::addAction(const QString &name, Action *action) { QAction *act = addAction(name, static_cast(action)); + Q_UNUSED(act); Q_ASSERT(act == action); return action; } @@ -74,7 +77,7 @@ QAction *ActionCollection::addAction(const QString &name, QAction *action) { else action->setObjectName(indexName); if(indexName.isEmpty()) - indexName = QString("unnamed-%1").arg((int)action, 16); + indexName = indexName.sprintf("unnamed-%p", (void *)action); // do we already have this action? if(_actionByName.value(indexName, 0) == action) @@ -225,3 +228,5 @@ bool ActionCollection::unlistAction(QAction *action) { return true; } + +#endif /* HAVE_KDE */