From 20b3de56573b9e86c6b6041faf684adc8cbb2a45 Mon Sep 17 00:00:00 2001 From: mickeyl Date: Sat, 29 Jan 2005 14:23:27 +0000 Subject: examples to where they belong --- (limited to 'libopie2/examples/opiecore/oplugins/oplugins.cpp') diff --git a/libopie2/examples/opiecore/oplugins/oplugins.cpp b/libopie2/examples/opiecore/oplugins/oplugins.cpp deleted file mode 100644 index 26623be..0000000 --- a/libopie2/examples/opiecore/oplugins/oplugins.cpp +++ b/dev/null @@ -1,47 +0,0 @@ -/* - * You may copy, modify and or distribute without any limitation - */ -#include -#include - -#include - -using Opie::Core::OPluginItem; -using Opie::Core::OGenericPluginLoader; -using Opie::Core::OPluginLoader; - -void debugLst( const OPluginItem::List& lst ) { - for ( OPluginItem::List::ConstIterator it = lst.begin(); it != lst.end(); ++it ) - odebug << "Name " << (*it).name() << " " << (*it).path() << " " << (*it).position() << oendl; -} - - -int main( void ) { - OGenericPluginLoader loader( "today", true ); - loader.setAutoDelete( true ); - - odebug << "IS in Safe Mode" << loader.isInSafeMode() << oendl; - - OPluginItem::List lst = loader.allAvailable( true ); - debugLst( lst ); - - lst = loader.filtered( true ); - debugLst( lst ); - - for ( OPluginItem::List::Iterator it = lst.begin(); it != lst.end(); ++it ) { - QUnknownInterface* iface = loader.load( *it, IID_TodayPluginInterface ); - } - - OPluginLoader loader2("today",true); - OPluginItem::List lst2 = loader2.allAvailable( true ); - debugLst( lst2 ); - - for( OPluginItem::List::Iterator it = lst.begin(); it != lst.end(); ++it ){ - TodayPluginInterface* iface = loader2.load( *it, IID_TodayPluginInterface ); - } - - - /* - * now it's autodelete so cleaned up for us - */ -} -- cgit v0.9.0.2