summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opienet/omanufacturerdb.cpp15
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
@@ -27,23 +27,26 @@
27 Boston, MA 02111-1307, USA. 27 Boston, MA 02111-1307, USA.
28 28
29*/ 29*/
30 30
31#include "omanufacturerdb.h" 31#include "omanufacturerdb.h"
32 32
33/* OPIE CORE */ 33#define OPIE_IMPROVE_GUI_LATENCY 1
34
35/* OPIE */
34#include <opie2/odebug.h> 36#include <opie2/odebug.h>
37#ifdef OPIE_IMPROVE_GUI_LATENCY
38#include <qpe/global.h>
39#endif
35 40
36/* QT */ 41/* QT */
37#include <qapplication.h> 42#include <qapplication.h>
38#include <qstring.h> 43#include <qstring.h>
39#include <qfile.h> 44#include <qfile.h>
40#include <qtextstream.h> 45#include <qtextstream.h>
41 46
42#define OPIE_IMPROVE_GUI_LATENCY 1
43
44OManufacturerDB* OManufacturerDB::_instance = 0; 47OManufacturerDB* OManufacturerDB::_instance = 0;
45 48
46OManufacturerDB* OManufacturerDB::instance() 49OManufacturerDB* OManufacturerDB::instance()
47{ 50{
48 if ( !OManufacturerDB::_instance ) 51 if ( !OManufacturerDB::_instance )
49 { 52 {
@@ -53,12 +56,15 @@ OManufacturerDB* OManufacturerDB::instance()
53 return _instance; 56 return _instance;
54} 57}
55 58
56 59
57OManufacturerDB::OManufacturerDB() 60OManufacturerDB::OManufacturerDB()
58{ 61{
62 #ifdef OPIE_IMPROVE_GUI_LATENCY
63 Global::statusMessage( "Reading Manufacturers..." );
64 #endif
59 QString filename( "/etc/manufacturers" ); 65 QString filename( "/etc/manufacturers" );
60 odebug << "OManufacturerDB: trying to read " << filename << oendl; 66 odebug << "OManufacturerDB: trying to read " << filename << oendl;
61 if ( !QFile::exists( filename ) ) 67 if ( !QFile::exists( filename ) )
62 { 68 {
63 filename = "/opt/QtPalmtop/etc/manufacturers"; 69 filename = "/opt/QtPalmtop/etc/manufacturers";
64 odebug << "OManufacturerDB: trying to read " << filename << oendl; 70 odebug << "OManufacturerDB: trying to read " << filename << oendl;
@@ -101,12 +107,15 @@ OManufacturerDB::OManufacturerDB()
101 qApp->processEvents(); 107 qApp->processEvents();
102 counter = 0; 108 counter = 0;
103 } 109 }
104 #endif 110 #endif
105 } 111 }
106 odebug << "OManufacturerDB: manufacturer list completed." << oendl; 112 odebug << "OManufacturerDB: manufacturer list completed." << oendl;
113 #ifdef OPIE_IMPROVE_GUI_LATENCY
114 Global::statusMessage( "Manufacturers Complete..." );
115 #endif
107 } 116 }
108} 117}
109 118
110 119
111OManufacturerDB::~OManufacturerDB() 120OManufacturerDB::~OManufacturerDB()
112{ 121{