summaryrefslogtreecommitdiffstats
path: root/src/gui/graphicsview
diff options
context:
space:
mode:
authorThierry Bastian <thierry.bastian@nokia.com>2009-06-11 11:39:09 (GMT)
committerThierry Bastian <thierry.bastian@nokia.com>2009-06-11 14:07:03 (GMT)
commit35e2a2978a2318ca025393a8f67d30746c8b78fc (patch)
treef96f760ebd7e9c9f7a1f8d5f4400a03a1ae69e44 /src/gui/graphicsview
parent3f7a7c20c8493f62e090e703acfd581a4e3c4d2e (diff)
downloadQt-35e2a2978a2318ca025393a8f67d30746c8b78fc.zip
Qt-35e2a2978a2318ca025393a8f67d30746c8b78fc.tar.gz
Qt-35e2a2978a2318ca025393a8f67d30746c8b78fc.tar.bz2
Removed qApp and replaced with QApplication:: for static member calls
Diffstat (limited to 'src/gui/graphicsview')
-rw-r--r--src/gui/graphicsview/qgraphicsgridlayout.cpp2
-rw-r--r--src/gui/graphicsview/qgraphicslinearlayout.cpp2
-rw-r--r--src/gui/graphicsview/qgraphicsscene.cpp16
3 files changed, 10 insertions, 10 deletions
diff --git a/src/gui/graphicsview/qgraphicsgridlayout.cpp b/src/gui/graphicsview/qgraphicsgridlayout.cpp
index 1e21b54..36281f8 100644
--- a/src/gui/graphicsview/qgraphicsgridlayout.cpp
+++ b/src/gui/graphicsview/qgraphicsgridlayout.cpp
@@ -100,7 +100,7 @@ QLayoutStyleInfo QGraphicsGridLayoutPrivate::styleInfo() const
if (!wid)
wid = new QWidget;
QGraphicsItem *item = parentItem();
- QStyle *style = (item && item->isWidget()) ? static_cast<QGraphicsWidget*>(item)->style() : qApp->style();
+ QStyle *style = (item && item->isWidget()) ? static_cast<QGraphicsWidget*>(item)->style() : QApplication::style();
return QLayoutStyleInfo(style, wid);
}
diff --git a/src/gui/graphicsview/qgraphicslinearlayout.cpp b/src/gui/graphicsview/qgraphicslinearlayout.cpp
index 6a2d456..2f32950 100644
--- a/src/gui/graphicsview/qgraphicslinearlayout.cpp
+++ b/src/gui/graphicsview/qgraphicslinearlayout.cpp
@@ -178,7 +178,7 @@ QLayoutStyleInfo QGraphicsLinearLayoutPrivate::styleInfo() const
if (!wid)
wid = new QWidget;
QGraphicsItem *item = parentItem();
- QStyle *style = (item && item->isWidget()) ? static_cast<QGraphicsWidget*>(item)->style() : qApp->style();
+ QStyle *style = (item && item->isWidget()) ? static_cast<QGraphicsWidget*>(item)->style() : QApplication::style();
return QLayoutStyleInfo(style, wid);
}
diff --git a/src/gui/graphicsview/qgraphicsscene.cpp b/src/gui/graphicsview/qgraphicsscene.cpp
index e6c3503..1c48675 100644
--- a/src/gui/graphicsview/qgraphicsscene.cpp
+++ b/src/gui/graphicsview/qgraphicsscene.cpp
@@ -2161,7 +2161,7 @@ void QGraphicsScenePrivate::setFont_helper(const QFont &font)
*/
void QGraphicsScenePrivate::resolveFont()
{
- QFont naturalFont = qApp->font();
+ QFont naturalFont = QApplication::font();
naturalFont.resolve(0);
QFont resolvedFont = font.resolve(naturalFont);
updateFont(resolvedFont);
@@ -2217,7 +2217,7 @@ void QGraphicsScenePrivate::setPalette_helper(const QPalette &palette)
*/
void QGraphicsScenePrivate::resolvePalette()
{
- QPalette naturalPalette = qApp->palette();
+ QPalette naturalPalette = QApplication::palette();
naturalPalette.resolve(0);
QPalette resolvedPalette = palette.resolve(naturalPalette);
updatePalette(resolvedPalette);
@@ -3975,10 +3975,10 @@ bool QGraphicsScene::eventFilter(QObject *watched, QEvent *event)
switch (event->type()) {
case QEvent::ApplicationPaletteChange:
- qApp->postEvent(this, new QEvent(QEvent::ApplicationPaletteChange));
+ QApplication::postEvent(this, new QEvent(QEvent::ApplicationPaletteChange));
break;
case QEvent::ApplicationFontChange:
- qApp->postEvent(this, new QEvent(QEvent::ApplicationFontChange));
+ QApplication::postEvent(this, new QEvent(QEvent::ApplicationFontChange));
break;
default:
break;
@@ -4918,7 +4918,7 @@ void QGraphicsScenePrivate::drawItemHelper(QGraphicsItem *item, QPainter *painte
bool allowPartialCacheExposure = !viewRect.contains(deviceRect);
#else
// Only if deviceRect is 20% taller or wider than the desktop.
- QRect desktopRect = qApp->desktop()->availableGeometry(widget);
+ QRect desktopRect = QApplication::desktop()->availableGeometry(widget);
bool allowPartialCacheExposure = (desktopRect.width() * 1.2 < deviceRect.width()
|| desktopRect.height() * 1.2 < deviceRect.height());
#endif
@@ -5606,7 +5606,7 @@ QStyle *QGraphicsScene::style() const
{
Q_D(const QGraphicsScene);
// ### This function, and the use of styles in general, is non-reentrant.
- return d->style ? d->style : qApp->style();
+ return d->style ? d->style : QApplication::style();
}
/*!
@@ -5683,7 +5683,7 @@ QFont QGraphicsScene::font() const
void QGraphicsScene::setFont(const QFont &font)
{
Q_D(QGraphicsScene);
- QFont naturalFont = qApp->font();
+ QFont naturalFont = QApplication::font();
naturalFont.resolve(0);
QFont resolvedFont = font.resolve(naturalFont);
d->setFont_helper(resolvedFont);
@@ -5720,7 +5720,7 @@ QPalette QGraphicsScene::palette() const
void QGraphicsScene::setPalette(const QPalette &palette)
{
Q_D(QGraphicsScene);
- QPalette naturalPalette = qApp->palette();
+ QPalette naturalPalette = QApplication::palette();
naturalPalette.resolve(0);
QPalette resolvedPalette = palette.resolve(naturalPalette);
d->setPalette_helper(resolvedPalette);