-rw-r--r-- | libopie/oapplicationfactory.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libopie/oapplicationfactory.h b/libopie/oapplicationfactory.h index 418a82e..ab88d80 100644 --- a/libopie/oapplicationfactory.h +++ b/libopie/oapplicationfactory.h @@ -217,32 +217,34 @@ struct OApplicationFactory< Opie::Typelist<Product, ProductListTail > > } QStringList applications()const { QStringList _list; return OPrivate< Opie::Typelist<Product, ProductListTail> >::multiString( _list ); } Q_REFCOUNT }; /* If the library version should be build */ #ifdef OPIE_APP_INTERFACE #define OPIE_EXPORT_APP( factory ) Q_EXPORT_INTERFACE() { Q_CREATE_INSTANCE( factory ) } #else +#include <qpe/qpeapplication.h> + #define OPIE_EXPORT_APP( Factory ) \ int main( int argc, char **argv ) { \ QPEApplication a(argc, argv ); \ QWidget *mw = 0;\ \ /* method from TT */ \ QString executableName = QString::fromLatin1( argv[0] ); \ executableName = executableName.right(executableName.length() \ - executableName.findRev('/') - 1); \ \ Factory f; \ QStringList list = f.applications(); \ if (list.contains(executableName) ) \ mw = f.createMainWindow(executableName, 0, 0, 0 ); \ else \ mw = f.createMainWindow( list[0], 0, 0, 0 ); \ |