drm_hwcomposer: treewide: Handle bool properties in the Property class
To clean things up and unify the usage of properties.
Change-Id: I0e034ed309f5f8a0d4fc9be7a4a3edcb39050e7f
Signed-off-by: Roman Stratiienko <r.stratiienko@gmail.com>
diff --git a/drm/ResourceManager.cpp b/drm/ResourceManager.cpp
index 0c23734..9c68816 100644
--- a/drm/ResourceManager.cpp
+++ b/drm/ResourceManager.cpp
@@ -76,10 +76,9 @@
}
}
- char proptext[PROPERTY_VALUE_MAX];
- property_get("vendor.hwc.drm.scale_with_gpu", proptext, "0");
- scale_with_gpu_ = bool(strncmp(proptext, "0", 1));
+ scale_with_gpu_ = Properties::ScaleWithGpu();
+ char proptext[PROPERTY_VALUE_MAX];
constexpr char kDrmOrGpu[] = "DRM_OR_GPU";
constexpr char kDrmOrIgnore[] = "DRM_OR_IGNORE";
property_get("vendor.hwc.drm.ctm", proptext, kDrmOrGpu);