summaryrefslogtreecommitdiff
authorharlekin <harlekin>2003-03-29 13:23:53 (UTC)
committer harlekin <harlekin>2003-03-29 13:23:53 (UTC)
commit7c43e678395bbf781195686b34cc596ea72aa512 (patch) (unidiff)
treee201eb358c019ea5e116c704c49729d1fe9c0d91
parent22e941e4cbc9e8906287d1e352b66092c6a84c0d (diff)
downloadopie-7c43e678395bbf781195686b34cc596ea72aa512.zip
opie-7c43e678395bbf781195686b34cc596ea72aa512.tar.gz
opie-7c43e678395bbf781195686b34cc596ea72aa512.tar.bz2
added option to made the banner on top much smaller and also the date should adapt to local settings now ( hopefully )
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/today/today.cpp24
-rw-r--r--core/pim/today/today.h1
-rw-r--r--core/pim/today/todaybase.cpp4
-rw-r--r--core/pim/today/todaybase.h2
-rw-r--r--core/pim/today/todayconfig.cpp13
-rw-r--r--core/pim/today/todayconfig.h4
6 files changed, 40 insertions, 8 deletions
diff --git a/core/pim/today/today.cpp b/core/pim/today/today.cpp
index 5e5d373..0b61bf8 100644
--- a/core/pim/today/today.cpp
+++ b/core/pim/today/today.cpp
@@ -28,2 +28,3 @@
28#include <qpe/contact.h> 28#include <qpe/contact.h>
29#include <qpe/timestring.h>
29 30
@@ -132,2 +133,3 @@ void Today::init() {
132 m_iconSize = cfg.readNumEntry( "IconSize", 18 ); 133 m_iconSize = cfg.readNumEntry( "IconSize", 18 );
134 m_hideBanner = cfg.readNumEntry( "HideBanner", 0 );
133 setRefreshTimer( cfg.readNumEntry( "checkinterval", 15000 ) ); 135 setRefreshTimer( cfg.readNumEntry( "checkinterval", 15000 ) );
@@ -136,4 +138,3 @@ void Today::init() {
136 QDate date = QDate::currentDate(); 138 QDate date = QDate::currentDate();
137 QString time = ( tr( date.toString() ) ); 139 DateLabel->setText( QString( "<font color=#FFFFFF>" + TimeString::longDateString( date ) + "</font>" ) );
138 DateLabel->setText( QString( "<font color=#FFFFFF>" + time + "</font>" ) );
139 140
@@ -142,2 +143,19 @@ void Today::init() {
142 } 143 }
144
145 if ( m_hideBanner ) {
146 Opiezilla->hide();
147 TodayLabel->hide();
148 Frame->setMaximumHeight( 18 );
149 Frame->setMinimumHeight( 18 );
150 DateLabel->setGeometry( QRect( 10, 2, 168, 12 ) );
151 ConfigButton->setGeometry( QRect( QApplication::desktop()->width()-20, 0, 25, 20 ) );
152 } else {
153 Opiezilla->show();
154 TodayLabel->show();
155 Frame->setMaximumHeight( 50 );
156 Frame->setMinimumHeight( 50 );
157 DateLabel->setGeometry( QRect( 10, 35, 168, 12 ) );
158 ConfigButton->setGeometry( QRect( QApplication::desktop()->width()-80, 29, 25, 20 ) );
159 }
160
143 layout = new QVBoxLayout( this ); 161 layout = new QVBoxLayout( this );
@@ -321,3 +339,3 @@ void Today::startConfig() {
321 339
322 for ( int i = pluginList.count() - 1 ; i >= 0; i-- ) { 340 for ( int i = pluginList.count() - 1; i >= 0; i-- ) {
323 plugin = pluginList[i]; 341 plugin = pluginList[i];
diff --git a/core/pim/today/today.h b/core/pim/today/today.h
index 3802feb..b28ac96 100644
--- a/core/pim/today/today.h
+++ b/core/pim/today/today.h
@@ -68,2 +68,3 @@ private slots:
68 int m_maxCharClip; 68 int m_maxCharClip;
69 int m_hideBanner;
69}; 70};
diff --git a/core/pim/today/todaybase.cpp b/core/pim/today/todaybase.cpp
index da4efa3..a36ecaa 100644
--- a/core/pim/today/todaybase.cpp
+++ b/core/pim/today/todaybase.cpp
@@ -60,3 +60,3 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags )
60 // Today text 60 // Today text
61 QLabel* TodayLabel = new QLabel( Frame, "TodayText" ); 61 TodayLabel = new QLabel( Frame, "TodayText" );
62 TodayLabel->setGeometry( QRect( 10, 1, 168, 40 ) ); 62 TodayLabel->setGeometry( QRect( 10, 1, 168, 40 ) );
@@ -79,3 +79,3 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags )
79 // Opiezilla 79 // Opiezilla
80 QLabel* Opiezilla = new QLabel( Frame, "OpieZilla" ); 80 Opiezilla = new QLabel( Frame, "OpieZilla" );
81 Opiezilla->setPixmap( opiezilla ); 81 Opiezilla->setPixmap( opiezilla );
diff --git a/core/pim/today/todaybase.h b/core/pim/today/todaybase.h
index 340c7a6..b0b2e14 100644
--- a/core/pim/today/todaybase.h
+++ b/core/pim/today/todaybase.h
@@ -45,2 +45,4 @@ public:
45 QFrame* Frame15; 45 QFrame* Frame15;
46 QLabel* Opiezilla;
47 QLabel* TodayLabel;
46 OClickableLabel* ConfigButton; 48 OClickableLabel* ConfigButton;
diff --git a/core/pim/today/todayconfig.cpp b/core/pim/today/todayconfig.cpp
index 0774ccb..a60f1d2 100644
--- a/core/pim/today/todayconfig.cpp
+++ b/core/pim/today/todayconfig.cpp
@@ -56,3 +56,3 @@ TodayConfig::TodayConfig( QWidget* parent, const char* name, bool modal )
56 56
57 setCaption( tr( "Today config" ) ); 57 setCaption( tr( "Today Config" ) );
58 58
@@ -87,2 +87,10 @@ TodayConfig::TodayConfig( QWidget* parent, const char* name, bool modal )
87 QWhatsThis::add( CheckBoxAuto, tr( "Check this if today should be autostarted on resume." ) ); 87 QWhatsThis::add( CheckBoxAuto, tr( "Check this if today should be autostarted on resume." ) );
88
89 QHBox *hbox_hide = new QHBox( tab_3 );
90 TextLabel4 = new QLabel( hbox_hide, "HideBanner" );
91 TextLabel4->setText( tr( "Tiny Banner" ) );
92 //QWhatsThis::add( TextLabel2 , tr( "Check this if today should be autostarted on resume." ) );
93 CheckBoxHide = new QCheckBox( hbox_hide, "CheckBoxHide" );
94 // QWhatsThis::add( CheckBoxAuto, tr( "Check this if today should be autostarted on resume." ) );
95
88 QHBox *hbox_inactive = new QHBox( tab_3 ); 96 QHBox *hbox_inactive = new QHBox( tab_3 );
@@ -114,2 +122,3 @@ TodayConfig::TodayConfig( QWidget* parent, const char* name, bool modal )
114 tab3Layout->addWidget( hbox_auto ); 122 tab3Layout->addWidget( hbox_auto );
123 tab3Layout->addWidget( hbox_hide );
115 tab3Layout->addWidget( hbox_inactive ); 124 tab3Layout->addWidget( hbox_inactive );
@@ -162,2 +171,3 @@ void TodayConfig::readConfig() {
162 SpinRefresh->setValue( cfg.readNumEntry( "checkinterval", 15000 ) / 1000 ); 171 SpinRefresh->setValue( cfg.readNumEntry( "checkinterval", 15000 ) / 1000 );
172 CheckBoxHide->setChecked( cfg.readNumEntry( "HideBanner", 0 ) );
163 173
@@ -209,2 +219,3 @@ void TodayConfig::writeConfig() {
209 cfg.writeEntry( "IconSize", m_iconSize ); 219 cfg.writeEntry( "IconSize", m_iconSize );
220 cfg.writeEntry( "HideBanner", CheckBoxHide->isChecked() );
210 cfg.writeEntry( "checkinterval", SpinRefresh->value()*1000 ); 221 cfg.writeEntry( "checkinterval", SpinRefresh->value()*1000 );
diff --git a/core/pim/today/todayconfig.h b/core/pim/today/todayconfig.h
index 68483c2..41bd44b 100644
--- a/core/pim/today/todayconfig.h
+++ b/core/pim/today/todayconfig.h
@@ -62,6 +62,6 @@ private:
62 QLabel* TextLabel2; 62 QLabel* TextLabel2;
63 QCheckBox* CheckBoxAuto; 63 QCheckBox* CheckBoxAuto, *CheckBoxHide;
64 QWidget* tab_2; 64 QWidget* tab_2;
65 QWidget* tab_3; 65 QWidget* tab_3;
66 QLabel* TextLabel1; 66 QLabel* TextLabel1, *TextLabel4;
67 QSpinBox* SpinBox7; 67 QSpinBox* SpinBox7;