Chromium Code Reviews| Index: chrome/browser/resources/chromeos/chromevox/cvox2/background/command_handler.js |
| diff --git a/chrome/browser/resources/chromeos/chromevox/cvox2/background/command_handler.js b/chrome/browser/resources/chromeos/chromevox/cvox2/background/command_handler.js |
| index f37c37318f0dc822ea013835bc0c7c5e487a6a26..09fd6d6c0366917adfd4bf598e4d212a0116fa5e 100644 |
| --- a/chrome/browser/resources/chromeos/chromevox/cvox2/background/command_handler.js |
| +++ b/chrome/browser/resources/chromeos/chromevox/cvox2/background/command_handler.js |
| @@ -192,6 +192,20 @@ CommandHandler.onCommand = function(command) { |
| case 'showNextUpdatePage': |
| (new PanelCommand(PanelCommandType.UPDATE_NOTES)).send(); |
| return false; |
| + case 'darkenScreen': |
| + // Called twice to ensure the cros end of the dbus message is in a good |
|
dmazzoni
2017/03/24 16:02:40
I just think that detail should be handled lower d
David Tseng
2017/03/24 18:07:43
Ok, I see this as a one off api, so fine either wa
|
| + // state. |
| + chrome.accessibilityPrivate.darkenScreen(false); |
| + chrome.accessibilityPrivate.darkenScreen(true); |
| + new Output().format('@darken_screen').go(); |
| + break; |
| + case 'undarkenScreen': |
| + // Called twice to ensure the cros end of the dbus message is in a good |
| + // state. |
| + chrome.accessibilityPrivate.darkenScreen(true); |
| + chrome.accessibilityPrivate.darkenScreen(false); |
| + new Output().format('@undarken_screen').go(); |
| + break; |
| default: |
| break; |
| } |