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

Commit 5f97b088 authored by Saurabh Shah's avatar Saurabh Shah Committed by Steve Kondik
Browse files

SF: Check ViewFrame validity before sending to hwc

Check if ViewFrame is valid before sending to hwc to make sure
composition produces valid values.

A ViewFrame can get invalid values when the framework is disconnected
which is a step necessary for some testing scenarios.

Change-Id: I2ad76061b6664dbb7d2aa3d66acaf99b880aedfe
parent 33a45704
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1347,7 +1347,8 @@ void SurfaceFlinger::handleTransactionLocked(uint32_t transactionFlags)
                            }
                            // Set the view frame of each display only of its
                            // default orientation.
                            if(orient == DisplayState::eOrientationDefault) {
                            if(orient == DisplayState::eOrientationDefault and
                                    state.frame.isValid()) {
                                qdutils::setViewFrame(disp->getHwcDisplayId(),
                                    state.frame.left, state.frame.top,
                                    state.frame.right, state.frame.bottom);