Skip to content
Commit 49af48a4 authored by Makoto Onuki's avatar Makoto Onuki
Browse files

Extend FGS timeout for overlapping start

- If startForeground(SHORT_SERVICE) is called on an already
running SHORT_SERVICE FGS *when the app _could_ start a new FGS*,
then we should extend the timeout.

This allows "overlapping" uses of SHORT_SERVICE FGS.

- We also now support changing the FGS type from/to SHORT_FGS.

-- From SHORT_SERVICE to another type: Allowed only when the app
could start another FGS.

-- From another type to SHORT_SERVICE: Always allowed, and a timeout
will start.

-- From SHORT_SERVICE to SHORT_SERVICE: If the app could start another
FGS, we'll extend the timeout. Otherwise, it'd cause FGS-BG-start
exception.

Bug: 257270313
Test: atest CtsShortFgsTestCases
Test: Manual test using the test app.
Change-Id: I0c0057637f91000f1cb7ea6032eae6d696ad71f8
parent 64cb8020
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment