From 9b33ff5f74c30a5a4905093715a6f345edee26ab Mon Sep 17 00:00:00 2001 From: zecke Date: Sat, 12 Oct 2002 21:18:46 +0000 Subject: Calmed down... 2nd try after merge Use MetaFactory cuase it's so nice and avoids thousands of if() else if stuff Fix a bug in filetransfer where cancel after exit leaded to a crash cause of bogus adresses in the QSocketNotifiers.. --- (limited to 'noncore/apps/opie-console/metafactory.cpp') diff --git a/noncore/apps/opie-console/metafactory.cpp b/noncore/apps/opie-console/metafactory.cpp index 2b672cf..901f29f 100644 --- a/noncore/apps/opie-console/metafactory.cpp +++ b/noncore/apps/opie-console/metafactory.cpp @@ -126,6 +126,15 @@ EmulationLayer* MetaFactory::newEmulationLayer( const QString& str, WidgetLayer* return lay; } +FileTransferLayer* MetaFactory::newFileTransfer(const QString& str, IOLayer* lay ) { + FileTransferLayer* file = 0l; + QMap::Iterator it; + it = m_fileFact.find( str ); + if ( it != m_fileFact.end() ) { + file = (*(it.data() ) )(lay); + } + return file; +} QCString MetaFactory::internal( const QString& str )const { return m_strings[str]; } -- cgit v0.9.0.2