diff options
author | Abdiel Janulgue <abdiel.janulgue@nokia.com> | 2010-07-20 17:26:20 +0300 |
---|---|---|
committer | Abdiel Janulgue <abdiel.janulgue@nokia.com> | 2010-07-20 17:26:20 +0300 |
commit | 606c567d57367a286a185ba703010c0679ceb01f (patch) | |
tree | 12ba64436921697c77279377b602b090493534fa /src | |
parent | 67da0462edd4ac082c46e30fe44e56ac578b80a9 (diff) |
Changes: Move QGraphicsItem::shape() to base class MCompositeWindow
RevBy: TrustMe
Diffstat (limited to 'src')
-rw-r--r-- | src/mcompositewindow.cpp | 7 | ||||
-rw-r--r-- | src/mcompositewindow.h | 4 | ||||
-rw-r--r-- | src/mtexturepixmapitem.h | 1 | ||||
-rw-r--r-- | src/mtexturepixmapitem_egl.cpp | 7 | ||||
-rw-r--r-- | src/mtexturepixmapitem_glx.cpp | 7 |
5 files changed, 10 insertions, 16 deletions
diff --git a/src/mcompositewindow.cpp b/src/mcompositewindow.cpp index bbaff27..9cd3034 100644 --- a/src/mcompositewindow.cpp +++ b/src/mcompositewindow.cpp @@ -526,3 +526,10 @@ bool MCompositeWindow::isAppWindow(bool include_transients) return true; return false; } + +QPainterPath MCompositeWindow::shape() const +{ + QPainterPath path; + path.addRect(boundingRect()); + return path; +} diff --git a/src/mcompositewindow.h b/src/mcompositewindow.h index 5a2e216..9c9dca6 100644 --- a/src/mcompositewindow.h +++ b/src/mcompositewindow.h @@ -320,7 +320,9 @@ protected: virtual void hoverEnterEvent(QGraphicsSceneHoverEvent *); virtual void hoverLeaveEvent(QGraphicsSceneHoverEvent *); virtual void mouseReleaseEvent(QGraphicsSceneMouseEvent *); - virtual QVariant itemChange(GraphicsItemChange change, const QVariant &value); + virtual QVariant itemChange(GraphicsItemChange change, const QVariant &value); + virtual QPainterPath shape() const; + private: MWindowPropertyCache *pc; bool thumb_mode; diff --git a/src/mtexturepixmapitem.h b/src/mtexturepixmapitem.h index 83ad80a..63e602f 100644 --- a/src/mtexturepixmapitem.h +++ b/src/mtexturepixmapitem.h @@ -97,7 +97,6 @@ protected: QSizeF sizeHint(Qt::SizeHint, const QSizeF &) const; QRectF boundingRect() const; - QPainterPath shape() const; virtual void windowRaised(); private: diff --git a/src/mtexturepixmapitem_egl.cpp b/src/mtexturepixmapitem_egl.cpp index 864cba5..75d7046 100644 --- a/src/mtexturepixmapitem_egl.cpp +++ b/src/mtexturepixmapitem_egl.cpp @@ -380,13 +380,6 @@ QRectF MTexturePixmapItem::boundingRect() const return d->brect; } -QPainterPath MTexturePixmapItem::shape() const -{ - QPainterPath path; - path.addRect(boundingRect()); - return path; -} - void MTexturePixmapItem::clearTexture() { glBindTexture(GL_TEXTURE_2D, d->custom_tfp ? d->ctextureId : d->textureId); diff --git a/src/mtexturepixmapitem_glx.cpp b/src/mtexturepixmapitem_glx.cpp index cafac86..e103c49 100644 --- a/src/mtexturepixmapitem_glx.cpp +++ b/src/mtexturepixmapitem_glx.cpp @@ -350,13 +350,6 @@ QRectF MTexturePixmapItem::boundingRect() const return d->brect; } -QPainterPath MTexturePixmapItem::shape() const -{ - QPainterPath path; - path.addRect(boundingRect()); - return path; -} - void MTexturePixmapItem::clearTexture() { glBindTexture(GL_TEXTURE_2D, d->custom_tfp ? d->ctextureId : d->textureId); |