~linaro-graphics-wg/compiz-plugins-main/linaro-gles2

« back to all changes in this revision

Viewing changes to animation/src/animation.cpp

  • Committer: Alexandros Frantzis
  • Date: 2012-04-10 16:22:15 UTC
  • Revision ID: alexandros.frantzis@linaro.org-20120410162215-l8xcvbvehhj5m02b
Sync with (not yet released) 1:0.9.7.0~bzr19-0ubuntu10 package.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1319
1319
        mLastRedrawTime = curTime; // Store current time for next time
1320
1320
        mLastRedrawTimeFresh = true;
1321
1321
 
1322
 
        bool animStillInProgress = false;
1323
 
 
1324
1322
        /* Paint list includes destroyed windows */
1325
1323
        for (CompWindowList::const_reverse_iterator rit = pl.rbegin ();
1326
1324
             rit != pl.rend (); rit++)
1335
1333
                if (!curAnim->initialized ())
1336
1334
                    curAnim->init ();
1337
1335
 
1338
 
                if (curAnim->prePreparePaint (msSinceLastPaint))
1339
 
                    animStillInProgress = true;
 
1336
                curAnim->prePreparePaint (msSinceLastPaint);
1340
1337
 
1341
1338
                /* TODO optimize grid model by reusing one GridModel
1342
1339
                if (aw->com.mModel &&
1399
1396
                bool finished = (curAnim->remainingTime () <= 0);
1400
1397
                if (finished) // Animation is done
1401
1398
                    windowsFinishedAnimations.push_back (w);
1402
 
                else
1403
 
                    animStillInProgress = true;
1404
1399
            }
1405
1400
        }
1406
1401
 
1632
1627
 
1633
1628
    //w->indexCount = 0; // TODO check if this is still necessary
1634
1629
 
1635
 
    // TODO: should only happen for distorting effects
1636
 
    mask |= PAINT_WINDOW_TRANSFORMED_MASK;
 
1630
    if (mCurAnimation->requiresTransformedWindow ())
 
1631
        mask |= PAINT_WINDOW_TRANSFORMED_MASK;
1637
1632
 
1638
1633
    wAttrib.xScale = 1.0f;
1639
1634
    wAttrib.yScale = 1.0f;
1660
1655
{
1661
1656
    if (!mLockedPaintListCnt)
1662
1657
    {
1663
 
        mLockedPaintList = &cScreen->getWindowPaintList ();
 
1658
        const CompWindowList &pl = cScreen->getWindowPaintList ();
 
1659
        mLockedPaintList = &pl;
1664
1660
 
1665
1661
        if (!mGetWindowPaintListEnableCnt)
1666
1662
        {
2805
2801
                if (mPAScreen->shouldIgnoreWindowForAnim (mWindow, true))
2806
2802
                    break;
2807
2803
 
2808
 
                if (AnimEffectNone ==
2809
 
                    mPAScreen->getMatchingAnimSelection (mWindow,
2810
 
                                                         AnimEventClose,
2811
 
                                                         &duration))
 
2804
                /* Don't increment the destroy reference count unless
 
2805
                 * the window is already animated */
 
2806
                if (!mCurAnimation)
2812
2807
                    break;
2813
2808
 
2814
2809
                mDestroyCnt++;