summaryrefslogtreecommitdiff
path: root/library/lightstyle.cpp
authorar <ar>2005-01-21 19:56:15 (UTC)
committer ar <ar>2005-01-21 19:56:15 (UTC)
commitcd51d382be50bc021739395309e23760f1619759 (patch) (unidiff)
treee76155f772df7faea5fcf38667c6da8c916208db /library/lightstyle.cpp
parentfdc37fbd908472e28735a8f0b01e3e66a43535e0 (diff)
downloadopie-cd51d382be50bc021739395309e23760f1619759.zip
opie-cd51d382be50bc021739395309e23760f1619759.tar.gz
opie-cd51d382be50bc021739395309e23760f1619759.tar.bz2
- make opie compilable against qte 2.3.10 snapshot
check QT_VERSION against 0x030000 instead of 300
Diffstat (limited to 'library/lightstyle.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--library/lightstyle.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/library/lightstyle.cpp b/library/lightstyle.cpp
index f18bdca..3bd1623 100644
--- a/library/lightstyle.cpp
+++ b/library/lightstyle.cpp
@@ -19,7 +19,7 @@
19**********************************************************************/ 19**********************************************************************/
20#include "lightstyle.h" 20#include "lightstyle.h"
21 21
22#if QT_VERSION < 300 22#if QT_VERSION < 0x030000
23 23
24#define INCLUDE_MENUITEM_DEF 24#define INCLUDE_MENUITEM_DEF
25#include "qmenubar.h" 25#include "qmenubar.h"
@@ -159,7 +159,7 @@ void LightStyle::polish(QWidget *widget)
159 if (widget->inherits("QPushButton")) 159 if (widget->inherits("QPushButton"))
160 widget->installEventFilter(this); 160 widget->installEventFilter(this);
161 161
162#if QT_VERSION >= 300 162#if QT_VERSION >= 0x030000
163 if (widget->inherits("QLineEdit")) { 163 if (widget->inherits("QLineEdit")) {
164 QLineEdit *lineedit = (QLineEdit *) widget; 164 QLineEdit *lineedit = (QLineEdit *) widget;
165 lineedit->setFrameShape(QFrame::StyledPanel); 165 lineedit->setFrameShape(QFrame::StyledPanel);
@@ -176,7 +176,7 @@ void LightStyle::unPolish(QWidget *widget)
176 if (widget->inherits("QPushButton")) 176 if (widget->inherits("QPushButton"))
177 widget->removeEventFilter(this); 177 widget->removeEventFilter(this);
178 178
179#if QT_VERSION >= 300 179#if QT_VERSION >= 0x030000
180 if (widget->inherits("QLineEdit")) { 180 if (widget->inherits("QLineEdit")) {
181 QLineEdit *lineedit = (QLineEdit *) widget; 181 QLineEdit *lineedit = (QLineEdit *) widget;
182 lineedit->setLineWidth(1); 182 lineedit->setLineWidth(1);
@@ -414,7 +414,7 @@ void LightStyle::drawComboButton(QPainter *p, int x, int y, int w, int h,
414 int indent = ((y + h) / 2) - 3; 414 int indent = ((y + h) / 2) - 3;
415 int xpos = x; 415 int xpos = x;
416 416
417#if QT_VERSION >= 300 417#if QT_VERSION >= 0x030000
418 if( QApplication::reverseLayout() ) 418 if( QApplication::reverseLayout() )
419 xpos += indent; 419 xpos += indent;
420 else 420 else
@@ -431,7 +431,7 @@ QRect LightStyle::comboButtonRect( int x, int y, int w, int h ) const
431 int indent = ((y + h) / 2) - 3; 431 int indent = ((y + h) / 2) - 3;
432 r.setRight(r.right() - indent - 10); 432 r.setRight(r.right() - indent - 10);
433 433
434#if QT_VERSION >= 300 434#if QT_VERSION >= 0x030000
435 if( QApplication::reverseLayout() ) 435 if( QApplication::reverseLayout() )
436 r.moveBy( indent + 10, 0 ); 436 r.moveBy( indent + 10, 0 );
437#endif 437#endif