summaryrefslogtreecommitdiffstats
path: root/src/widgets
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@nokia.com>2011-09-28 22:20:06 +0200
committerQt by Nokia <qt-info@nokia.com>2011-10-03 05:59:07 +0200
commit3fd9398052d2b483d2830c3661ceed26e551fa49 (patch)
tree9eeca582e2c749aca76c3df38ffb1043344a70c6 /src/widgets
parent302b3c7d073d1bccd4468c990510697b77b2ece9 (diff)
Remove the remaining traces of QT3_SUPPORT
The only place that now still knows about it is moc, so it can still parse old headers. Change-Id: Iafec080f99c67560974e9ebc0cbfb27d9a4b2d6f Reviewed-on: http://codereview.qt-project.org/5755 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Diffstat (limited to 'src/widgets')
-rw-r--r--src/widgets/kernel/qapplication.cpp22
-rw-r--r--src/widgets/kernel/qlayout.h8
-rw-r--r--src/widgets/kernel/qsizepolicy.qdoc160
-rw-r--r--src/widgets/kernel/qwidget.cpp51
-rw-r--r--src/widgets/kernel/qwidget.h9
-rw-r--r--src/widgets/platforms/mac/qapplication_mac.mm9
-rw-r--r--src/widgets/platforms/mac/qkeymapper_mac.cpp30
-rw-r--r--src/widgets/platforms/mac/qwidget_mac.mm3
-rw-r--r--src/widgets/platforms/win/qkeymapper_win.cpp16
-rw-r--r--src/widgets/platforms/x11/qkeymapper_x11.cpp12
-rw-r--r--src/widgets/styles/qmacstyle_mac.mm48
-rw-r--r--src/widgets/widgets/qcombobox.h9
-rw-r--r--src/widgets/widgets/qframe.h13
-rw-r--r--src/widgets/widgets/qlabel.cpp8
-rw-r--r--src/widgets/widgets/qlcdnumber.h3
-rw-r--r--src/widgets/widgets/qslider.h9
-rw-r--r--src/widgets/widgets/qsplitter.cpp2
-rw-r--r--src/widgets/widgets/qsplitter.h2
-rw-r--r--src/widgets/widgets/qtabbar.h4
-rw-r--r--src/widgets/widgets/qtabwidget.h6
-rw-r--r--src/widgets/widgets/qtextbrowser.h5
-rw-r--r--src/widgets/widgets/qtextedit.h22
22 files changed, 7 insertions, 444 deletions
diff --git a/src/widgets/kernel/qapplication.cpp b/src/widgets/kernel/qapplication.cpp
index 74336bec28..b87c0c9d8a 100644
--- a/src/widgets/kernel/qapplication.cpp
+++ b/src/widgets/kernel/qapplication.cpp
@@ -3607,24 +3607,6 @@ bool QApplication::notify(QObject *receiver, QEvent *e)
if (!receiver->isWidgetType()) {
res = d->notify_helper(receiver, e);
} else switch (e->type()) {
-#if defined QT3_SUPPORT && !defined(QT_NO_SHORTCUT)
- case QEvent::Accel:
- {
- if (d->use_compat()) {
- QKeyEvent* key = static_cast<QKeyEvent*>(e);
- res = d->notify_helper(receiver, e);
-
- if (!res && !key->isAccepted())
- res = d->qt_dispatchAccelEvent(static_cast<QWidget *>(receiver), key);
-
- // next lines are for compatibility with Qt <= 3.0.x: old
- // QAccel was listening on toplevel widgets
- if (!res && !key->isAccepted() && !static_cast<QWidget *>(receiver)->isWindow())
- res = d->notify_helper(static_cast<QWidget *>(receiver)->window(), e);
- }
- break;
- }
-#endif //QT3_SUPPORT && !QT_NO_SHORTCUT
case QEvent::ShortcutOverride:
case QEvent::KeyPress:
case QEvent::KeyRelease:
@@ -3640,10 +3622,6 @@ bool QApplication::notify(QObject *receiver, QEvent *e)
}
QKeyEvent* key = static_cast<QKeyEvent*>(e);
-#if defined QT3_SUPPORT && !defined(QT_NO_SHORTCUT)
- if (d->use_compat() && d->qt_tryComposeUnicode(static_cast<QWidget*>(receiver), key))
- break;
-#endif
if (key->type()==QEvent::KeyPress) {
#ifndef QT_NO_SHORTCUT
// Try looking for a Shortcut before sending key events
diff --git a/src/widgets/kernel/qlayout.h b/src/widgets/kernel/qlayout.h
index 5d14aae58b..65fccb13fa 100644
--- a/src/widgets/kernel/qlayout.h
+++ b/src/widgets/kernel/qlayout.h
@@ -79,12 +79,6 @@ public:
SetFixedSize,
SetMaximumSize,
SetMinAndMaxSize
-#if defined(QT3_SUPPORT) && !defined(Q_MOC_RUN)
- , Auto = SetDefaultConstraint,
- FreeResize = SetNoConstraint,
- Minimum = SetMinimumSize,
- Fixed = SetFixedSize
-#endif
};
QLayout(QWidget *parent);
@@ -173,12 +167,10 @@ private:
//### support old includes
-#if 1 //def QT3_SUPPORT
QT_BEGIN_INCLUDE_NAMESPACE
#include <QtWidgets/qboxlayout.h>
#include <QtWidgets/qgridlayout.h>
QT_END_INCLUDE_NAMESPACE
-#endif
QT_END_NAMESPACE
diff --git a/src/widgets/kernel/qsizepolicy.qdoc b/src/widgets/kernel/qsizepolicy.qdoc
index 593560ee7f..f3e5e9f5e8 100644
--- a/src/widgets/kernel/qsizepolicy.qdoc
+++ b/src/widgets/kernel/qsizepolicy.qdoc
@@ -367,163 +367,3 @@
\sa setControlType(), controlType()
*/
-#ifdef QT3_SUPPORT
-/*!
- \typedef QSizePolicy::SizeType
- \compat
-
- Use the QSizePolicy::Policy enum instead.
-*/
-
-/*!
- \enum QSizePolicy::ExpandData
- \compat
-
- Use the Qt::Orientations enum instead.
-
- \value NoDirection Use 0 instead.
- \value Horizontally Use Qt::Horizontal instead.
- \value Vertically Use Qt::Vertical instead.
- \value BothDirections Use Qt::Horizontal | Qt::Vertical instead.
-*/
-
-/*!
- \fn bool QSizePolicy::mayShrinkHorizontally() const
-
- Use the horizontalPolicy() function combined with the
- QSizePolicy::PolicyFlag enum instead.
-
- \oldcode
- bool policy = mayShrinkHorizontally();
- \newcode
- bool policy = horizontalPolicy() & QSizePolicy::ShrinkFlag;
- \endcode
-*/
-
-/*!
- \fn bool QSizePolicy::mayShrinkVertically() const
-
- Use the verticalPolicy() function combined with the
- QSizePolicy::PolicyFlag enum instead.
-
- \oldcode
- bool policy = mayShrinkVertically();
- \newcode
- bool policy = verticalPolicy() & QSizePolicy::ShrinkFlag;
- \endcode
-*/
-
-/*!
- \fn bool QSizePolicy::mayGrowHorizontally() const
-
- Use the horizontalPolicy() function combined with the
- QSizePolicy::PolicyFlag enum instead.
-
- \oldcode
- bool policy = mayGrowHorizontally();
- \newcode
- bool policy = horizontalPolicy() & QSizePolicy::GrowFlag;
- \endcode
-*/
-
-/*!
- \fn bool QSizePolicy::mayGrowVertically() const
-
- Use the verticalPolicy() function combined with the
- QSizePolicy::PolicyFlag enum instead.
-
- \oldcode
- bool policy = mayGrowVertically();
- \newcode
- bool policy = verticalPolicy() & QSizePolicy::GrowFlag;
- \endcode
-*/
-
-/*!
- \fn Qt::QSizePolicy::Orientations QSizePolicy::expanding() const
-
- Use expandingDirections() instead.
-*/
-
-/*!
- \fn QSizePolicy::QSizePolicy(Policy horizontal, Policy vertical, bool dependent)
-
- Use the QSizePolicy() constructor and the setHeightForWidth()
- function instead.
-
- \oldcode
- QSizePolicy *policy = new QSizePolicy(horizontal, vertical, dependent);
- \newcode
- QSizePolicy *policy = new QSizePolicy(horizontal, vertical);
- policy->setHeightForWidth(dependent);
- \endcode
-*/
-
-/*!
- \fn QSizePolicy::QSizePolicy(Policy horizontal, Policy vertical, uchar horizontalStretch,
- uchar verticalStretch, bool dependent)
-
- Use the QSizePolicy() constructor and call the
- setHorizontalStretch(), setVerticalStretch(), and
- setHeightForWidth() functions instead.
-
- \oldcode
- QSizePolicy *policy = new QSizePolicy(horizontal, vertical,
- horizontalStretch, verticalStretch,
- dependent);
- \newcode
- QSizePolicy *policy = new QSizePolicy(horizontal, vertical);
- policy->setHorizontalStretch(horizontalStretch);
- policy->setVerticalStretch(verticalStretch);
- policy->setHeightForWidth(dependent);
- \endcode
-*/
-
-/*!
- \fn QSizePolicy::Policy QSizePolicy::horData() const
-
- Use horizontalPolicy() instead.
-*/
-
-/*!
- \fn QSizePolicy::Policy QSizePolicy::verData() const
-
- Use verticalPolicy() instead.
-*/
-
-/*!
- \fn void QSizePolicy::setHorData(Policy policy)
-
- Use setHorizontalPolicy() instead.
-*/
-
-/*!
- \fn void QSizePolicy::setVerData(Policy policy)
-
- Use setVerticalPolicy() instead.
-*/
-
-/*!
- \fn uint QSizePolicy::horStretch() const
-
- Use horizontalStretch() instead.
-*/
-
-/*!
- \fn uint QSizePolicy::verStretch() const
-
- Use verticalStretch() instead.
-*/
-
-/*!
- \fn void QSizePolicy::setHorStretch(uchar stretch)
-
- Use setHorizontalStretch() instead.
-*/
-
-/*!
- \fn void QSizePolicy::setVerStretch(uchar stretch)
-
- Use setVerticalStretch() instead.
-*/
-#endif
diff --git a/src/widgets/kernel/qwidget.cpp b/src/widgets/kernel/qwidget.cpp
index 4d6c44398b..981defeb07 100644
--- a/src/widgets/kernel/qwidget.cpp
+++ b/src/widgets/kernel/qwidget.cpp
@@ -1807,9 +1807,6 @@ void QWidgetPrivate::propagatePaletteChange()
wd->resolvePalette();
}
}
-#if defined(QT3_SUPPORT)
- q->paletteChange(q->palette()); // compatibility
-#endif
}
/*
@@ -3228,46 +3225,6 @@ void QWidget::setAcceptDrops(bool on)
}
-/*!
- \fn void QWidget::enabledChange(bool)
-
- \internal
- \obsolete
-*/
-
-/*!
- \fn void QWidget::paletteChange(const QPalette &)
-
- \internal
- \obsolete
-*/
-
-/*!
- \fn void QWidget::fontChange(const QFont &)
-
- \internal
- \obsolete
-*/
-
-/*!
- \fn void QWidget::windowActivationChange(bool)
-
- \internal
- \obsolete
-*/
-
-/*!
- \fn void QWidget::languageChange()
-
- \obsolete
-*/
-
-/*!
- \fn void QWidget::styleChange(QStyle& style)
-
- \internal
- \obsolete
-*/
/*!
Disables widget input events if \a disable is true; otherwise
@@ -11008,14 +10965,6 @@ void QWidget::stackUnder(QWidget* w)
QApplication::sendEvent(this, &e);
}
-void QWidget::styleChange(QStyle&) { }
-void QWidget::enabledChange(bool) { } // compat
-void QWidget::paletteChange(const QPalette &) { } // compat
-void QWidget::fontChange(const QFont &) { } // compat
-void QWidget::windowActivationChange(bool) { } // compat
-void QWidget::languageChange() { } // compat
-
-
/*!
\enum QWidget::BackgroundOrigin
diff --git a/src/widgets/kernel/qwidget.h b/src/widgets/kernel/qwidget.h
index 1e0e29eae9..a8722e9482 100644
--- a/src/widgets/kernel/qwidget.h
+++ b/src/widgets/kernel/qwidget.h
@@ -806,15 +806,6 @@ private:
#endif
QWidgetData *data;
-
-
-protected:
- virtual void styleChange(QStyle&); // compat
- virtual void enabledChange(bool); // compat
- virtual void paletteChange(const QPalette &); // compat
- virtual void fontChange(const QFont &); // compat
- virtual void windowActivationChange(bool); // compat
- virtual void languageChange(); // compat
};
Q_DECLARE_OPERATORS_FOR_FLAGS(QWidget::RenderFlags)
diff --git a/src/widgets/platforms/mac/qapplication_mac.mm b/src/widgets/platforms/mac/qapplication_mac.mm
index 5868849836..d77c01fc95 100644
--- a/src/widgets/platforms/mac/qapplication_mac.mm
+++ b/src/widgets/platforms/mac/qapplication_mac.mm
@@ -1350,15 +1350,6 @@ bool qt_wstate_iconified(WId)
extern QWidget * mac_mouse_grabber;
extern QWidget * mac_keyboard_grabber;
-#ifdef QT3_SUPPORT
-void QApplication::setMainWidget(QWidget *mainWidget)
-{
- QApplicationPrivate::main_widget = mainWidget;
- if (QApplicationPrivate::main_widget && windowIcon().isNull()
- && QApplicationPrivate::main_widget->testAttribute(Qt::WA_SetWindowIcon))
- setWindowIcon(QApplicationPrivate::main_widget->windowIcon());
-}
-#endif
#ifndef QT_NO_CURSOR
/*****************************************************************************
diff --git a/src/widgets/platforms/mac/qkeymapper_mac.cpp b/src/widgets/platforms/mac/qkeymapper_mac.cpp
index e96caf1b9d..75a36673be 100644
--- a/src/widgets/platforms/mac/qkeymapper_mac.cpp
+++ b/src/widgets/platforms/mac/qkeymapper_mac.cpp
@@ -970,36 +970,10 @@ QKeyMapper::sendKeyEvent(QWidget *widget, bool grab,
quint32 nativeModifiers, bool *isAccepted)
{
Q_UNUSED(count);
+ Q_UNUSED(grab);
+
if (widget && widget->isEnabled()) {
bool key_event = true;
-#if defined(QT3_SUPPORT) && !defined(QT_NO_SHORTCUT)
- if (type == QEvent::KeyPress && !grab
- && QApplicationPrivate::instance()->use_compat()) {
- QKeyEventEx accel_ev(type, code, modifiers,
- text, autorepeat, qMax(1, int(text.length())),
- nativeScanCode, nativeVirtualKey, nativeModifiers);
- if (QApplicationPrivate::instance()->qt_tryAccelEvent(widget, &accel_ev)) {
-#if defined(DEBUG_KEY_BINDINGS) || defined(DEBUG_KEY_BINDINGS_MODIFIERS)
- qDebug("KeyEvent: %s::%s consumed Accel: %s",
- widget ? widget->metaObject()->className() : "none",
- widget ? widget->objectName().toLatin1().constData() : "",
- text.toLatin1().constData());
-#endif
- key_event = false;
- } else {
- if (accel_ev.isAccepted()) {
-#if defined(DEBUG_KEY_BINDINGS) || defined(DEBUG_KEY_BINDINGS_MODIFIERS)
- qDebug("KeyEvent: %s::%s overrode Accel: %s",
- widget ? widget->metaObject()->className() : "none",
- widget ? widget->objectName().toLatin1().constData() : "",
- text.toLatin1().constData());
-#endif
- }
- }
- }
-#else
-Q_UNUSED(grab);
-#endif // QT3_SUPPORT && !QT_NO_SHORTCUT
if (key_event) {
#if defined(DEBUG_KEY_BINDINGS) || defined(DEBUG_KEY_BINDINGS_MODIFIERS)
qDebug("KeyEvent: Sending %s to %s::%s: %s 0x%08x%s",
diff --git a/src/widgets/platforms/mac/qwidget_mac.mm b/src/widgets/platforms/mac/qwidget_mac.mm
index 4adaa6b288..39a4895357 100644
--- a/src/widgets/platforms/mac/qwidget_mac.mm
+++ b/src/widgets/platforms/mac/qwidget_mac.mm
@@ -1381,9 +1381,6 @@ OSStatus QWidgetPrivate::qt_widget_event(EventHandlerCallRef er, EventRef event,
qrgn.translate(redirectionOffset);
QPaintEvent e(qrgn);
widget->d_func()->dirtyOnWidget = QRegion();
-#ifdef QT3_SUPPORT
- e.setErased(true);
-#endif
QApplication::sendSpontaneousEvent(widget, &e);
if (!redirectionOffset.isNull())
widget->d_func()->restoreRedirected();
diff --git a/src/widgets/platforms/win/qkeymapper_win.cpp b/src/widgets/platforms/win/qkeymapper_win.cpp
index 78389c1160..076b37038d 100644
--- a/src/widgets/platforms/win/qkeymapper_win.cpp
+++ b/src/widgets/platforms/win/qkeymapper_win.cpp
@@ -1168,24 +1168,8 @@ bool QKeyMapper::sendKeyEvent(QWidget *widget, bool grab,
quint32 nativeScanCode, quint32 nativeVirtualKey, quint32 nativeModifiers,
bool *)
{
-#if defined(Q_OS_WINCE)
Q_UNUSED(grab);
-#endif
Q_UNUSED(count);
-#if defined QT3_SUPPORT && !defined(QT_NO_SHORTCUT)
- if (type == QEvent::KeyPress
- && !grab
- && QApplicationPrivate::instance()->use_compat()) {
- // send accel events if the keyboard is not grabbed
- QKeyEventEx a(type, code, modifiers,
- text, autorepeat, qMax(1, int(text.length())),
- nativeScanCode, nativeVirtualKey, nativeModifiers);
- if (QApplicationPrivate::instance()->qt_tryAccelEvent(widget, &a))
- return true;
- }
-#else
- Q_UNUSED(grab);
-#endif
if (!widget->isEnabled())
return false;
diff --git a/src/widgets/platforms/x11/qkeymapper_x11.cpp b/src/widgets/platforms/x11/qkeymapper_x11.cpp
index 455840f8b2..7e348b3385 100644
--- a/src/widgets/platforms/x11/qkeymapper_x11.cpp
+++ b/src/widgets/platforms/x11/qkeymapper_x11.cpp
@@ -1708,18 +1708,6 @@ bool QKeyMapperPrivate::translateKeyEvent(QWidget *keyWidget, const XEvent *even
curr_autorep = autor ? event->xkey.keycode : 0;
}
-#if defined QT3_SUPPORT && !defined(QT_NO_SHORTCUT)
- // process accelerators before doing key compression
- if (type == QEvent::KeyPress && !grab
- && QApplicationPrivate::instance()->use_compat()) {
- // send accel events if the keyboard is not grabbed
- QKeyEventEx a(type, code, modifiers, text, autor, qMax(qMax(count,1), int(text.length())),
- event->xkey.keycode, keysym, event->xkey.state);
- if (QApplicationPrivate::instance()->qt_tryAccelEvent(keyWidget, &a))
- return true;
- }
-#endif
-
#ifndef QT_NO_IM
QInputContext *qic = keyWidget->inputContext();
#endif
diff --git a/src/widgets/styles/qmacstyle_mac.mm b/src/widgets/styles/qmacstyle_mac.mm
index 86b30cf7e0..6629ec0f29 100644
--- a/src/widgets/styles/qmacstyle_mac.mm
+++ b/src/widgets/styles/qmacstyle_mac.mm
@@ -389,9 +389,6 @@ static inline bool isTreeView(const QWidget *widget)
{
return (widget && widget->parentWidget() &&
(qobject_cast<const QTreeView *>(widget->parentWidget())
-#ifdef QT3_SUPPORT
- || widget->parentWidget()->inherits("Q3ListView")
-#endif
));
}
@@ -518,17 +515,9 @@ static QSize qt_aqua_get_known_size(QStyle::ContentsType ct, const QWidget *widg
ct = QStyle::CT_ProgressBar;
else if (qobject_cast<const QLineEdit *>(widg))
ct = QStyle::CT_LineEdit;
- else if (qobject_cast<const QHeaderView *>(widg)
-#ifdef QT3_SUPPORT
- || widg->inherits("Q3Header")
-#endif
- )
+ else if (qobject_cast<const QHeaderView *>(widg))
ct = QStyle::CT_HeaderSection;
- else if (qobject_cast<const QMenuBar *>(widg)
-#ifdef QT3_SUPPORT
- || widg->inherits("Q3MenuBar")
-#endif
- )
+ else if (qobject_cast<const QMenuBar *>(widg))
ct = QStyle::CT_MenuBar;
else if (qobject_cast<const QSizeGrip *>(widg))
ct = QStyle::CT_SizeGrip;
@@ -1476,11 +1465,7 @@ bool QMacStylePrivate::addWidget(QWidget *w)
startAnimate(AquaPushButton, btn);
return true;
} else {
- bool isProgressBar = (qobject_cast<QProgressBar *>(w)
-#ifdef QT3_SUPPORT
- || w->inherits("Q3ProgressBar")
-#endif
- );
+ bool isProgressBar = (qobject_cast<QProgressBar *>(w));
if (isProgressBar) {
w->installEventFilter(this);
startAnimate(AquaProgressBar, w);
@@ -1499,11 +1484,7 @@ void QMacStylePrivate::removeWidget(QWidget *w)
QPushButton *btn = qobject_cast<QPushButton *>(w);
if (btn && btn == defaultButton) {
stopAnimate(AquaPushButton, btn);
- } else if (qobject_cast<QProgressBar *>(w)
-#ifdef QT3_SUPPORT
- || w->inherits("Q3ProgressBar")
-#endif
- ) {
+ } else if (qobject_cast<QProgressBar *>(w)) {
stopAnimate(AquaProgressBar, w);
}
}
@@ -1548,21 +1529,6 @@ void QMacStylePrivate::timerEvent(QTimerEvent *)
pb->update();
}
}
-#ifdef QT3_SUPPORT
- else {
- // Watch me now...
- QVariant progress = maybeProgress->property("progress");
- QVariant totalSteps = maybeProgress->property("totalSteps");
- if (progress.isValid() && totalSteps.isValid()) {
- int intProgress = progress.toInt();
- int intTotalSteps = totalSteps.toInt();
- if (intTotalSteps == 0 || intProgress > 0 && intProgress < intTotalSteps) {
- if (doAnimate(AquaProgressBar))
- maybeProgress->update();
- }
- }
- }
-#endif
++i;
}
}
@@ -2012,9 +1978,6 @@ int QMacStyle::pixelMetric(PixelMetric metric, const QStyleOption *opt, const QW
|| (qobject_cast<const QMainWindow*>(widget->parentWidget())
&& static_cast<QMainWindow *>(widget->parentWidget())->centralWidget() == widget))
&& (qobject_cast<const QAbstractScrollArea *>(widget)
-#ifdef QT3_SUPPORT
- || widget->inherits("QScrollView")
-#endif
|| widget->inherits("QWorkspaceChild")))
ret = 0;
else
@@ -2378,9 +2341,6 @@ int QMacStyle::styleHint(StyleHint sh, const QStyleOption *opt, const QWidget *w
case SH_ScrollView_FrameOnlyAroundContents:
if (w && (w->isWindow() || !w->parentWidget() || w->parentWidget()->isWindow())
&& (w->inherits("QWorkspaceChild")
-#ifdef QT3_SUPPORT
- || w->inherits("QScrollView")
-#endif
))
ret = true;
else
diff --git a/src/widgets/widgets/qcombobox.h b/src/widgets/widgets/qcombobox.h
index f0cffc2fcf..e297dae1b5 100644
--- a/src/widgets/widgets/qcombobox.h
+++ b/src/widgets/widgets/qcombobox.h
@@ -124,15 +124,6 @@ public:
InsertAfterCurrent,
InsertBeforeCurrent,
InsertAlphabetically
-#if defined(QT3_SUPPORT) && !defined(Q_MOC_RUN)
- ,
- NoInsertion = NoInsert,
- AtTop = InsertAtTop,
- AtCurrent = InsertAtCurrent,
- AtBottom = InsertAtBottom,
- AfterCurrent = InsertAfterCurrent,
- BeforeCurrent = InsertBeforeCurrent
-#endif
};
InsertPolicy insertPolicy() const;
diff --git a/src/widgets/widgets/qframe.h b/src/widgets/widgets/qframe.h
index bee80403ab..4e11a6289b 100644
--- a/src/widgets/widgets/qframe.h
+++ b/src/widgets/widgets/qframe.h
@@ -83,15 +83,6 @@ public:
HLine = 0x0004, // horizontal line
VLine = 0x0005, // vertical line
StyledPanel = 0x0006 // rectangular panel depending on the GUI style
-
-#if defined(QT3_SUPPORT) && !defined(Q_MOC_RUN)
- ,PopupPanel = StyledPanel, // rectangular panel depending on the GUI style
- MenuBarPanel = StyledPanel,
- ToolBarPanel = StyledPanel,
- LineEditPanel = StyledPanel,
- TabWidgetPanel = StyledPanel,
- GroupBoxPanel = StyledPanel
-#endif
};
enum Shadow {
Plain = 0x0010, // plain line
@@ -102,10 +93,6 @@ public:
enum StyleMask {
Shadow_Mask = 0x00f0, // mask for the shadow
Shape_Mask = 0x000f // mask for the shape
-#if defined(QT3_SUPPORT)
- ,MShadow = Shadow_Mask,
- MShape = Shape_Mask
-#endif
};
Shape frameShape() const;
diff --git a/src/widgets/widgets/qlabel.cpp b/src/widgets/widgets/qlabel.cpp
index 8a698c528a..09bdc68511 100644
--- a/src/widgets/widgets/qlabel.cpp
+++ b/src/widgets/widgets/qlabel.cpp
@@ -1427,14 +1427,6 @@ Qt::LayoutDirection QLabelPrivate::textDirection() const
return text.isRightToLeft() ? Qt::RightToLeft : Qt::LeftToRight;
}
-/*!
- \fn void QLabel::setAlignment(Qt::AlignmentFlag flag)
- \internal
-
- Without this function, a call to e.g. setAlignment(Qt::AlignTop)
- results in the \c QT3_SUPPORT function setAlignment(int) being called,
- rather than setAlignment(Qt::Alignment).
-*/
// Returns the rect that is available for us to draw the document
QRect QLabelPrivate::documentRect() const
diff --git a/src/widgets/widgets/qlcdnumber.h b/src/widgets/widgets/qlcdnumber.h
index b48fbedc46..6af2b185ea 100644
--- a/src/widgets/widgets/qlcdnumber.h
+++ b/src/widgets/widgets/qlcdnumber.h
@@ -73,9 +73,6 @@ public:
enum Mode {
Hex, Dec, Oct, Bin
-#if defined(QT3_SUPPORT) && !defined(Q_MOC_RUN)
- , HEX = Hex, DEC = Dec, OCT = Oct, BIN = Bin
-#endif
};
enum SegmentStyle {
Outline, Filled, Flat
diff --git a/src/widgets/widgets/qslider.h b/src/widgets/widgets/qslider.h
index a4552d8cf5..c6620d253b 100644
--- a/src/widgets/widgets/qslider.h
+++ b/src/widgets/widgets/qslider.h
@@ -70,15 +70,6 @@ public:
TicksBelow = 2,
TicksRight = TicksBelow,
TicksBothSides = 3
-
-#if defined(QT3_SUPPORT) && !defined(Q_MOC_RUN)
- ,NoMarks = NoTicks,
- Above = TicksAbove,
- Left = TicksAbove,
- Below = TicksBelow,
- Right = TicksRight,
- Both = TicksBothSides
-#endif
};
explicit QSlider(QWidget *parent = 0);
diff --git a/src/widgets/widgets/qsplitter.cpp b/src/widgets/widgets/qsplitter.cpp
index 12c851b88b..864bf0debe 100644
--- a/src/widgets/widgets/qsplitter.cpp
+++ b/src/widgets/widgets/qsplitter.cpp
@@ -1673,7 +1673,6 @@ void QSplitter::setStretchFactor(int index, int stretch)
}
-//#ifdef QT3_SUPPORT
#ifndef QT_NO_TEXTSTREAM
/*!
\relates QSplitter
@@ -1706,7 +1705,6 @@ QTextStream& operator>>(QTextStream& ts, QSplitter& splitter)
return ts;
}
#endif // QT_NO_TEXTSTREAM
-//#endif // QT3_SUPPORT
QT_END_NAMESPACE
diff --git a/src/widgets/widgets/qsplitter.h b/src/widgets/widgets/qsplitter.h
index 7579e1a2c3..71252ede24 100644
--- a/src/widgets/widgets/qsplitter.h
+++ b/src/widgets/widgets/qsplitter.h
@@ -133,12 +133,10 @@ private:
friend class QSplitterHandle;
};
-//#ifdef QT3_SUPPORT
#ifndef QT_NO_TEXTSTREAM
Q_WIDGETS_EXPORT QTextStream& operator<<(QTextStream&, const QSplitter&);
Q_WIDGETS_EXPORT QTextStream& operator>>(QTextStream&, QSplitter&);
#endif
-//#endif
class QSplitterHandlePrivate;
class Q_WIDGETS_EXPORT QSplitterHandle : public QWidget
diff --git a/src/widgets/widgets/qtabbar.h b/src/widgets/widgets/qtabbar.h
index e5e8175733..d33e6bbb1b 100644
--- a/src/widgets/widgets/qtabbar.h
+++ b/src/widgets/widgets/qtabbar.h
@@ -80,10 +80,6 @@ public:
enum Shape { RoundedNorth, RoundedSouth, RoundedWest, RoundedEast,
TriangularNorth, TriangularSouth, TriangularWest, TriangularEast
-#if defined(QT3_SUPPORT) && !defined(Q_MOC_RUN)
- , RoundedAbove = RoundedNorth, RoundedBelow = RoundedSouth,
- TriangularAbove = TriangularNorth, TriangularBelow = TriangularSouth
-#endif
};
enum ButtonPosition {
diff --git a/src/widgets/widgets/qtabwidget.h b/src/widgets/widgets/qtabwidget.h
index 5ee6a38c80..ff734ed722 100644
--- a/src/widgets/widgets/qtabwidget.h
+++ b/src/widgets/widgets/qtabwidget.h
@@ -109,11 +109,7 @@ public:
int indexOf(QWidget *widget) const;
int count() const;
- enum TabPosition { North, South, West, East
-#if defined(QT3_SUPPORT) && !defined(Q_MOC_RUN)
- , Top = North, Bottom = South
-#endif
- };
+ enum TabPosition { North, South, West, East };
TabPosition tabPosition() const;
void setTabPosition(TabPosition);
diff --git a/src/widgets/widgets/qtextbrowser.h b/src/widgets/widgets/qtextbrowser.h
index 3f488975ec..b7ec942753 100644
--- a/src/widgets/widgets/qtextbrowser.h
+++ b/src/widgets/widgets/qtextbrowser.h
@@ -118,11 +118,6 @@ protected:
virtual bool focusNextPrevChild(bool next);
virtual void paintEvent(QPaintEvent *e);
-#if defined(QT3_SUPPORT)
-public:
- QT3_SUPPORT_CONSTRUCTOR QTextBrowser(QWidget *parent, const char *name);
-#endif
-
private:
Q_DISABLE_COPY(QTextBrowser)
Q_DECLARE_PRIVATE(QTextBrowser)
diff --git a/src/widgets/widgets/qtextedit.h b/src/widgets/widgets/qtextedit.h
index b3c1193c2b..1fcf87cdf7 100644
--- a/src/widgets/widgets/qtextedit.h
+++ b/src/widgets/widgets/qtextedit.h
@@ -104,28 +104,6 @@ public:
Q_DECLARE_FLAGS(AutoFormatting, AutoFormattingFlag)
-#if defined(QT3_SUPPORT)
- enum CursorAction {
- MoveBackward,
- MoveForward,
- MoveWordBackward,
- MoveWordForward,
- MoveUp,
- MoveDown,
- MoveLineStart,
- MoveLineEnd,
- MoveHome,
- MoveEnd,
- MovePageUp,
- MovePageDown
-#if !defined(Q_MOC_RUN)
- ,
- MovePgUp = MovePageUp,
- MovePgDown = MovePageDown
-#endif
- };
-#endif
-
explicit QTextEdit(QWidget *parent = 0);
explicit QTextEdit(const QString &text, QWidget *parent = 0);
virtual ~QTextEdit();