author | erik <erik> | 2007-02-09 21:16:14 (UTC) |
---|---|---|
committer | erik <erik> | 2007-02-09 21:16:14 (UTC) |
commit | 570130f80c0db0c9acab25423b8e8424beb78491 (patch) (unidiff) | |
tree | 6a42bf998188819bdf036e214e7c7e221cf5fd64 | |
parent | 2695f72652956e94e24611539579e7ff7899811e (diff) | |
download | opie-570130f80c0db0c9acab25423b8e8424beb78491.zip opie-570130f80c0db0c9acab25423b8e8424beb78491.tar.gz opie-570130f80c0db0c9acab25423b8e8424beb78491.tar.bz2 |
This commit is based on the patch submitted to bug 1702:
http://opie-bugs.oszine.de/view.php?id=1702
The problem behavior said that the day abbreviations in the PIM suite were
wrong for at least it and fr. The fix is to make sure that there is not a
translation of the abbreviations because the abbreviations have already
been translated.
Thanks goes to an anonymous reporter for reporting and to antonus for
submitting a patch. Thanks to Paul E. (aka BlueLightning) for bringing the
bug to our attention.
-rw-r--r-- | core/pim/datebook/modules/weeklst/datebookweeklstdayhdr.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/pim/datebook/modules/weeklst/datebookweeklstdayhdr.cpp b/core/pim/datebook/modules/weeklst/datebookweeklstdayhdr.cpp index d173444..24a68ed 100644 --- a/core/pim/datebook/modules/weeklst/datebookweeklstdayhdr.cpp +++ b/core/pim/datebook/modules/weeklst/datebookweeklstdayhdr.cpp | |||
@@ -1,53 +1,53 @@ | |||
1 | #include "datebookweeklstdayhdr.h" | 1 | #include "datebookweeklstdayhdr.h" |
2 | 2 | ||
3 | #include "namespace_hack.h" | 3 | #include "namespace_hack.h" |
4 | 4 | ||
5 | DateBookWeekLstDayHdr::DateBookWeekLstDayHdr(const QDate &d, bool /* onM */, | 5 | DateBookWeekLstDayHdr::DateBookWeekLstDayHdr(const QDate &d, bool /* onM */, |
6 | QWidget* parent, | 6 | QWidget* parent, |
7 | const char* name, | 7 | const char* name, |
8 | WFlags fl ) | 8 | WFlags fl ) |
9 | : DateBookWeekLstDayHdrBase(parent, name, fl) { | 9 | : DateBookWeekLstDayHdrBase(parent, name, fl) { |
10 | 10 | ||
11 | date=d; | 11 | date=d; |
12 | 12 | ||
13 | static const QString wdays=tr("MTWTFSSM", "Week days"); | 13 | static const QString wdays=tr("MTWTFSSM", "Week days"); |
14 | char day=wdays[d.dayOfWeek()-1]; | 14 | char day=wdays[d.dayOfWeek()-1]; |
15 | 15 | ||
16 | //dont use dayOfWeek() to save space ! | 16 | //dont use dayOfWeek() to save space ! |
17 | label->setText( QString(QObject::tr(QString(QChar(day)))) + " " +QString::number(d.day()) ); | 17 | label->setText( QString(QString(QChar(day))) + " " +QString::number(d.day()) ); |
18 | 18 | ||
19 | add->setText("+"); | 19 | add->setText("+"); |
20 | 20 | ||
21 | if (d == QDate::currentDate()) { | 21 | if (d == QDate::currentDate()) { |
22 | QPalette pal=label->palette(); | 22 | QPalette pal=label->palette(); |
23 | pal.setColor(QColorGroup::Foreground, QColor(0,0,255)); | 23 | pal.setColor(QColorGroup::Foreground, QColor(0,0,255)); |
24 | label->setPalette(pal); | 24 | label->setPalette(pal); |
25 | 25 | ||
26 | /* | 26 | /* |
27 | QFont f=label->font(); | 27 | QFont f=label->font(); |
28 | f.setItalic(true); | 28 | f.setItalic(true); |
29 | label->setFont(f); | 29 | label->setFont(f); |
30 | label->setPalette(QPalette(QColor(0,0,255),label->backgroundColor())); | 30 | label->setPalette(QPalette(QColor(0,0,255),label->backgroundColor())); |
31 | */ | 31 | */ |
32 | } else if (d.dayOfWeek() == 7) { // FIXME: Match any holiday | 32 | } else if (d.dayOfWeek() == 7) { // FIXME: Match any holiday |
33 | QPalette pal=label->palette(); | 33 | QPalette pal=label->palette(); |
34 | pal.setColor(QColorGroup::Foreground, QColor(255,0,0)); | 34 | pal.setColor(QColorGroup::Foreground, QColor(255,0,0)); |
35 | label->setPalette(pal); | 35 | label->setPalette(pal); |
36 | } | 36 | } |
37 | 37 | ||
38 | connect (label, SIGNAL(clicked()), this, SLOT(showDay())); | 38 | connect (label, SIGNAL(clicked()), this, SLOT(showDay())); |
39 | connect (add, SIGNAL(clicked()), this, SLOT(newEvent())); | 39 | connect (add, SIGNAL(clicked()), this, SLOT(newEvent())); |
40 | } | 40 | } |
41 | 41 | ||
42 | void DateBookWeekLstDayHdr::showDay() { | 42 | void DateBookWeekLstDayHdr::showDay() { |
43 | emit showDate(date.year(), date.month(), date.day()); | 43 | emit showDate(date.year(), date.month(), date.day()); |
44 | } | 44 | } |
45 | 45 | ||
46 | void DateBookWeekLstDayHdr::newEvent() { | 46 | void DateBookWeekLstDayHdr::newEvent() { |
47 | QDateTime start, stop; | 47 | QDateTime start, stop; |
48 | start=stop=date; | 48 | start=stop=date; |
49 | start.setTime(QTime(10,0)); | 49 | start.setTime(QTime(10,0)); |
50 | stop.setTime(QTime(12,0)); | 50 | stop.setTime(QTime(12,0)); |
51 | 51 | ||
52 | emit addEvent(start,stop,"",0); | 52 | emit addEvent(start,stop,"",0); |
53 | } | 53 | } |