Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ae879b5a authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Automerger Merge Worker
Browse files

Merge "SF: Allow display layer clip bounds to be overriden" into rvc-dev am:...

Merge "SF: Allow display layer clip bounds to be overriden" into rvc-dev am: 7cfab4e3 am: b32210f3 am: 782caa3c

Change-Id: Iadc642804ac5b4c60077f890546a1f3b10f66bdd
parents 241408a0 782caa3c
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -2364,6 +2364,10 @@ void SurfaceFlinger::postComposition()
    }
}

FloatRect SurfaceFlinger::getLayerClipBoundsForDisplay(const DisplayDevice& displayDevice) const {
    return displayDevice.getViewport().toFloatRect();
}

void SurfaceFlinger::computeLayerBounds() {
    for (const auto& pair : mDisplays) {
        const auto& displayDevice = pair.second;
@@ -2374,7 +2378,7 @@ void SurfaceFlinger::computeLayerBounds() {
                continue;
            }

            layer->computeBounds(displayDevice->getViewport().toFloatRect(), ui::Transform(),
            layer->computeBounds(getLayerClipBoundsForDisplay(*displayDevice), ui::Transform(),
                                 0.f /* shadowRadius */);
        }
    }
+7 −0
Original line number Diff line number Diff line
@@ -643,6 +643,13 @@ protected:
            REQUIRES(mStateLock);
    virtual void commitTransactionLocked();

    // Used internally by computeLayerBounds() to gets the clip rectangle to use for the
    // root layers on a particular display in layer-coordinate space. The
    // layers (and effectively their children) will be clipped against this
    // rectangle. The base behavior is to clip to the visible region of the
    // display.
    virtual FloatRect getLayerClipBoundsForDisplay(const DisplayDevice&) const;

private:
    /* ------------------------------------------------------------------------
     * Layer management