Commit Graph

7 Commits

Author SHA1 Message Date
Dave Mankoff
f1a5f74f40 Use less SysUI specific code in Flags.
A step along they way to sharing the flagging code as a library.

Bug: 249121873
Test: atest SystemUITests
Change-Id: Id48d33a6ce0d058c4b2d3c282865297841753bb7
2022-10-03 13:57:23 +00:00
Dave Mankoff
2719567655 Add ability for flags to be server-overridden.
This works in both debug and release builds. In debug builds,
all flags can be overridden via the same mechanisms as before,
but can also be overridden by flags defined on the server.

On release builds, only `ReleasedFlag`s can be overridden.
`UnreleasedFlag`s remain set in their default state.

With this cl, server side flags do not get their new value
until SystemUI is restarted (via a reboot or a crash).

Bug: 239863271
Test: atest SystemUITests
Change-Id: I08166cb90675dea06b2671669cecfc16ac58ab61
Merged-In: I08166cb90675dea06b2671669cecfc16ac58ab61
2022-08-06 23:25:13 +00:00
Jeff DeCew
c7be05d8ed Add Compile.IS_DEBUG to systemui
This is meant to replace Build.IS_DEBUGGABLE and allow compile-time optimizations

Fixes: 214238812
Test: manual builds
Change-Id: Id4b3c48a0c88f1e4cff7752907cf72d19295571d
2022-01-12 16:20:02 +00:00
Dave Mankoff
02e42be6ec Convert FeatureFlags to interface.
Rename FeatureFlagManager version to
FeatureFlagsDebug and FeatureFlagsRelease, implementing
the FeatureFlags interface.

Bug: 203548827
Test: manual
Change-Id: I4b78757a5e7ee3d5ee06f9124e2b8f670e611d4f
2021-11-17 17:13:25 -05:00
Dave Mankoff
5346e090f5 Move contents of FeatureFlags into FeatureFlagManager.
The meaningful contents of FeatureFlags only relates to debug
builds and has been moved into the debug version of
FeatureFlagManager.

Bug: 203548872
Test: atest SystemUITests && manual
Change-Id: Ifcef0cfe4e2d07daec34dfc7a6cbe2d305b312b5
2021-11-10 09:46:04 -05:00
Dave Mankoff
1a934e9aee Add ability to read flag values to Flag Library.
The FlagManager now partially implements the FlagReader interface.

The FeatureFlagManager, part of SystemUI proper, now uses the
FlagManager to read flag values, helping to ensure consistency between
the two separate systems.

Bug: 203548827
Test: manual
Change-Id: Ia3b103f783a846cfe9437cd8e6b987962cebabde
2021-11-03 10:28:22 -04:00
Jeff DeCew
86b8e77bbf Make gradle build use debuggable FeatureFlagManager
Fixes: 204129347
Test: gradle build & dump
Change-Id: I06ba95f4cc21b06519e676afee4bb6ae9c44c03e
2021-10-30 14:08:45 -04:00