[sf] Fix blur alpha for new sf frontend
- update the blur alpha when alpha changes
- also update layer stack ordering to match legacy order
Test: presubmit
Bug: 238781169
Change-Id: I6d122a9721a3de0f8b04e60ac21fa879b29b22e3
diff --git a/services/surfaceflinger/FrontEnd/LayerHierarchy.cpp b/services/surfaceflinger/FrontEnd/LayerHierarchy.cpp
index c30465f..5913d4b 100644
--- a/services/surfaceflinger/FrontEnd/LayerHierarchy.cpp
+++ b/services/surfaceflinger/FrontEnd/LayerHierarchy.cpp
@@ -30,7 +30,7 @@
auto lhsLayer = lhs.first->getLayer();
auto rhsLayer = rhs.first->getLayer();
if (lhsLayer->layerStack.id != rhsLayer->layerStack.id) {
- return lhsLayer->layerStack.id > rhsLayer->layerStack.id;
+ return lhsLayer->layerStack.id < rhsLayer->layerStack.id;
}
if (lhsLayer->z != rhsLayer->z) {
return lhsLayer->z < rhsLayer->z;