summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel
diff options
context:
space:
mode:
authorThomas Hartmann <Thomas.Hartmann@nokia.com>2009-11-04 12:09:30 (GMT)
committerJoerg Bornemann <joerg.bornemann@nokia.com>2009-11-06 12:50:37 (GMT)
commit6cd1a36774605afaa37d8e3edf870f9133e1cf3e (patch)
treef4696179d77e20b589e5b031bad859b90fa1cd7c /src/gui/kernel
parent5491ab9c921c8e7b89e335c7d09219153ae1d21a (diff)
downloadQt-6cd1a36774605afaa37d8e3edf870f9133e1cf3e.zip
Qt-6cd1a36774605afaa37d8e3edf870f9133e1cf3e.tar.gz
Qt-6cd1a36774605afaa37d8e3edf870f9133e1cf3e.tar.bz2
compilefixes for qfeatures
Reviewed-by: Maurice
Diffstat (limited to 'src/gui/kernel')
-rw-r--r--src/gui/kernel/qsoftkeymanager.cpp4
-rw-r--r--src/gui/kernel/qwidget_win.cpp14
2 files changed, 16 insertions, 2 deletions
diff --git a/src/gui/kernel/qsoftkeymanager.cpp b/src/gui/kernel/qsoftkeymanager.cpp
index 21795b4..e970d2f 100644
--- a/src/gui/kernel/qsoftkeymanager.cpp
+++ b/src/gui/kernel/qsoftkeymanager.cpp
@@ -137,12 +137,14 @@ QAction *QSoftKeyManager::createAction(StandardSoftKey standardKey, QWidget *act
*/
QAction *QSoftKeyManager::createKeyedAction(StandardSoftKey standardKey, Qt::Key key, QWidget *actionWidget)
{
+#ifndef QT_NO_ACTION
QScopedPointer<QAction> action(createAction(standardKey, actionWidget));
connect(action.data(), SIGNAL(triggered()), QSoftKeyManager::instance(), SLOT(sendKeyEvent()));
connect(action.data(), SIGNAL(destroyed(QObject*)), QSoftKeyManager::instance(), SLOT(cleanupHash(QObject*)));
QSoftKeyManager::instance()->d_func()->keyedActions.insert(action.data(), key);
return action.take();
+#endif //QT_NO_ACTION
}
void QSoftKeyManager::cleanupHash(QObject* obj)
@@ -175,6 +177,7 @@ void QSoftKeyManager::updateSoftKeys()
bool QSoftKeyManager::event(QEvent *e)
{
+#ifndef QT_NO_ACTION
if (e->type() == QEvent::UpdateSoftKeys) {
QList<QAction*> softKeys;
QWidget *source = QApplication::focusWidget();
@@ -201,6 +204,7 @@ bool QSoftKeyManager::event(QEvent *e)
QSoftKeyManagerPrivate::updateSoftKeys_sys(softKeys);
return true;
}
+#endif //QT_NO_ACTION
return false;
}
diff --git a/src/gui/kernel/qwidget_win.cpp b/src/gui/kernel/qwidget_win.cpp
index 22a94b9..2bdaddb 100644
--- a/src/gui/kernel/qwidget_win.cpp
+++ b/src/gui/kernel/qwidget_win.cpp
@@ -677,7 +677,11 @@ QPoint QWidget::mapToGlobal(const QPoint &pos) const
QWidget *parentWindow = window();
QWExtra *extra = parentWindow->d_func()->extra;
if (!isVisible() || parentWindow->isMinimized() || !testAttribute(Qt::WA_WState_Created) || !internalWinId()
- || (extra && extra->proxyWidget)) {
+ || (extra
+#ifndef QT_NO_GRAPHICSVIEW
+ && extra->proxyWidget
+#endif //QT_NO_GRAPHICSVIEW
+ )) {
if (extra && extra->topextra && extra->topextra->embedded) {
QPoint pt = mapTo(parentWindow, pos);
POINT p = {pt.x(), pt.y()};
@@ -704,7 +708,11 @@ QPoint QWidget::mapFromGlobal(const QPoint &pos) const
QWidget *parentWindow = window();
QWExtra *extra = parentWindow->d_func()->extra;
if (!isVisible() || parentWindow->isMinimized() || !testAttribute(Qt::WA_WState_Created) || !internalWinId()
- || (extra && extra->proxyWidget)) {
+ || (extra
+#ifndef QT_NO_GRAPHICSVIEW
+ && extra->proxyWidget
+#endif //QT_NO_GRAPHICSVIEW
+ )) {
if (extra && extra->topextra && extra->topextra->embedded) {
POINT p = {pos.x(), pos.y()};
ScreenToClient(parentWindow->effectiveWinId(), &p);
@@ -2042,6 +2050,7 @@ void QWidgetPrivate::winSetupGestures()
bool needv = false;
bool singleFingerPanEnabled = false;
+#ifndef QT_NO_SCROLLAREA
if (QAbstractScrollArea *asa = qobject_cast<QAbstractScrollArea*>(q->parent())) {
QScrollBar *hbar = asa->horizontalScrollBar();
QScrollBar *vbar = asa->verticalScrollBar();
@@ -2055,6 +2064,7 @@ void QWidgetPrivate::winSetupGestures()
if (!winid)
winid = q->winId(); // enforces the native winid on the viewport
}
+#endif //QT_NO_SCROLLAREA
if (winid && qAppPriv->SetGestureConfig) {
GESTURECONFIG gc[1];
memset(gc, 0, sizeof(gc));