[platforms/hwcomposer] Use enum instead of the number for readable code

Summary: Enums taken from hardware/hwcomposer_defs.h header file

Test Plan: builds

Reviewers: #kwin, graesslin, mart

Reviewed By: mart

Subscribers: kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D3699
This commit is contained in:
Bhushan Shah 2016-12-16 14:36:43 +05:30
parent 71b6ebcfef
commit 62b4517f1d

View file

@ -320,7 +320,7 @@ void HwcomposerBackend::toggleBlankOutput()
#if defined(HWC_DEVICE_API_VERSION_1_4) || defined(HWC_DEVICE_API_VERSION_1_5)
if (m_hwcVersion > HWC_DEVICE_API_VERSION_1_3)
m_device->setPowerMode(m_device, 0, m_outputBlank ? 0 : 2);
m_device->setPowerMode(m_device, 0, m_outputBlank ? HWC_POWER_MODE_OFF : HWC_POWER_MODE_NORMAL);
else
#endif
m_device->blank(m_device, 0, m_outputBlank ? 1 : 0);