-rw-r--r-- | libopie2/opienet/omanufacturerdb.cpp | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/libopie2/opienet/omanufacturerdb.cpp b/libopie2/opienet/omanufacturerdb.cpp index f61270b..2da549c 100644 --- a/libopie2/opienet/omanufacturerdb.cpp +++ b/libopie2/opienet/omanufacturerdb.cpp @@ -25,42 +25,48 @@ If not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include "omanufacturerdb.h" -/* OPIE CORE */ +#define OPIE_IMPROVE_GUI_LATENCY 1 + +/* OPIE */ #include <opie2/odebug.h> +#ifdef OPIE_IMPROVE_GUI_LATENCY +#include <qpe/global.h> +#endif /* QT */ #include <qapplication.h> #include <qstring.h> #include <qfile.h> #include <qtextstream.h> -#define OPIE_IMPROVE_GUI_LATENCY 1 - OManufacturerDB* OManufacturerDB::_instance = 0; OManufacturerDB* OManufacturerDB::instance() { if ( !OManufacturerDB::_instance ) { odebug << "OManufacturerDB::instance(): creating OManufacturerDB..." << oendl; _instance = new OManufacturerDB(); } return _instance; } OManufacturerDB::OManufacturerDB() { + #ifdef OPIE_IMPROVE_GUI_LATENCY + Global::statusMessage( "Reading Manufacturers..." ); + #endif QString filename( "/etc/manufacturers" ); odebug << "OManufacturerDB: trying to read " << filename << oendl; if ( !QFile::exists( filename ) ) { filename = "/opt/QtPalmtop/etc/manufacturers"; odebug << "OManufacturerDB: trying to read " << filename << oendl; if ( !QFile::exists( filename ) ) { @@ -99,16 +105,19 @@ OManufacturerDB::OManufacturerDB() if ( counter == 50 ) { qApp->processEvents(); counter = 0; } #endif } odebug << "OManufacturerDB: manufacturer list completed." << oendl; + #ifdef OPIE_IMPROVE_GUI_LATENCY + Global::statusMessage( "Manufacturers Complete..." ); + #endif } } OManufacturerDB::~OManufacturerDB() { } |