DescriptionChanges in app.window and app.runtime to support lock screen note taking
Implements changes in app.window and app.runtime to support launching
app window for handling actions on lock screen. Currently, this is
restricted to note taking action (at time of writing, no other actions
exist), which will be restricted to a whitelisted apps on lock screen
(guarded by lockScreen permsission).
Changes to APIs:
chrome.app.runtime:
* add isLockScreenAction to LaunchData.AcionData, which will be set
when the launch event is fired in order to handle the action on lock
screen (and it will be fired to the app running in lock screen
context - script context with reduced access to chrome APIs)
chrome.app.window:
* add lockScreenAction app window option. When passer to window.create,
if set, the option will indicate that the app window is being
launched to handle an action that should be handled on lock screen.
The created app window would be added to ash window container visible
on the Chrome OS lock screen (LockActionHandlerContainer).
This option will be restricted to apps running in lock screen context
with lockScreen permission (whitelisted to Keep app).
Note that creation of app windows visible on lock screen will succeed
only if user session is locked and the action in question was requested
from the lock screen - this will be determined by delegating to
AppWindowClient (which already creates app window instances).
This CL adds a CreateAppWindowForLockScreenAction method to the client
which will use lock_screen_apps:StateController to verify that the app
was asked to handle the lock screen action before creating the app
window. If created, the lock screen window is registered with the
lock_screen_apps::StateController so lock screen apps state can be
updated depending on the window state (e.g. exit active state when the
app window is closed), and vice-versa.
Tests for launching lock screen note taking action to be added in:
https://codereview.chromium.org/2927303003
BUG=715781
Review-Url: https://codereview.chromium.org/2934513003
Cr-Commit-Position: refs/heads/master@{#481417}
Committed: https://chromium.googlesource.com/chromium/src/+/8bf50fca8ae311bde0cf49734344a2d0f9ac0f68
Patch Set 1 #Patch Set 2 : split out browsertests #
Total comments: 20
Patch Set 3 : feedback #Patch Set 4 : . #
Total comments: 14
Patch Set 5 : . #
Total comments: 4
Patch Set 6 : . #Patch Set 7 : . #Patch Set 8 : . #
Total comments: 2
Patch Set 9 : . #Patch Set 10 : . #Patch Set 11 : rebase to ToT #Patch Set 12 : . #Patch Set 13 : . #Messages
Total messages: 25 (11 generated)
|