~compiz-team/compiz/0.9.9

« back to all changes in this revision

Viewing changes to plugins/opengl/src/paint.cpp

  • Committer: Tarmac
  • Author(s): Daniel van Vugt
  • Date: 2012-09-21 08:29:44 UTC
  • mfrom: (3382.1.2 fix-1047168)
  • Revision ID: tarmac-20120921082944-44dp8m7ruhd37ogl
Ensure unredirected windows get redirected if windows are being transformed, 
like in scale mode.
(LP: #1047168)
. Fixes: https://bugs.launchpad.net/bugs/1047168. Approved by Sam Spilsbury.

Show diffs side-by-side

added added

removed removed

Lines of Context:
352
352
             */
353
353
            if (unredirectFS &&
354
354
                !(mask & PAINT_SCREEN_TRANSFORMED_MASK) &&
 
355
                !(mask & PAINT_SCREEN_WITH_TRANSFORMED_WINDOWS_MASK) &&
355
356
                fs.isCoveredBy (w->region (), flags))
356
357
            {
357
358
                unredirected.insert (w);
618
619
 
619
620
        sTransform.toScreenSpace (output, -DEFAULT_Z_CAMERA);
620
621
 
621
 
        if (!region.isEmpty ())
 
622
        /*
 
623
         * Sometimes region might be empty but we still need to force the
 
624
         * repaint. This can happen when a fullscreen window is unredirected,
 
625
         * and damageScreen is called. CompositeScreen::handlePaintTimeout
 
626
         * then subtracts the whole screen of damage because it's an overlay
 
627
         * and we're left with an empty damage region.
 
628
         * Even when this happens we may want to force the repaint if
 
629
         * windows are getting transformed (and so the unredirected window
 
630
         * needs to be redirected again).
 
631
         */
 
632
        if (!region.isEmpty () ||
 
633
            (mask & PAINT_SCREEN_FULL_MASK) ||
 
634
            (mask & PAINT_SCREEN_WITH_TRANSFORMED_WINDOWS_MASK))
622
635
            priv->paintOutputRegion (sTransform, region, output, mask);
623
636
 
624
637
        return true;