summaryrefslogtreecommitdiff
path: root/libopie2/opienet/omanufacturerdb.cpp
Unidiff
Diffstat (limited to 'libopie2/opienet/omanufacturerdb.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opienet/omanufacturerdb.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/libopie2/opienet/omanufacturerdb.cpp b/libopie2/opienet/omanufacturerdb.cpp
index 32bae0a..7e185a2 100644
--- a/libopie2/opienet/omanufacturerdb.cpp
+++ b/libopie2/opienet/omanufacturerdb.cpp
@@ -49,49 +49,49 @@ namespace Opie {
49namespace Net { 49namespace Net {
50 50
51OManufacturerDB* OManufacturerDB::_instance = 0; 51OManufacturerDB* OManufacturerDB::_instance = 0;
52 52
53OManufacturerDB* OManufacturerDB::instance() 53OManufacturerDB* OManufacturerDB::instance()
54{ 54{
55 if ( !OManufacturerDB::_instance ) 55 if ( !OManufacturerDB::_instance )
56 { 56 {
57 odebug << "OManufacturerDB::instance(): creating OManufacturerDB..." << oendl; 57 odebug << "OManufacturerDB::instance(): creating OManufacturerDB..." << oendl;
58 _instance = new OManufacturerDB(); 58 _instance = new OManufacturerDB();
59 } 59 }
60 return _instance; 60 return _instance;
61} 61}
62 62
63 63
64OManufacturerDB::OManufacturerDB() 64OManufacturerDB::OManufacturerDB()
65{ 65{
66 #ifdef OPIE_IMPROVE_GUI_LATENCY 66 #ifdef OPIE_IMPROVE_GUI_LATENCY
67 Global::statusMessage( "Reading Manufacturers..." ); 67 Global::statusMessage( "Reading Manufacturers..." );
68 #endif 68 #endif
69 QString filename( "/etc/manufacturers" ); 69 QString filename( "/etc/manufacturers" );
70 odebug << "OManufacturerDB: trying to read " << filename << oendl; 70 odebug << "OManufacturerDB: trying to read " << filename << oendl;
71 if ( !QFile::exists( filename ) ) 71 if ( !QFile::exists( filename ) )
72 { 72 {
73 filename = QPEApplication::qpeDir()+"/etc/manufacturers"; 73 filename = QPEApplication::qpeDir()+"etc/manufacturers";
74 odebug << "OManufacturerDB: trying to read " << filename << oendl; 74 odebug << "OManufacturerDB: trying to read " << filename << oendl;
75 if ( !QFile::exists( filename ) ) 75 if ( !QFile::exists( filename ) )
76 { 76 {
77 filename = "/usr/share/wellenreiter/manufacturers"; 77 filename = "/usr/share/wellenreiter/manufacturers";
78 odebug << "OManufacturerDB: trying to read " << filename << oendl; 78 odebug << "OManufacturerDB: trying to read " << filename << oendl;
79 } 79 }
80 } 80 }
81 81
82 QFile file( filename ); 82 QFile file( filename );
83 bool hasFile = file.open( IO_ReadOnly ); 83 bool hasFile = file.open( IO_ReadOnly );
84 if (!hasFile) 84 if (!hasFile)
85 { 85 {
86 owarn << "OManufacturerDB: no valid manufacturer list found." << oendl; 86 owarn << "OManufacturerDB: no valid manufacturer list found." << oendl;
87 } 87 }
88 else 88 else
89 { 89 {
90 odebug << "OManufacturerDB: found manufacturer list in " << filename << oendl; 90 odebug << "OManufacturerDB: found manufacturer list in " << filename << oendl;
91 QTextStream s( &file ); 91 QTextStream s( &file );
92 QString addr; 92 QString addr;
93 QString manu; 93 QString manu;
94 QString extManu; 94 QString extManu;
95 #ifdef OPIE_IMPROVE_GUI_LATENCY 95 #ifdef OPIE_IMPROVE_GUI_LATENCY
96 int counter = 0; 96 int counter = 0;
97 #endif 97 #endif