summaryrefslogtreecommitdiff
authorzecke <zecke>2002-10-15 21:42:20 (UTC)
committer zecke <zecke>2002-10-15 21:42:20 (UTC)
commit676be5604cbdb3213c00775e0ff66f4e766f8dcb (patch) (unidiff)
tree63c29adab530a60371f78880ff75e2689398e239
parentb774e015816e51ac65e5d1c685306f8404a3a19e (diff)
downloadopie-676be5604cbdb3213c00775e0ff66f4e766f8dcb.zip
opie-676be5604cbdb3213c00775e0ff66f4e766f8dcb.tar.gz
opie-676be5604cbdb3213c00775e0ff66f4e766f8dcb.tar.bz2
Actually most of them are -+ cause I opened them in xemacs..
The main goal is to replace some header names to let them be overwritten by external once so "qpeapplication.h" is now <qpe/qpeapplication.h> I'll check if it's building on non Qt2/X11 systems...
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--library/alarmserver.cpp4
-rw-r--r--library/backend/vcc.y2
-rw-r--r--library/backend/vcc_yacc.cpp2
-rw-r--r--library/backend/vobject.cpp116
-rw-r--r--library/datebookmonth.cpp14
-rw-r--r--library/fileselector.cpp6
-rw-r--r--library/fontdatabase.cpp2
-rw-r--r--library/fontdatabase.h1
-rw-r--r--library/mimetype.cpp2
-rw-r--r--library/qpedialog.cpp4
-rw-r--r--library/qpestyle.cpp14
-rw-r--r--library/resource.cpp2
-rw-r--r--library/timestring.cpp34
13 files changed, 102 insertions, 101 deletions
diff --git a/library/alarmserver.cpp b/library/alarmserver.cpp
index 1ee05c6..177a0cb 100644
--- a/library/alarmserver.cpp
+++ b/library/alarmserver.cpp
@@ -24,12 +24,12 @@
24#include <qtextstream.h> 24#include <qtextstream.h>
25 25
26 26
27#include "qpeapplication.h" 27#include <qpe/qpeapplication.h>
28#include "global.h" 28#include "global.h"
29#include "resource.h" 29#include "resource.h"
30 30
31#if defined(Q_WS_QWS) && !defined(QT_NO_COP) 31#if defined(Q_WS_QWS) && !defined(QT_NO_COP)
32#include "qcopenvelope_qws.h" 32#include <qpe/qcopenvelope_qws.h>
33#endif 33#endif
34#include "alarmserver.h" 34#include "alarmserver.h"
35#include <qpe/timeconversion.h> 35#include <qpe/timeconversion.h>
diff --git a/library/backend/vcc.y b/library/backend/vcc.y
index 5bcf0cb..6781312 100644
--- a/library/backend/vcc.y
+++ b/library/backend/vcc.y
@@ -122,7 +122,7 @@ DFARS 252.227-7013 or 48 CFR 52.227-19, as applicable.
122//#ifdef PALMTOPCENTER 122//#ifdef PALMTOPCENTER
123//#include <qpe/vobject_p.h> 123//#include <qpe/vobject_p.h>
124//#else 124//#else
125#include "vobject_p.h" 125#include <qtopia/private/vobject_p.h>
126//#endif 126//#endif
127 127
128/**** Types, Constants ****/ 128/**** Types, Constants ****/
diff --git a/library/backend/vcc_yacc.cpp b/library/backend/vcc_yacc.cpp
index 19a108f..b2b0c14 100644
--- a/library/backend/vcc_yacc.cpp
+++ b/library/backend/vcc_yacc.cpp
@@ -158,7 +158,7 @@ DFARS 252.227-7013 or 48 CFR 52.227-19, as applicable.
158/*#ifdef PALMTOPCENTER */ 158/*#ifdef PALMTOPCENTER */
159/*#include <qpe/vobject_p.h> */ 159/*#include <qpe/vobject_p.h> */
160/*#else */ 160/*#else */
161#include "vobject_p.h" 161#include <qtopia/private/vobject_p.h>
162/*#endif */ 162/*#endif */
163 163
164/**** Types, Constants ****/ 164/**** Types, Constants ****/
diff --git a/library/backend/vobject.cpp b/library/backend/vobject.cpp
index e6f6b78..dab128e 100644
--- a/library/backend/vobject.cpp
+++ b/library/backend/vobject.cpp
@@ -1,44 +1,44 @@
1/*************************************************************************** 1/***************************************************************************
2(C) Copyright 1996 Apple Computer, Inc., AT&T Corp., International 2(C) Copyright 1996 Apple Computer, Inc., AT&T Corp., International
3Business Machines Corporation and Siemens Rolm Communications Inc. 3Business Machines Corporation and Siemens Rolm Communications Inc.
4 4
5For purposes of this license notice, the term Licensors shall mean, 5For purposes of this license notice, the term Licensors shall mean,
6collectively, Apple Computer, Inc., AT&T Corp., International 6collectively, Apple Computer, Inc., AT&T Corp., International
7Business Machines Corporation and Siemens Rolm Communications Inc. 7Business Machines Corporation and Siemens Rolm Communications Inc.
8The term Licensor shall mean any of the Licensors. 8The term Licensor shall mean any of the Licensors.
9 9
10Subject to acceptance of the following conditions, permission is hereby 10Subject to acceptance of the following conditions, permission is hereby
11granted by Licensors without the need for written agreement and without 11granted by Licensors without the need for written agreement and without
12license or royalty fees, to use, copy, modify and distribute this 12license or royalty fees, to use, copy, modify and distribute this
13software for any purpose. 13software for any purpose.
14 14
15The above copyright notice and the following four paragraphs must be 15The above copyright notice and the following four paragraphs must be
16reproduced in all copies of this software and any software including 16reproduced in all copies of this software and any software including
17this software. 17this software.
18 18
19THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS AND NO LICENSOR SHALL HAVE 19THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS AND NO LICENSOR SHALL HAVE
20ANY OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS OR 20ANY OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS OR
21MODIFICATIONS. 21MODIFICATIONS.
22 22
23IN NO EVENT SHALL ANY LICENSOR BE LIABLE TO ANY PARTY FOR DIRECT, 23IN NO EVENT SHALL ANY LICENSOR BE LIABLE TO ANY PARTY FOR DIRECT,
24INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES OR LOST PROFITS ARISING OUT 24INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES OR LOST PROFITS ARISING OUT
25OF THE USE OF THIS SOFTWARE EVEN IF ADVISED OF THE POSSIBILITY OF SUCH 25OF THE USE OF THIS SOFTWARE EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
26DAMAGE. 26DAMAGE.
27 27
28EACH LICENSOR SPECIFICALLY DISCLAIMS ANY WARRANTIES, EXPRESS OR IMPLIED, 28EACH LICENSOR SPECIFICALLY DISCLAIMS ANY WARRANTIES, EXPRESS OR IMPLIED,
29INCLUDING BUT NOT LIMITED TO ANY WARRANTY OF NONINFRINGEMENT OR THE 29INCLUDING BUT NOT LIMITED TO ANY WARRANTY OF NONINFRINGEMENT OR THE
30IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 30IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
31PURPOSE. 31PURPOSE.
32 32
33The software is provided with RESTRICTED RIGHTS. Use, duplication, or 33The software is provided with RESTRICTED RIGHTS. Use, duplication, or
34disclosure by the government are subject to restrictions set forth in 34disclosure by the government are subject to restrictions set forth in
35DFARS 252.227-7013 or 48 CFR 52.227-19, as applicable. 35DFARS 252.227-7013 or 48 CFR 52.227-19, as applicable.
36 36
37***************************************************************************/ 37***************************************************************************/
38 38
39/* 39/*
40 * src: vobject.c 40 * src: vobject.c
41 * doc: vobject and APIs to construct vobject, APIs pretty print 41 * doc: vobject and APIs to construct vobject, APIs pretty print
42 * vobject, and convert a vobject into its textual representation. 42 * vobject, and convert a vobject into its textual representation.
43 */ 43 */
44 44
@@ -46,8 +46,8 @@ DFARS 252.227-7013 or 48 CFR 52.227-19, as applicable.
46#include <malloc.h> 46#include <malloc.h>
47#endif 47#endif
48 48
49#include "vobject_p.h" 49#include <qtopia/private/vobject_p.h>
50#include "qfiledirect_p.h" 50#include <qtopia/private/qfiledirect_p.h>
51#include <string.h> 51#include <string.h>
52#include <stdio.h> 52#include <stdio.h>
53#include <fcntl.h> 53#include <fcntl.h>
@@ -327,18 +327,18 @@ DLLEXPORT(VObject*) setValueWithSize(VObject *prop, void *val, unsigned int size
327 327
328DLLEXPORT(void) initPropIterator(VObjectIterator *i, VObject *o) 328DLLEXPORT(void) initPropIterator(VObjectIterator *i, VObject *o)
329{ 329{
330 i->start = o->prop; 330 i->start = o->prop;
331 i->next = 0; 331 i->next = 0;
332} 332}
333 333
334DLLEXPORT(void) initVObjectIterator(VObjectIterator *i, VObject *o) 334DLLEXPORT(void) initVObjectIterator(VObjectIterator *i, VObject *o)
335{ 335{
336 i->start = o->next; 336 i->start = o->next;
337 i->next = 0; 337 i->next = 0;
338} 338}
339 339
340DLLEXPORT(int) moreIteration(VObjectIterator *i) 340DLLEXPORT(int) moreIteration(VObjectIterator *i)
341{ 341{
342 return (i->start && (i->next==0 || i->next!=i->start)); 342 return (i->start && (i->next==0 || i->next!=i->start));
343} 343}
344 344
@@ -403,7 +403,7 @@ DLLEXPORT(VObject*) addGroup(VObject *o, const char *g)
403 t = addProp(t,VCGroupingProp); 403 t = addProp(t,VCGroupingProp);
404 setVObjectStringZValue(t,lookupProp_(n)); 404 setVObjectStringZValue(t,lookupProp_(n));
405 } while (n != gs); 405 } while (n != gs);
406 deleteStr(gs); 406 deleteStr(gs);
407 return p; 407 return p;
408 } 408 }
409 else 409 else
@@ -799,12 +799,12 @@ static struct PreDefProp* lookupPropInfo(const char* str)
799{ 799{
800 /* brute force for now, could use a hash table here. */ 800 /* brute force for now, could use a hash table here. */
801 int i; 801 int i;
802 802
803 for (i = 0; propNames[i].name; i++) 803 for (i = 0; propNames[i].name; i++)
804 if (qstricmp(str, propNames[i].name) == 0) { 804 if (qstricmp(str, propNames[i].name) == 0) {
805 return &propNames[i]; 805 return &propNames[i];
806 } 806 }
807 807
808 return 0; 808 return 0;
809} 809}
810 810
@@ -812,7 +812,7 @@ static struct PreDefProp* lookupPropInfo(const char* str)
812DLLEXPORT(const char*) lookupProp_(const char* str) 812DLLEXPORT(const char*) lookupProp_(const char* str)
813{ 813{
814 int i; 814 int i;
815 815
816 for (i = 0; propNames[i].name; i++) 816 for (i = 0; propNames[i].name; i++)
817 if (qstricmp(str, propNames[i].name) == 0) { 817 if (qstricmp(str, propNames[i].name) == 0) {
818 const char* s; 818 const char* s;
@@ -826,7 +826,7 @@ DLLEXPORT(const char*) lookupProp_(const char* str)
826DLLEXPORT(const char*) lookupProp(const char* str) 826DLLEXPORT(const char*) lookupProp(const char* str)
827{ 827{
828 int i; 828 int i;
829 829
830 for (i = 0; propNames[i].name; i++) 830 for (i = 0; propNames[i].name; i++)
831 if (qstricmp(str, propNames[i].name) == 0) { 831 if (qstricmp(str, propNames[i].name) == 0) {
832 const char *s; 832 const char *s;
@@ -1005,27 +1005,27 @@ static int writeBase64(OFile *fp, unsigned char *s, long len)
1005 return 1; 1005 return 1;
1006} 1006}
1007 1007
1008static const char *replaceChar(unsigned char c) 1008static const char *replaceChar(unsigned char c)
1009{ 1009{
1010 if (c == '\n') { 1010 if (c == '\n') {
1011 return "=0A=\n"; 1011 return "=0A=\n";
1012 } else if ( 1012 } else if (
1013 (c >= 'A' && c <= 'Z') 1013 (c >= 'A' && c <= 'Z')
1014 || 1014 ||
1015 (c >= 'a' && c <= 'z') 1015 (c >= 'a' && c <= 'z')
1016 || 1016 ||
1017 (c >= '0' && c <= '9') 1017 (c >= '0' && c <= '9')
1018 || 1018 ||
1019 (c >= '\'' && c <= ')') 1019 (c >= '\'' && c <= ')')
1020 || 1020 ||
1021 (c >= '+' && c <= '-') 1021 (c >= '+' && c <= '-')
1022 || 1022 ||
1023 (c == '/') 1023 (c == '/')
1024 || 1024 ||
1025 (c == '?') 1025 (c == '?')
1026 || 1026 ||
1027 (c == ' ')) 1027 (c == ' '))
1028 { 1028 {
1029 return 0; 1029 return 0;
1030 } 1030 }
1031 1031
@@ -1051,7 +1051,7 @@ static const char *replaceChar(unsigned char c)
1051static void writeQPString(OFile *fp, const char *s) 1051static void writeQPString(OFile *fp, const char *s)
1052{ 1052{
1053 /* 1053 /*
1054 only A-Z, 0-9 and 1054 only A-Z, 0-9 and
1055 "'" (ASCII code 39) 1055 "'" (ASCII code 39)
1056 "(" (ASCII code 40) 1056 "(" (ASCII code 40)
1057 ")" (ASCII code 41) 1057 ")" (ASCII code 41)
@@ -1060,7 +1060,7 @@ static void writeQPString(OFile *fp, const char *s)
1060 "-" (ASCII code 45) 1060 "-" (ASCII code 45)
1061 "/" (ASCII code 47) 1061 "/" (ASCII code 47)
1062 "?" (ASCII code 63) 1062 "?" (ASCII code 63)
1063 1063
1064 should remain un-encoded. 1064 should remain un-encoded.
1065 '=' needs to be encoded as it is the escape character. 1065 '=' needs to be encoded as it is the escape character.
1066 ';' needs to be as it is a field separator. 1066 ';' needs to be as it is a field separator.
@@ -1093,7 +1093,7 @@ static bool includesUnprintable(VObject *o)
1093 } 1093 }
1094 return FALSE; 1094 return FALSE;
1095} 1095}
1096 1096
1097static void writeVObject_(OFile *fp, VObject *o); 1097static void writeVObject_(OFile *fp, VObject *o);
1098 1098
1099static void writeValue(OFile *fp, VObject *o, unsigned long size) 1099static void writeValue(OFile *fp, VObject *o, unsigned long size)
@@ -1229,7 +1229,7 @@ static void writeProp(OFile *fp, VObject *o)
1229 } 1229 }
1230 } 1230 }
1231 1231
1232 1232
1233 if (VALUE_TYPE(o)) { 1233 if (VALUE_TYPE(o)) {
1234 if ( includesUnprintable(o) ) { 1234 if ( includesUnprintable(o) ) {
1235 appendsOFile(fp, ";" VCEncodingProp "=" VCQuotedPrintableProp); 1235 appendsOFile(fp, ";" VCEncodingProp "=" VCQuotedPrintableProp);
diff --git a/library/datebookmonth.cpp b/library/datebookmonth.cpp
index 272c223..4a9dcbd 100644
--- a/library/datebookmonth.cpp
+++ b/library/datebookmonth.cpp
@@ -22,7 +22,7 @@
22#include "datebookdb.h" 22#include "datebookdb.h"
23#include <qtopia/private/event.h> 23#include <qtopia/private/event.h>
24#include "resource.h" 24#include "resource.h"
25#include "qpeapplication.h" 25#include <qpe/qpeapplication.h>
26#include "timestring.h" 26#include "timestring.h"
27 27
28#include <qtoolbutton.h> 28#include <qtoolbutton.h>
@@ -554,10 +554,10 @@ void DayItemMonth::paint( QPainter *p, const QColorGroup &cg,
554 int w = cr.width(); 554 int w = cr.width();
555 Event ev = (*itDays).event(); 555 Event ev = (*itDays).event();
556 556
557 int f = (*itDays).start().hour(); // assume Effective event 557 int f = (*itDays).start().hour(); // assume Effective event
558 int t = (*itDays).end().hour(); // is truncated. 558 int t = (*itDays).end().hour(); // is truncated.
559 559
560 if (ev.isAllDay()) { 560 if (ev.isAllDay()) {
561 if (!ev.hasRepeat()) 561 if (!ev.hasRepeat())
562 normalAllDay = TRUE; 562 normalAllDay = TRUE;
563 else 563 else
@@ -615,9 +615,9 @@ void DayItemMonth::paint( QPainter *p, const QColorGroup &cg,
615 p->fillRect( 0, 0, cr.width(), cr.height(), 615 p->fillRect( 0, 0, cr.width(), cr.height(),
616 colorRepeatLight ); 616 colorRepeatLight );
617 } else { 617 } else {
618 p->fillRect( 0, 0, cr.width(), 618 p->fillRect( 0, 0, cr.width(),
619 cr.height(), selected 619 cr.height(), selected
620 ? g.brush( QColorGroup::Highlight ) 620 ? g.brush( QColorGroup::Highlight )
621 : g.brush( QColorGroup::Base ) ); 621 : g.brush( QColorGroup::Base ) );
622 } 622 }
623 623
@@ -733,7 +733,7 @@ void DateButton::setDate( QDate d )
733{ 733{
734 currDate = d; 734 currDate = d;
735 setText( longFormat ? TimeString::longDateString( d, df ) : 735 setText( longFormat ? TimeString::longDateString( d, df ) :
736 TimeString::shortDate( d, df ) ); 736 TimeString::shortDate( d, df ) );
737 737
738} 738}
739 739
diff --git a/library/fileselector.cpp b/library/fileselector.cpp
index 7ff09b4..052a29e 100644
--- a/library/fileselector.cpp
+++ b/library/fileselector.cpp
@@ -31,15 +31,15 @@
31#include "storage.h" 31#include "storage.h"
32#include "qpemenubar.h" 32#include "qpemenubar.h"
33#ifdef QWS 33#ifdef QWS
34#include "qcopchannel_qws.h" 34#include <qcopchannel_qws.h>
35#endif 35#endif
36#include "lnkproperties.h" 36#include "lnkproperties.h"
37#include "applnk.h" 37#include "applnk.h"
38#include "qpeapplication.h" 38#include <qpe/qpeapplication.h>
39#include "categorymenu.h" 39#include "categorymenu.h"
40#include "categoryselect.h" 40#include "categoryselect.h"
41#include "mimetype.h" 41#include "mimetype.h"
42#include "categories.h" 42#include <qpe/categories.h>
43 43
44#include <stdlib.h> 44#include <stdlib.h>
45 45
diff --git a/library/fontdatabase.cpp b/library/fontdatabase.cpp
index c64e645..2b5e0d2 100644
--- a/library/fontdatabase.cpp
+++ b/library/fontdatabase.cpp
@@ -18,7 +18,7 @@
18** 18**
19**********************************************************************/ 19**********************************************************************/
20 20
21#include "qpeapplication.h" 21#include <qpe/qpeapplication.h>
22#include "fontfactoryinterface.h" 22#include "fontfactoryinterface.h"
23#include "fontdatabase.h" 23#include "fontdatabase.h"
24 24
diff --git a/library/fontdatabase.h b/library/fontdatabase.h
index 10aec91..991847b 100644
--- a/library/fontdatabase.h
+++ b/library/fontdatabase.h
@@ -36,6 +36,7 @@ struct FontFactory
36 QFontFactory *factory; 36 QFontFactory *factory;
37}; 37};
38 38
39#undef QT_NO_FONTDATABASE
39class FontDatabase 40class FontDatabase
40#ifndef QT_NO_FONTDATABASE 41#ifndef QT_NO_FONTDATABASE
41 : public QFontDatabase 42 : public QFontDatabase
diff --git a/library/mimetype.cpp b/library/mimetype.cpp
index 92fe5e6..ef5d619 100644
--- a/library/mimetype.cpp
+++ b/library/mimetype.cpp
@@ -22,7 +22,7 @@
22#include "mimetype.h" 22#include "mimetype.h"
23#include "applnk.h" 23#include "applnk.h"
24#include "resource.h" 24#include "resource.h"
25#include "qpeapplication.h" 25#include <qpe/qpeapplication.h>
26#include "config.h" 26#include "config.h"
27 27
28#include <qfile.h> 28#include <qfile.h>
diff --git a/library/qpedialog.cpp b/library/qpedialog.cpp
index 0db161b..b98e42e 100644
--- a/library/qpedialog.cpp
+++ b/library/qpedialog.cpp
@@ -23,7 +23,7 @@
23#undef protected 23#undef protected
24 24
25#include "qpedialog.h" 25#include "qpedialog.h"
26#include "qpeapplication.h" 26#include <qpe/qpeapplication.h>
27 27
28QPEDialogListener::QPEDialogListener(QDialog *di ) : QObject(di) 28QPEDialogListener::QPEDialogListener(QDialog *di ) : QObject(di)
29{ 29{
@@ -36,7 +36,7 @@ QPEDialogListener::~QPEDialogListener() {}
36 36
37void QPEDialogListener::appMessage( const QCString &msg, const QByteArray & ) 37void QPEDialogListener::appMessage( const QCString &msg, const QByteArray & )
38{ 38{
39 if (!dialog) 39 if (!dialog)
40 return; 40 return;
41 if (msg == "accept()") { 41 if (msg == "accept()") {
42 dialog->accept(); 42 dialog->accept();
diff --git a/library/qpestyle.cpp b/library/qpestyle.cpp
index dfd300f..665910c 100644
--- a/library/qpestyle.cpp
+++ b/library/qpestyle.cpp
@@ -19,7 +19,7 @@
19**********************************************************************/ 19**********************************************************************/
20 20
21#include "qpestyle.h" 21#include "qpestyle.h"
22#include "qpeapplication.h" 22#include <qpe/qpeapplication.h>
23#include <qpushbutton.h> 23#include <qpushbutton.h>
24 24
25#include <qpainter.h> 25#include <qpainter.h>
@@ -224,7 +224,7 @@ void QPEStyle::drawControl( ControlElement ce, QPainter *p,
224 cg.brush( QColorGroup::Button )); 224 cg.brush( QColorGroup::Button ));
225 225
226 //do shading; will not work for pixmap brushes 226 //do shading; will not work for pixmap brushes
227 QColor bg = cg.button(); 227 QColor bg = cg.button();
228 // int h,s,v; 228 // int h,s,v;
229 // bg.hsv( &h, &s, &v ); 229 // bg.hsv( &h, &s, &v );
230 int n = r2.height()/2; 230 int n = r2.height()/2;
@@ -533,8 +533,8 @@ QRect QPEStyle::comboButtonRect( int x, int y, int w, int h)
533{ 533{
534 return QRect(x+1, y+1, w-2-14, h-2); 534 return QRect(x+1, y+1, w-2-14, h-2);
535} 535}
536 536
537 537
538QRect QPEStyle::comboButtonFocusRect( int x, int y, int w, int h) 538QRect QPEStyle::comboButtonFocusRect( int x, int y, int w, int h)
539{ 539{
540 return QRect(x+2, y+2, w-4-14, h-4); 540 return QRect(x+2, y+2, w-4-14, h-4);
@@ -918,7 +918,7 @@ void QPEStyle::drawTab( QPainter *p, const QTabBar *tb, QTab *t, bool selected )
918 tb->colorGroup().brush( QColorGroup::Button )); 918 tb->colorGroup().brush( QColorGroup::Button ));
919 919
920 //do shading; will not work for pixmap brushes 920 //do shading; will not work for pixmap brushes
921 QColor bg = tb->colorGroup().button(); 921 QColor bg = tb->colorGroup().button();
922 // int h,s,v; 922 // int h,s,v;
923 // bg.hsv( &h, &s, &v ); 923 // bg.hsv( &h, &s, &v );
924 int n = r.height()/2; 924 int n = r.height()/2;
@@ -1028,7 +1028,7 @@ int QPEStyle::extraPopupMenuItemWidth( bool checkable, int maxpmw, QMenuItem* mi
1028*/ 1028*/
1029int QPEStyle::popupMenuItemHeight( bool /*checkable*/, QMenuItem* mi, const QFontMetrics& fm ) 1029int QPEStyle::popupMenuItemHeight( bool /*checkable*/, QMenuItem* mi, const QFontMetrics& fm )
1030{ 1030{
1031#ifndef QT_NO_MENUDATA 1031#ifndef QT_NO_MENUDATA
1032 int h = 0; 1032 int h = 0;
1033 if ( mi->isSeparator() ) // separator height 1033 if ( mi->isSeparator() ) // separator height
1034 h = motifSepHeight; 1034 h = motifSepHeight;
@@ -1050,7 +1050,7 @@ void QPEStyle::drawPopupMenuItem( QPainter* p, bool checkable, int maxpmw, int t
1050 const QPalette& pal, 1050 const QPalette& pal,
1051 bool act, bool enabled, int x, int y, int w, int h) 1051 bool act, bool enabled, int x, int y, int w, int h)
1052{ 1052{
1053#ifndef QT_NO_MENUDATA 1053#ifndef QT_NO_MENUDATA
1054 const QColorGroup & g = pal.active(); 1054 const QColorGroup & g = pal.active();
1055 bool dis = !enabled; 1055 bool dis = !enabled;
1056 QColorGroup itemg = dis ? pal.disabled() : pal.active(); 1056 QColorGroup itemg = dis ? pal.disabled() : pal.active();
diff --git a/library/resource.cpp b/library/resource.cpp
index bdcd603..0920b67 100644
--- a/library/resource.cpp
+++ b/library/resource.cpp
@@ -19,7 +19,7 @@
19**********************************************************************/ 19**********************************************************************/
20 20
21#define QTOPIA_INTERNAL_MIMEEXT 21#define QTOPIA_INTERNAL_MIMEEXT
22#include "qpeapplication.h" 22#include <qpe/qpeapplication.h>
23#include "resource.h" 23#include "resource.h"
24#include "mimetype.h" 24#include "mimetype.h"
25#include <qdir.h> 25#include <qdir.h>
diff --git a/library/timestring.cpp b/library/timestring.cpp
index 4c6fa72..6443b6b 100644
--- a/library/timestring.cpp
+++ b/library/timestring.cpp
@@ -20,7 +20,7 @@
20 20
21#include "timestring.h" 21#include "timestring.h"
22#include <qobject.h> 22#include <qobject.h>
23#include "qpeapplication.h" //for qApp 23#include <qpe/qpeapplication.h> //for qApp
24#include "config.h" 24#include "config.h"
25 25
26 26
@@ -49,7 +49,7 @@ private:
49 Config config("qpe"); 49 Config config("qpe");
50 config.setGroup( "Date" ); 50 config.setGroup( "Date" );
51 format = DateFormat(QChar(config.readEntry("Separator", "/")[0]), 51 format = DateFormat(QChar(config.readEntry("Separator", "/")[0]),
52 (DateFormat::Order)config .readNumEntry("ShortOrder", DateFormat::DayMonthYear), 52 (DateFormat::Order)config .readNumEntry("ShortOrder", DateFormat::DayMonthYear),
53 (DateFormat::Order)config.readNumEntry("LongOrder", DateFormat::DayMonthYear)); 53 (DateFormat::Order)config.readNumEntry("LongOrder", DateFormat::DayMonthYear));
54 54
55 connect( qApp, SIGNAL( dateFormatChanged(DateFormat) ), 55 connect( qApp, SIGNAL( dateFormatChanged(DateFormat) ),
@@ -65,7 +65,7 @@ QString DateFormat::toNumberString() const
65 // for each part of the order 65 // for each part of the order
66 for (int i = 0; i < 3; i++) { 66 for (int i = 0; i < 3; i++) {
67 // switch on the relavent 3 bits. 67 // switch on the relavent 3 bits.
68 switch((_shortOrder >> (i * 3)) & 0x0007) { 68 switch((_shortOrder >> (i * 3)) & 0x0007) {
69 case 0x0001: 69 case 0x0001:
70 buf += QObject::tr( "D" ); 70 buf += QObject::tr( "D" );
71 break; 71 break;
@@ -88,24 +88,24 @@ QString DateFormat::toWordString() const
88 // for each part of the order 88 // for each part of the order
89 for (int i = 0; i < 3; i++) { 89 for (int i = 0; i < 3; i++) {
90 // switch on the relavent 3 bits. 90 // switch on the relavent 3 bits.
91 switch((_longOrder >> (i * 3)) & 0x0007) { 91 switch((_longOrder >> (i * 3)) & 0x0007) {
92 case 0x0001: 92 case 0x0001:
93 buf += QObject::tr( "day" ); 93 buf += QObject::tr( "day" );
94 if (i < 2) { 94 if (i < 2) {
95 if ((_shortOrder << ((i+1) * 3)) & 0x0007) 95 if ((_shortOrder << ((i+1) * 3)) & 0x0007)
96 buf += ", "; 96 buf += ", ";
97 else 97 else
98 buf += " "; 98 buf += " ";
99 } 99 }
100 break; 100 break;
101 case 0x0002: 101 case 0x0002:
102 buf += QObject::tr( "month" ); 102 buf += QObject::tr( "month" );
103 if (i < 2) 103 if (i < 2)
104 buf += " "; 104 buf += " ";
105 break; 105 break;
106 case 0x0004: 106 case 0x0004:
107 buf += QObject::tr( "year" ); 107 buf += QObject::tr( "year" );
108 if (i < 2) 108 if (i < 2)
109 buf += ", "; 109 buf += ", ";
110 break; 110 break;
111 } 111 }
@@ -122,7 +122,7 @@ QString DateFormat::numberDate(const QDate &d, int v) const
122 // for each part of the order 122 // for each part of the order
123 for (int i = 0; i < 3; i++) { 123 for (int i = 0; i < 3; i++) {
124 // switch on the relavent 3 bits. 124 // switch on the relavent 3 bits.
125 switch((_shortOrder >> (i * 3)) & 0x0007) { 125 switch((_shortOrder >> (i * 3)) & 0x0007) {
126 case 0x0001: 126 case 0x0001:
127 if (pad==2) buf += QString().sprintf("%02d",d.day()); 127 if (pad==2) buf += QString().sprintf("%02d",d.day());
128 else buf += QString().sprintf("%d",d.day()); 128 else buf += QString().sprintf("%d",d.day());
@@ -161,21 +161,21 @@ QString DateFormat::wordDate(const QDate &d, int v) const
161 buf += weekDay; 161 buf += weekDay;
162 if ((_longOrder & 0x0007) == 0x0002) 162 if ((_longOrder & 0x0007) == 0x0002)
163 buf += ' '; 163 buf += ' ';
164 else 164 else
165 buf += ", "; 165 buf += ", ";
166 } 166 }
167 167
168 for (int i = 0; i < 3; i++) { 168 for (int i = 0; i < 3; i++) {
169 // switch on the relavent 3 bits. 169 // switch on the relavent 3 bits.
170 switch((_longOrder >> (i * 3)) & 0x0007) { 170 switch((_longOrder >> (i * 3)) & 0x0007) {
171 case 0x0001: 171 case 0x0001:
172 if (i==1) { 172 if (i==1) {
173 buf += QString().sprintf("%02d, ",d.day()); 173 buf += QString().sprintf("%02d, ",d.day());
174 } else { 174 } else {
175 buf += QString().sprintf("%2d",d.day()); 175 buf += QString().sprintf("%2d",d.day());
176 if (separator()=='.') // 2002/1/11 176 if (separator()=='.') // 2002/1/11
177 buf += ". "; 177 buf += ". ";
178 else 178 else
179 buf += " "; 179 buf += " ";
180 } 180 }
181 break; 181 break;
@@ -187,7 +187,7 @@ QString DateFormat::wordDate(const QDate &d, int v) const
187 } 187 }
188 buf += monthName; 188 buf += monthName;
189 } 189 }
190 if (i < 2) 190 if (i < 2)
191 buf += " "; 191 buf += " ";
192 break; 192 break;
193 case 0x0004: 193 case 0x0004:
@@ -201,7 +201,7 @@ QString DateFormat::wordDate(const QDate &d, int v) const
201 201
202 buf += QString::number(year); 202 buf += QString::number(year);
203 } 203 }
204 if (i < 2) 204 if (i < 2)
205 buf += ", "; 205 buf += ", ";
206 break; 206 break;
207 } 207 }
@@ -219,7 +219,7 @@ void DateFormat::save(QDataStream &d) const
219 d << v; 219 d << v;
220} 220}
221 221
222void DateFormat::load(QDataStream &d) 222void DateFormat::load(QDataStream &d)
223{ 223{
224 ushort value; 224 ushort value;
225 d >> value; 225 d >> value;
@@ -257,7 +257,7 @@ QString TimeString::dateString( const QDate &d, DateFormat dtf )
257 257
258QString TimeString::longDateString( const QDate &d, DateFormat dtf ) 258QString TimeString::longDateString( const QDate &d, DateFormat dtf )
259{ 259{
260 return dtf.wordDate(d, DateFormat::showWeekDay | DateFormat::longNumber 260 return dtf.wordDate(d, DateFormat::showWeekDay | DateFormat::longNumber
261 | DateFormat::longWord); 261 | DateFormat::longWord);
262} 262}
263 263