summaryrefslogtreecommitdiffstats
path: root/src/scripttools/debugging/qscriptbreakpointswidget.cpp
diff options
context:
space:
mode:
authorJason McDonald <jason.mcdonald@nokia.com>2009-04-16 01:06:09 (GMT)
committerJason McDonald <jason.mcdonald@nokia.com>2009-04-16 01:06:09 (GMT)
commit5174ef058693fb3c5420bd9ed555ebf0dfc758a2 (patch)
tree2e8272b2394c9beff850e08dd745559d11aad258 /src/scripttools/debugging/qscriptbreakpointswidget.cpp
parent3eb4aacf07c77876c6ce68e9746906424934433b (diff)
downloadQt-5174ef058693fb3c5420bd9ed555ebf0dfc758a2.zip
Qt-5174ef058693fb3c5420bd9ed555ebf0dfc758a2.tar.gz
Qt-5174ef058693fb3c5420bd9ed555ebf0dfc758a2.tar.bz2
Remove obsolete pre-processor directives that check QT_VERSION.
Reviewed-by: Kent Hansen
Diffstat (limited to 'src/scripttools/debugging/qscriptbreakpointswidget.cpp')
-rw-r--r--src/scripttools/debugging/qscriptbreakpointswidget.cpp8
1 files changed, 0 insertions, 8 deletions
diff --git a/src/scripttools/debugging/qscriptbreakpointswidget.cpp b/src/scripttools/debugging/qscriptbreakpointswidget.cpp
index aea1fe7..efb3047 100644
--- a/src/scripttools/debugging/qscriptbreakpointswidget.cpp
+++ b/src/scripttools/debugging/qscriptbreakpointswidget.cpp
@@ -225,7 +225,6 @@ public:
bool eventFilter(QObject *editor, QEvent *event)
{
-#if QT_VERSION >= 0x040500
if (QLineEdit *le = qobject_cast<QLineEdit*>(editor)) {
if (event->type() == QEvent::KeyPress) {
int key = static_cast<QKeyEvent*>(event)->key();
@@ -237,21 +236,18 @@ public:
}
}
}
-#endif
return QStyledItemDelegate::eventFilter(editor, event);
}
void setModelData(QWidget *editor, QAbstractItemModel *model,
const QModelIndex &index) const
{
-#if QT_VERSION >= 0x040500
if (index.column() == 2) {
// check that the syntax is OK
QString condition = qobject_cast<QLineEdit*>(editor)->text();
if (QScriptEngine::checkSyntax(condition).state() != QScriptSyntaxCheckResult::Valid)
return;
}
-#endif
QStyledItemDelegate::setModelData(editor, model, index);
}
@@ -261,11 +257,7 @@ private Q_SLOTS:
QWidget *editor = qobject_cast<QWidget*>(sender());
QPalette pal = editor->palette();
QColor col;
-#if QT_VERSION >= 0x040500
bool ok = (QScriptEngine::checkSyntax(text).state() == QScriptSyntaxCheckResult::Valid);
-#else
- bool ok = true;
-#endif
if (ok) {
col = Qt::white;
} else {