summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorSamuel Rødal <sroedal@trolltech.com>2009-11-10 12:35:42 (GMT)
committerDavid Boddie <dboddie@trolltech.com>2009-11-11 16:06:55 (GMT)
commit3b93dfa8c64a209456f8ba2cde6e0edca27c6b42 (patch)
tree3cc8b509ac15ce1d7408cd24a3be24a3013daf7c /examples
parent71f5f5f62463c70bba76485ef07e930829423997 (diff)
downloadQt-3b93dfa8c64a209456f8ba2cde6e0edca27c6b42.zip
Qt-3b93dfa8c64a209456f8ba2cde6e0edca27c6b42.tar.gz
Qt-3b93dfa8c64a209456f8ba2cde6e0edca27c6b42.tar.bz2
Improvements to graphics effects API after review round.
* Get rid of QGraphicsEffectSource from the public API, instead add convenience functions in QGraphicsEffect. This way we commit to less API, and are free to introduce a customizable QGraphicsEffectSource in a future release. * Move PixmapPadMode into QGraphicsEffect and tweak the names of the enum values. * Make QGraphicsBlurEffect::BlurHint into a bit flag, for extensibility. Reviewed-by: Bjørn Erik Nilsen
Diffstat (limited to 'examples')
-rw-r--r--examples/effects/blurpicker/blureffect.cpp4
-rw-r--r--examples/effects/blurpicker/blureffect.h2
-rw-r--r--examples/effects/customshader/blureffect.cpp4
-rw-r--r--examples/effects/customshader/blureffect.h2
4 files changed, 6 insertions, 6 deletions
diff --git a/examples/effects/blurpicker/blureffect.cpp b/examples/effects/blurpicker/blureffect.cpp
index 9046cbd..956637d 100644
--- a/examples/effects/blurpicker/blureffect.cpp
+++ b/examples/effects/blurpicker/blureffect.cpp
@@ -62,8 +62,8 @@ QRectF BlurEffect::boundingRect() const
return QGraphicsBlurEffect::boundingRect();
}
-void BlurEffect::draw(QPainter *painter, QGraphicsEffectSource *source)
+void BlurEffect::draw(QPainter *painter)
{
adjustForItem();
- QGraphicsBlurEffect::draw(painter, source);
+ QGraphicsBlurEffect::draw(painter);
}
diff --git a/examples/effects/blurpicker/blureffect.h b/examples/effects/blurpicker/blureffect.h
index 6cfa55a..3d1d433 100644
--- a/examples/effects/blurpicker/blureffect.h
+++ b/examples/effects/blurpicker/blureffect.h
@@ -54,7 +54,7 @@ public:
QRectF boundingRect() const;
- void draw(QPainter *painter, QGraphicsEffectSource *source);
+ void draw(QPainter *painter);
private:
void adjustForItem();
diff --git a/examples/effects/customshader/blureffect.cpp b/examples/effects/customshader/blureffect.cpp
index 9046cbd..956637d 100644
--- a/examples/effects/customshader/blureffect.cpp
+++ b/examples/effects/customshader/blureffect.cpp
@@ -62,8 +62,8 @@ QRectF BlurEffect::boundingRect() const
return QGraphicsBlurEffect::boundingRect();
}
-void BlurEffect::draw(QPainter *painter, QGraphicsEffectSource *source)
+void BlurEffect::draw(QPainter *painter)
{
adjustForItem();
- QGraphicsBlurEffect::draw(painter, source);
+ QGraphicsBlurEffect::draw(painter);
}
diff --git a/examples/effects/customshader/blureffect.h b/examples/effects/customshader/blureffect.h
index 6cfa55a..3d1d433 100644
--- a/examples/effects/customshader/blureffect.h
+++ b/examples/effects/customshader/blureffect.h
@@ -54,7 +54,7 @@ public:
QRectF boundingRect() const;
- void draw(QPainter *painter, QGraphicsEffectSource *source);
+ void draw(QPainter *painter);
private:
void adjustForItem();