Skip to content

Allow display to turn off for power saving during say all#11118

Merged
feerrenrut merged 2 commits into
nvaccess:masterfrom
LeonarddeR:sayAllNoDisplayRequired
May 7, 2020
Merged

Allow display to turn off for power saving during say all#11118
feerrenrut merged 2 commits into
nvaccess:masterfrom
LeonarddeR:sayAllNoDisplayRequired

Conversation

@LeonarddeR

@LeonarddeR LeonarddeR commented May 6, 2020

Copy link
Copy Markdown
Collaborator

Link to issue number:

#10643 (comment)

Summary of the issue:

When in say all, the screen is forced to stay on even when there are no screen updates. For non-visual use, this seems unnecessary.
Some users may wish to have their screen turn off for power saving reasons.

Description of how this pull request fixes the issue:

No longer provide the winKernel.ES_DISPLAY_REQUIRED flag to SetThreadExecutionState

Testing performed:

Tested that say all still continues for the original use case in #10643

Known issues with pull request:

If the screen really updates, such as due to cursor movement, this may not make any difference. Therefore difference is only expected when:

  • Say all in browse mode with long paragraphs
  • Braille display gestures when reading with the review cursor.

Change log entry:

@feerrenrut feerrenrut left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @LeonarddeR

@feerrenrut feerrenrut changed the title Don't force the display to stay on when in say all Allow display to turn off for power saving during say all May 7, 2020
@feerrenrut feerrenrut merged commit 3c5bc1e into nvaccess:master May 7, 2020
@nvaccessAuto nvaccessAuto added this to the 2020.1 milestone May 7, 2020
LeonarddeR added a commit that referenced this pull request Aug 25, 2020
seanbudd pushed a commit that referenced this pull request Feb 16, 2025
Fixes #17649
Partially reverts #11118
Follow up of #10111, #10643,

Summary of the issue:
On some systems (mine, for example 😉) the screen still locks during a say all even though we reset the system idle timer. We also reset the display timer in the past, but this was reverted in #11118, particularly on request of @btman16

Description of user facing changes
Added a new advanced setting that, when enabled, also resets the display timer.

Description of development approach
Added new helper/wrapper methods to systemUtils
Rather than resetting the timer(s) many times during a say all, we now persist the state during say all using the ES_CONTINUOUS flag. This should avoid an edge case where reading a line takes more then a minute and the sleep timer is a minute, in which case the system will still lock.
@LeonarddeR LeonarddeR deleted the sayAllNoDisplayRequired branch August 23, 2025 06:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants