summaryrefslogtreecommitdiff
authorzecke <zecke>2003-06-11 10:24:16 (UTC)
committer zecke <zecke>2003-06-11 10:24:16 (UTC)
commit188319af82322c84f02e1abb848d908ca8f9e26c (patch) (side-by-side diff)
treee88f078a70ded124b1cf0adc2b2a039f564e861b
parent4d05b57498f6b2f135ecd55e5fde5e6ebc21c160 (diff)
downloadopie-188319af82322c84f02e1abb848d908ca8f9e26c.zip
opie-188319af82322c84f02e1abb848d908ca8f9e26c.tar.gz
opie-188319af82322c84f02e1abb848d908ca8f9e26c.tar.bz2
do what the FIXME says... const fixes
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--libopie/oticker.cpp4
-rw-r--r--libopie/oticker.h6
2 files changed, 4 insertions, 6 deletions
diff --git a/libopie/oticker.cpp b/libopie/oticker.cpp
index 9a7044d..4fb5945 100644
--- a/libopie/oticker.cpp
+++ b/libopie/oticker.cpp
@@ -46,38 +46,38 @@
OTicker::OTicker( QWidget* parent )
: QLabel( parent ) {
// : QFrame( parent ) {
setTextFormat(Qt::RichText);
Config cfg("qpe");
cfg.setGroup("Appearance");
backgroundcolor = QColor( cfg.readEntry( "Background", "#E5E1D5" ) );
foregroundcolor= Qt::black;
updateTimerTime = 50;
scrollLength = 1;
}
OTicker::~OTicker() {
}
-void OTicker::setBackgroundColor(QColor backcolor) {
+void OTicker::setBackgroundColor(const QColor& backcolor) {
backgroundcolor = backcolor;
update();
}
-void OTicker::setForegroundColor(QColor backcolor) {
+void OTicker::setForegroundColor(const QColor& backcolor) {
foregroundcolor = backcolor;
update();
}
void OTicker::setFrame(int frameStyle) {
setFrameStyle( frameStyle/*WinPanel | Sunken */);
update();
}
void OTicker::setText( const QString& text ) {
pos = 0; // reset it everytime the text is changed
scrollText = text;
qDebug(scrollText);
int pixelLen = 0;
bool bigger = false;
diff --git a/libopie/oticker.h b/libopie/oticker.h
index c52e317..0b88919 100644
--- a/libopie/oticker.h
+++ b/libopie/oticker.h
@@ -65,42 +65,40 @@ public:
* @brief Object destructor.
*/
~OTicker();
/*!
* @fn setText(const QString& )
* @brief sets text to be displayed
* @param text QString text to be displayed.
*
*/
void setText( const QString& text ) ;
/*!
* @fn setBackgroundColor(QColor color)
* @brief sets color of the ticker's background
* @param color QColor color to be set.
*
*/
- //FIXME const QColor& please -zecke
- void setBackgroundColor(QColor color);
+ void setBackgroundColor(const QColor& color);
/*!
* @fn setForegroundColor(QColor color)
* @brief sets color of text
* @param color QColor color of text
*
*/
- // FIXME const QColor& please -zecke
- void setForegroundColor(QColor color);
+ void setForegroundColor(const QColor& color);
/*!
* @fn setFrame(int style)
* @brief sets frame style
* @param style int Frame style to be see. See Qt::WidgetFlags.
*
*/
void setFrame(int style);
/*!
* @fn setUpdateTime(int timeout)
* @brief sets time of update
* @param timeout int time in milliseconds between updates.
*
*/
void setUpdateTime(int timeout);
/*!
* @fn setScrollLength(int length)