[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdelibs/kdecore/kernel
From:       David Faure <faure () kde ! org>
Date:       2007-03-13 0:08:10
Message-ID: 1173744490.912254.7854.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 641979 by dfaure:

Don't define a class with implicit ctor/dtor/etc. - it's just a namespace.
Fix triggered by krazy's "missing d pointer" complaint.


 M  +1 -6      kauthorized.cpp  
 M  +8 -10     kauthorized.h  


--- trunk/KDE/kdelibs/kdecore/kernel/kauthorized.cpp #641978:641979
@@ -18,7 +18,6 @@
     Boston, MA 02110-1301, USA.
         */
 
-#include "config.h"
 #include "kauthorized.h"
 
 #include <qdir.h>
@@ -37,17 +36,13 @@
 #include <kurl.h>
 #include <kconfiggroup.h>
 
-#ifdef HAVE_PATHS_H
-//#include <paths.h>
-#endif
-
 #include <QMutex>
 #include <QMutexLocker>
 #include <qglobal.h>
+
 #ifdef __GNUC__
 #warning used non public api for now
 #endif
-
 extern bool kde_kiosk_exception;
 
 
--- trunk/KDE/kdelibs/kdecore/kernel/kauthorized.h #641978:641979
@@ -30,17 +30,15 @@
 /**
 * Extracted from kapplication (3.x). Kiosk authorization framework
 */
-class KDECORE_EXPORT KAuthorized
+namespace KAuthorized
 {
-public:
-
   /**
    * Returns whether a certain action is authorized
    * @param genericAction The name of a generic  action
    * @return true if the action is authorized
    * @todo what are the generic actions?
    */
-  static bool authorize(const QString& genericAction);
+  KDE_EXPORT bool authorize(const QString& genericAction);
 
   /**
    * Returns whether a certain KAction is authorized.
@@ -49,7 +47,7 @@
    * with "action/" before being passed to authorize()
    * @return true if the KAction is authorized
    */
-  static bool authorizeKAction(const QString& action);
+  KDE_EXPORT bool authorizeKAction(const QString& action);
 
   /**
    * Returns whether a certain URL related action is authorized.
@@ -63,7 +61,7 @@
    * @param destUrl The object of the action
    * @return true when the action is authorized, false otherwise.
    */
-  static bool authorizeUrlAction(const QString& action, const KUrl& baseUrl, const KUrl& destUrl);
+  KDE_EXPORT bool authorizeUrlAction(const QString& action, const KUrl& baseUrl, const KUrl& destUrl);
 
   /**
    * Allow a certain URL action. This can be useful if your application
@@ -73,7 +71,7 @@
    * @param baseUrl The url where the action originates from
    * @param _destUrl The object of the action
    */
-  static void allowUrlAction(const QString& action, const KUrl& baseUrl, const KUrl&  _destUrl);
+  KDE_EXPORT void allowUrlAction(const QString& action, const KUrl& baseUrl, const KUrl&  _destUrl);
 
   /**
    * Returns whether access to a certain control module is authorized.
@@ -81,7 +79,7 @@
    * @param menuId identifying the control module, e.g. kde-mouse.desktop
    * @return true if access to the module is authorized, false otherwise.
    */
-  static bool authorizeControlModule(const QString& menuId);
+  KDE_EXPORT bool authorizeControlModule(const QString& menuId);
 
   /**
    * Returns whether access to a certain control modules is authorized.
@@ -90,8 +88,8 @@
    * an example of a menu-id is kde-mouse.desktop.
    * @return Those control modules for which access has been authorized.
    */
-  static QStringList authorizeControlModules(const QStringList& menuIds);
+  KDE_EXPORT QStringList authorizeControlModules(const QStringList& menuIds);
 
-};
+}
 
 #endif
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic