-rw-r--r-- | core/launcher/irserver.cpp | 6 | ||||
-rw-r--r-- | core/launcher/launcherview.cpp | 1 |
2 files changed, 3 insertions, 4 deletions
diff --git a/core/launcher/irserver.cpp b/core/launcher/irserver.cpp index 2147d0a..625cb60 100644 --- a/core/launcher/irserver.cpp +++ b/core/launcher/irserver.cpp @@ -1,52 +1,52 @@ #include "irserver.h" #include <qpe/qlibrary.h> #include <qpe/qpeapplication.h> #include <qtranslator.h> #include <stdlib.h> #include "obexinterface.h" #include <qdir.h> IrServer::IrServer( QObject *parent, const char *name ) : QObject( parent, name ) { lib = 0; iface = 0; QString path = QPEApplication::qpeDir() + "/plugins/obex/"; QDir dir( path, "lib*.so" ); QStringList list = dir.entryList(); QStringList::Iterator it; for ( it = list.begin(); it != list.end(); ++it ) { QLibrary *trylib = new QLibrary( path + *it ); - qDebug("trying lib %s", (path + (*it)).latin1() ); + //qDebug("trying lib %s", (path + (*it)).latin1() ); if ( trylib->queryInterface( IID_ObexInterface, (QUnknownInterface**)&iface ) == QS_OK ) { lib = trylib; - qDebug("found obex lib" ); + //qDebug("found obex lib" ); QString lang = getenv( "LANG" ); QTranslator * trans = new QTranslator(qApp); QString type = (*it).left( (*it).find(".") ); QString tfn = QPEApplication::qpeDir()+"/i18n/"+lang+"/"+type+".qm"; - qDebug("tr fpr obex: %s", tfn.latin1() ); + //qDebug("tr fpr obex: %s", tfn.latin1() ); if ( trans->load( tfn )) qApp->installTranslator( trans ); else delete trans; break; } else { delete lib; } } if ( !lib ) qDebug("could not load IR plugin" ); } IrServer::~IrServer() { if ( iface ) iface->release(); delete lib; } diff --git a/core/launcher/launcherview.cpp b/core/launcher/launcherview.cpp index 95a1d4a..7117e0b 100644 --- a/core/launcher/launcherview.cpp +++ b/core/launcher/launcherview.cpp @@ -776,65 +776,64 @@ void LauncherView::setBackgroundType( BackgroundType t, const QString &val ) bg.resize( width(), 9 ); QPainter painter( &bg ); for ( int i = 0; i < 3; i++ ) { painter.setPen( white ); painter.drawLine( 0, i*3, width()-1, i*3 ); painter.drawLine( 0, i*3+1, width()-1, i*3+1 ); painter.setPen( colorGroup().background().light(105) ); painter.drawLine( 0, i*3+2, width()-1, i*3+2 ); } painter.end(); bgCache->insert( bgName, new BgPixmap(bg) ); } icons->setBackgroundPixmap( bg ); break; } case SolidColor: icons->setBackgroundPixmap( QPixmap() ); if ( val.isEmpty() ) { icons->setBackgroundColor( colorGroup().base() ); } else { icons->setBackgroundColor( val ); } bgName = ""; break; case Image: bgName = val; if ( bgCache->contains( bgName ) ) { (*bgCache)[bgName]->ref++; icons->setBackgroundPixmap( (*bgCache)[bgName]->pm ); } else { - qDebug( "Loading image: %s", val.latin1() ); QPixmap bg( Resource::loadPixmap( val ) ); if ( bg.isNull() ) { QImageIO imgio; imgio.setFileName( bgName ); QSize ds = qApp->desktop()->size(); QString param( "Scale( %1, %2, ScaleMin )" ); // No tr imgio.setParameters( param.arg(ds.width()).arg(ds.height()).latin1() ); imgio.read(); bg = imgio.image(); } bgCache->insert( bgName, new BgPixmap(bg) ); icons->setBackgroundPixmap( bg ); } break; } // remove unreferenced backgrounds. QMap<QString,BgPixmap*>::Iterator it = bgCache->begin(); while ( it != bgCache->end() ) { QMap<QString,BgPixmap*>::Iterator curr = it; ++it; if ( (*curr)->ref == 0 ) { delete (*curr); bgCache->remove( curr ); } } bgType = t; icons->viewport()->update(); } void LauncherView::setTextColor( const QColor &tc ) |