New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[lipstick] devicelock to handle blanking states for home2. Contribute… #307
Conversation
Note for reviewers: matching changes in jolla-home can be found in "keep-lock"-branch. |
@@ -31,7 +31,7 @@ BuildRequires: pkgconfig(Qt5Test) | |||
BuildRequires: pkgconfig(Qt5Sensors) | |||
BuildRequires: pkgconfig(contentaction5) | |||
BuildRequires: pkgconfig(mlite5) >= 0.0.6 | |||
BuildRequires: pkgconfig(mce) >= 1.12.2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mce is at 1.51.1, but mce-dev aka mce-headers aka pkgconfig(mce) >= 1.16.0
@@ -83,6 +120,27 @@ void DeviceLock::handleCallStateChange(const QString &state, const QString &igno | |||
} | |||
} | |||
|
|||
void DeviceLock::handleBlankingPauseChange(const QString &state) | |||
{ | |||
if (state.startsWith("active") && !m_blankingPause) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there some reason to use startsWith() instead of equality check?
Also I found the double if structure to require some thought to grok. Could be simpler and smaller - something like this perhaps?
bool blankingPause = (state == "active");
if (m_blankingPause != blankingPause ) {
m_blankingPause = blankingPause;
emit blankingPauseChanged();
}
I guess the dependency already got fixed, so LGTM |
I dont have write access to this repo. So anyone with write access: feel free to merge. |
To me feels architecturally weird to give homescreen blanking state handling to device lock. |
LGTM |
[lipstick] devicelock to handle blanking states for home2. Contribute…
…s to JB#28929