author | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
---|---|---|
committer | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
commit | a08aff328d4393031d5ba7d622c2b05705a89d73 (patch) (unidiff) | |
tree | 8ee90d686081c52e7c69b5ce946e9b1a7d690001 /kabc/plugins/file | |
parent | 11edc920afe4f274c0964436633aa632c8288a40 (diff) | |
download | kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.zip kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.tar.gz kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.tar.bz2 |
initial public commit of qt4 portp1
-rw-r--r-- | kabc/plugins/file/file.pro | 14 | ||||
-rw-r--r-- | kabc/plugins/file/fileE.pro | 4 | ||||
-rw-r--r-- | kabc/plugins/file/resourcefile.cpp | 10 | ||||
-rw-r--r-- | kabc/plugins/file/resourcefileconfig.cpp | 4 |
4 files changed, 19 insertions, 13 deletions
diff --git a/kabc/plugins/file/file.pro b/kabc/plugins/file/file.pro index 2d17313..e4f1270 100644 --- a/kabc/plugins/file/file.pro +++ b/kabc/plugins/file/file.pro | |||
@@ -4,11 +4,11 @@ CONFIG += qt warn_on release | |||
4 | 4 | ||
5 | include( ../../../variables.pri ) | 5 | include( ../../../variables.pri ) |
6 | 6 | ||
7 | TARGET = microkabc_file | 7 | TARGET = xmicrokabc_file |
8 | INCLUDEPATH += ../.. ../../../microkde ../../../microkde/kdecore ../../../microkde/kio/kfile ../../../microkde/kio/kio ../../../microkde/kresources ../../../qtcompat | 8 | INCLUDEPATH += ../.. ../../../microkde ../../../microkde/kdecore ../../../microkde/kio/kfile ../../../microkde/kio/kio ../../../microkde/kresources ../../../qtcompat |
9 | 9 | ||
10 | DESTDIR = ../../../bin | 10 | DESTDIR = ../../../bin |
11 | #LIBS += -lmicrokde -lmicrokabc | 11 | #LIBS += -lxmicrokde -lxmicrokabc |
12 | #LIBS += -L$(QPEDIR)/lib | 12 | #LIBS += -L$(QPEDIR)/lib |
13 | 13 | ||
14 | INTERFACES = \ | 14 | INTERFACES = \ |
@@ -30,8 +30,12 @@ CONFIG += dll | |||
30 | DEFINES += _WIN32_ | 30 | DEFINES += _WIN32_ |
31 | OBJECTS_DIR = obj/win | 31 | OBJECTS_DIR = obj/win |
32 | MOC_DIR = moc/win | 32 | MOC_DIR = moc/win |
33 | LIBS += ../../../bin/microkdepim.lib | 33 | LIBS += ../../../bin/xmicrokdepim.lib |
34 | LIBS += ../../../bin/microkcal.lib | 34 | LIBS += ../../../bin/xmicrokcal.lib |
35 | LIBS += ../../../bin/microkde.lib | 35 | LIBS += ../../../bin/xmicrokde.lib |
36 | LIBS += ../../../bin/microkabc.lib | 36 | LIBS += ../../../bin/microkabc.lib |
37 | } | 37 | } |
38 | #The following line was inserted by qt3to4 | ||
39 | QT += qt3support | ||
40 | #The following line was inserted by qt3to4 | ||
41 | QT += xml | ||
diff --git a/kabc/plugins/file/fileE.pro b/kabc/plugins/file/fileE.pro index 16707e5..5044cd9 100644 --- a/kabc/plugins/file/fileE.pro +++ b/kabc/plugins/file/fileE.pro | |||
@@ -2,12 +2,12 @@ TEMPLATE = lib | |||
2 | CONFIG += qt warn_on release | 2 | CONFIG += qt warn_on release |
3 | #release debug | 3 | #release debug |
4 | 4 | ||
5 | TARGET = microkabc_file | 5 | TARGET = xmicrokabc_file |
6 | INCLUDEPATH += $(KDEPIMDIR)/kabc $(KDEPIMDIR)/microkde $(KDEPIMDIR)/microkde/kdecore $(KDEPIMDIR)/microkde/kio/kfile $(KDEPIMDIR)/microkde/kio/kio $(KDEPIMDIR)/microkde/kresources $(KDEPIMDIR)/qtcompat | 6 | INCLUDEPATH += $(KDEPIMDIR)/kabc $(KDEPIMDIR)/microkde $(KDEPIMDIR)/microkde/kdecore $(KDEPIMDIR)/microkde/kio/kfile $(KDEPIMDIR)/microkde/kio/kio $(KDEPIMDIR)/microkde/kresources $(KDEPIMDIR)/qtcompat |
7 | OBJECTS_DIR = obj/$(PLATFORM) | 7 | OBJECTS_DIR = obj/$(PLATFORM) |
8 | MOC_DIR = moc/$(PLATFORM) | 8 | MOC_DIR = moc/$(PLATFORM) |
9 | DESTDIR = $(QPEDIR)/lib | 9 | DESTDIR = $(QPEDIR)/lib |
10 | LIBS += -lmicrokde -lmicrokabc | 10 | LIBS += -lxmicrokde -lxmicrokabc |
11 | LIBS += -L$(QPEDIR)/lib | 11 | LIBS += -L$(QPEDIR)/lib |
12 | 12 | ||
13 | INTERFACES = \ | 13 | INTERFACES = \ |
diff --git a/kabc/plugins/file/resourcefile.cpp b/kabc/plugins/file/resourcefile.cpp index dad4571..3ed850c 100644 --- a/kabc/plugins/file/resourcefile.cpp +++ b/kabc/plugins/file/resourcefile.cpp | |||
@@ -201,13 +201,13 @@ bool ResourceFile::doOpen() | |||
201 | 201 | ||
202 | if ( !file.exists() ) { | 202 | if ( !file.exists() ) { |
203 | // try to create the file | 203 | // try to create the file |
204 | bool ok = file.open( IO_WriteOnly ); | 204 | bool ok = file.open( QIODevice::WriteOnly ); |
205 | if ( ok ) | 205 | if ( ok ) |
206 | file.close(); | 206 | file.close(); |
207 | 207 | ||
208 | return ok; | 208 | return ok; |
209 | } else { | 209 | } else { |
210 | if ( !file.open( IO_ReadWrite ) ) | 210 | if ( !file.open( QIODevice::ReadWrite ) ) |
211 | return false; | 211 | return false; |
212 | 212 | ||
213 | if ( file.size() < 10 ) { | 213 | if ( file.size() < 10 ) { |
@@ -230,7 +230,7 @@ bool ResourceFile::load() | |||
230 | { | 230 | { |
231 | 231 | ||
232 | QFile file( fileName() ); | 232 | QFile file( fileName() ); |
233 | if ( !file.open( IO_ReadOnly ) ) { | 233 | if ( !file.open( QIODevice::ReadOnly ) ) { |
234 | addressBook()->error( i18n( "Unable to open file '%1'." ).arg( fileName() ) ); | 234 | addressBook()->error( i18n( "Unable to open file '%1'." ).arg( fileName() ) ); |
235 | return false; | 235 | return false; |
236 | } | 236 | } |
@@ -311,7 +311,7 @@ bool ResourceFile::save( Ticket *ticket ) | |||
311 | } | 311 | } |
312 | QFile info; | 312 | QFile info; |
313 | info.setName( fileName() ); | 313 | info.setName( fileName() ); |
314 | bool ok = info.open( IO_WriteOnly ); | 314 | bool ok = info.open( QIODevice::WriteOnly ); |
315 | if ( ok ) { | 315 | if ( ok ) { |
316 | mFormat->saveAll( addressBook(), this, &info ); | 316 | mFormat->saveAll( addressBook(), this, &info ); |
317 | 317 | ||
@@ -363,7 +363,7 @@ bool ResourceFile::lock( const QString &fileName ) | |||
363 | 363 | ||
364 | // Create unique file | 364 | // Create unique file |
365 | QFile file( mLockUniqueName ); | 365 | QFile file( mLockUniqueName ); |
366 | file.open( IO_WriteOnly ); | 366 | file.open( QIODevice::WriteOnly ); |
367 | file.close(); | 367 | file.close(); |
368 | 368 | ||
369 | // Create lock file | 369 | // Create lock file |
diff --git a/kabc/plugins/file/resourcefileconfig.cpp b/kabc/plugins/file/resourcefileconfig.cpp index b63775d..70b0bac 100644 --- a/kabc/plugins/file/resourcefileconfig.cpp +++ b/kabc/plugins/file/resourcefileconfig.cpp | |||
@@ -28,6 +28,8 @@ $Id$ | |||
28 | #include <qlabel.h> | 28 | #include <qlabel.h> |
29 | #include <qlayout.h> | 29 | #include <qlayout.h> |
30 | #include <qfileinfo.h> | 30 | #include <qfileinfo.h> |
31 | //Added by qt3to4: | ||
32 | #include <Q3GridLayout> | ||
31 | 33 | ||
32 | #include <kdebug.h> | 34 | #include <kdebug.h> |
33 | #include <klocale.h> | 35 | #include <klocale.h> |
@@ -50,7 +52,7 @@ ResourceFileConfig::ResourceFileConfig( QWidget* parent, const char* name ) | |||
50 | { | 52 | { |
51 | //qDebug("ResourceFileConfig::ResourceFileConfig"); | 53 | //qDebug("ResourceFileConfig::ResourceFileConfig"); |
52 | 54 | ||
53 | QGridLayout *mainLayout = new QGridLayout( this, 2, 2, 0, | 55 | Q3GridLayout *mainLayout = new Q3GridLayout( this, 2, 2, 0, |
54 | KDialog::spacingHint() ); | 56 | KDialog::spacingHint() ); |
55 | 57 | ||
56 | QLabel *label = new QLabel( i18n( "Format:" ), this ); | 58 | QLabel *label = new QLabel( i18n( "Format:" ), this ); |