author | zecke <zecke> | 2004-10-16 00:01:01 (UTC) |
---|---|---|
committer | zecke <zecke> | 2004-10-16 00:01:01 (UTC) |
commit | df14f647ff1a60ca82e0fa9bd91458be146153b8 (patch) (side-by-side diff) | |
tree | 4859961352851a4392e1442f2080c15bff8ad7bc /x11 | |
parent | 419f9710c488f56a7a117eb1529970d3371e0094 (diff) | |
download | opie-df14f647ff1a60ca82e0fa9bd91458be146153b8.zip opie-df14f647ff1a60ca82e0fa9bd91458be146153b8.tar.gz opie-df14f647ff1a60ca82e0fa9bd91458be146153b8.tar.bz2 |
Replace QPEApplication::qpeDir() + "/ with
QPEApplication::qpeDir() + "
as it is guranteed that qpeDir() will have '/' as the last
charachter
-rw-r--r-- | x11/libqpe-x11/qpe/qpeapplication.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/x11/libqpe-x11/qpe/qpeapplication.cpp b/x11/libqpe-x11/qpe/qpeapplication.cpp index 3cb8faf..73e7ce4 100644 --- a/x11/libqpe-x11/qpe/qpeapplication.cpp +++ b/x11/libqpe-x11/qpe/qpeapplication.cpp @@ -79,150 +79,150 @@ public: bool notbusysent : 1; bool preloaded : 1; bool forceshow : 1; bool nomaximize : 1; bool keep_running : 1; QWidget* presswidget; QPoint presspos; QWidget* qpe_main_widget; QString appName; QString styleName; QString decorationName; Atom wm_delete_window; Atom wm_take_focus; Atom wm_context_help; Atom wm_context_accept; Atom wm_protocols; private: QList<QCopRec> qcopq; }; QPEApplication::Private::~Private() { } QPEApplication::Private::Private() : kbgrabber(0 ), presstimer(0 ), rightpressed( FALSE ), kbregrab( FALSE ), notbusysent( FALSE ), preloaded( FALSE ), forceshow( FALSE ), nomaximize( FALSE ), keep_running( TRUE ), presswidget( 0 ), qpe_main_widget(0 ) { qcopq.setAutoDelete( TRUE ); } void QPEApplication::Private::enqueueQCop( const QCString& chan, const QCString& msg, const QByteArray& ar ) { qcopq.append( new QCopRec(chan, msg, ar ) ); } void QPEApplication::Private::sendQCopQ() { QCopRec* r; for ( r = qcopq.first(); r; r = qcopq.next() ) { QCopChannel::sendLocally( r->channel, r->message, r->data ); } qcopq.clear(); } void QPEApplication::Private::show_mx(QWidget* mw, bool nomaximize ) { if (mw->layout() && mw->inherits("QDialog") ) { QPEApplication::showDialog( (QDialog*)mw, nomaximize ); }else { if (!nomaximize ) mw->showMaximized(); else mw->show(); } } void QPEApplication::Private::show( QWidget* mw, bool nomax ) { nomaximize = nomax; qpe_main_widget = mw; sendQCopQ(); if ( preloaded ) { if (forceshow ) show_mx(mw, nomax ); }else if ( keep_running ) show_mx( mw, nomax ); } void QPEApplication::Private::loadTextCodecs() { - QString path = QPEApplication::qpeDir() + "/plugins/textcodecs"; + QString path = QPEApplication::qpeDir() + "plugins/textcodecs"; QDir dir( path, "lib*.so" ); QStringList list = dir.entryList(); QStringList::Iterator it; for ( it = list.begin(); it != list.end(); ++it ) { TextCodecInterface *iface = 0; QLibrary *lib = new QLibrary( path + "/" + *it ); if ( lib->queryInterface( IID_QtopiaTextCodec, (QUnknownInterface**)&iface ) == QS_OK && iface ) { QValueList<int> mibs = iface->mibEnums(); for (QValueList<int>::ConstIterator i = mibs.begin(); i != mibs.end(); ++i) { (void)iface->createForMib(*i); // ### it exists now; need to remember if we can delete it } } else { lib->unload(); delete lib; } } } void QPEApplication::Private::loadImageCodecs() { - QString path = QPEApplication::qpeDir() + "/plugins/imagecodecs"; + QString path = QPEApplication::qpeDir() + "plugins/imagecodecs"; QDir dir( path, "lib*.so" ); QStringList list = dir.entryList(); QStringList::Iterator it; for ( it = list.begin(); it != list.end(); ++it ) { ImageCodecInterface *iface = 0; QLibrary *lib = new QLibrary( path + "/" + *it ); if ( lib->queryInterface( IID_QtopiaImageCodec, (QUnknownInterface**)&iface ) == QS_OK && iface ) { QStringList formats = iface->keys(); for (QStringList::ConstIterator i = formats.begin(); i != formats.end(); ++i) { (void)iface->installIOHandler(*i); // ### it exists now; need to remember if we can delete it } } else { lib->unload(); delete lib; } } } // The Help System hook namespace { class ResourceMimeFactory : public QMimeSourceFactory { public: ResourceMimeFactory(); ~ResourceMimeFactory(); const QMimeSource* data( const QString& abs_name )const; }; ResourceMimeFactory::ResourceMimeFactory() { setFilePath( Global::helpPath() ); setExtensionType( "html", "text/html;charset=UTF-8" ); } ResourceMimeFactory::~ResourceMimeFactory() { } const QMimeSource* ResourceMimeFactory::data( const QString& abs_name ) const { const QMimeSource * r = QMimeSourceFactory::data( abs_name ); if ( !r ) { int sl = abs_name.length(); do { sl = abs_name.findRev( '/', sl - 1 ); QString name = sl >= 0 ? abs_name.mid( sl + 1 ) : abs_name; int dot = name.findRev( '.' ); if ( dot >= 0 ) name = name.left( dot ); QImage img = Resource::loadImage( name ); if ( !img.isNull() ) r = new QImageDrag( img ); } while ( !r && sl > 0 ); } return r; }; }; // QPEApplication QPEApplication::~QPEApplication() { qWarning("~QPEApplication"); ungrabKeyboard(); qWarning("UngrabKeyboard"); // delete m_sys; |