install drawfilter for the picture playback as well
git-svn-id: http://skia.googlecode.com/svn/trunk@2839 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
parent
0e734bdc42
commit
e23f194bf9
@ -1052,6 +1052,7 @@ void SampleWindow::afterChildren(SkCanvas* orig) {
|
||||
if (true) {
|
||||
SkPicture* pict = new SkPicture(*fPicture);
|
||||
fPicture->unref();
|
||||
this->installDrawFilter(orig);
|
||||
orig->drawPicture(*pict);
|
||||
pict->unref();
|
||||
} else if (true) {
|
||||
@ -1141,8 +1142,7 @@ void SampleWindow::beforeChild(SkView* child, SkCanvas* canvas) {
|
||||
canvas->concat(m);
|
||||
}
|
||||
|
||||
canvas->setDrawFilter(new FlagsDrawFilter(fLCDState, fAAState,
|
||||
fFilterState, fHintingState))->unref();
|
||||
this->installDrawFilter(canvas);
|
||||
|
||||
if (fMeasureFPS) {
|
||||
fMeasureFPS_Time = 0; // 0 means the child is not aware of repeat-draw
|
||||
@ -1263,11 +1263,17 @@ void SampleWindow::showOverview() {
|
||||
4));
|
||||
}
|
||||
|
||||
void SampleWindow::installDrawFilter(SkCanvas* canvas) {
|
||||
canvas->setDrawFilter(new FlagsDrawFilter(fLCDState, fAAState,
|
||||
fFilterState, fHintingState))->unref();
|
||||
}
|
||||
|
||||
void SampleWindow::postAnimatingEvent() {
|
||||
if (fAnimating) {
|
||||
(new SkEvent(ANIMATING_EVENTTYPE, this->getSinkID()))->postDelay(ANIMATING_DELAY);
|
||||
}
|
||||
}
|
||||
|
||||
bool SampleWindow::onEvent(const SkEvent& evt) {
|
||||
if (evt.isType(gUpdateWindowTitleEvtName)) {
|
||||
this->updateTitle();
|
||||
|
@ -189,6 +189,7 @@ private:
|
||||
void showZoomer(SkCanvas* canvas);
|
||||
void updateMatrix();
|
||||
void postAnimatingEvent();
|
||||
void installDrawFilter(SkCanvas*);
|
||||
|
||||
typedef SkOSWindow INHERITED;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user