Diffstat (limited to 'noncore/net/wellenreiter/gui/resource.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/net/wellenreiter/gui/resource.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/noncore/net/wellenreiter/gui/resource.cpp b/noncore/net/wellenreiter/gui/resource.cpp index 7683329..a39bbcc 100644 --- a/noncore/net/wellenreiter/gui/resource.cpp +++ b/noncore/net/wellenreiter/gui/resource.cpp @@ -14,12 +14,15 @@ **********************************************************************/ #include "resource.h" #define PIXMAPPATH "/usr/local/share" +#include <qpixmap.h> +#include <qiconset.h> + namespace Resource { QPixmap loadPixmap( const QString& pix ) { QString filename; @@ -29,7 +32,19 @@ QPixmap loadPixmap( const QString& pix ) { qDebug( "Wellenreiter::Resource: can't find pixmap " + filename ); } return pixmap; }; +QIconSet loadIconSet( const QString& pix ) +{ + QString filename; + filename.sprintf( "%s/%s.png", (const char*) PIXMAPPATH, (const char*) pix ); + QPixmap pixmap( filename ); + if ( pixmap.isNull() ) + { + qDebug( "Wellenreiter::Resource: can't find pixmap " + filename ); + } + return QIconSet( pixmap ); +}; + }; |