commit | f2995e72f47e2d5e279955aacae59547273c6cea | [log] [tgz] |
---|---|---|
author | Yi Kong <yikong@google.com> | Thu May 04 00:21:10 2017 +0000 |
committer | android-build-merger <android-build-merger@google.com> | Thu May 04 00:21:10 2017 +0000 |
tree | f954ebdbc634c9c4fc265b5d6fc2524b59d59095 | |
parent | 21ea7683bc4d8515c03231ad9f2b84996b97fede [diff] | |
parent | 40f0088f4568fb005c12d37d1deb023d55baac79 [diff] |
Merge "Add const specifier to SortLayersByZ comparator" am: 40f0088f45 Change-Id: Ia7316e218e388b6f3760374751b32bb992c6441a
diff --git a/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.cpp b/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.cpp index 617ea9f..7f48289 100644 --- a/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.cpp +++ b/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.cpp
@@ -1993,9 +1993,8 @@ mHasUnsupportedDataspace(false), mHasUnsupportedPlaneAlpha(false) {} -bool HWC2On1Adapter::SortLayersByZ::operator()( - const std::shared_ptr<Layer>& lhs, const std::shared_ptr<Layer>& rhs) -{ +bool HWC2On1Adapter::SortLayersByZ::operator()(const std::shared_ptr<Layer>& lhs, + const std::shared_ptr<Layer>& rhs) const { return lhs->getZ() < rhs->getZ(); }
diff --git a/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.h b/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.h index 962361e..45922af 100644 --- a/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.h +++ b/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.h
@@ -123,7 +123,7 @@ class SortLayersByZ { public: bool operator()(const std::shared_ptr<Layer>& lhs, - const std::shared_ptr<Layer>& rhs); + const std::shared_ptr<Layer>& rhs) const; }; class DisplayContentsDeleter {