Home
last modified time | relevance | path

Searched refs:TileSpec (Results 1 – 25 of 132) sorted by relevance

123456

/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/qs/panels/domain/interactor/
DInfiniteGridConsistencyInteractorTest.kt25 import com.android.systemui.qs.pipeline.shared.TileSpec
38 TileSpec.create("smallA"),
39 TileSpec.create("smallB"),
40 TileSpec.create("smallC"),
41 TileSpec.create("smallD"),
42 TileSpec.create("smallE"),
48 override fun isIconTile(spec: TileSpec): Boolean { in <lambda>()
65 TileSpec.create("largeA"), in validTiles_returnsUnchangedList()
66 TileSpec.create("smallA"), in validTiles_returnsUnchangedList()
67 TileSpec.create("smallB"), in validTiles_returnsUnchangedList()
[all …]
DGridConsistencyInteractorTest.kt30 import com.android.systemui.qs.pipeline.shared.TileSpec
47 TileSpec.create("smallA"),
48 TileSpec.create("smallB"),
49 TileSpec.create("smallC"),
50 TileSpec.create("smallD"),
51 TileSpec.create("smallE"),
58 override fun isIconTile(spec: TileSpec): Boolean { in <lambda>()
87 TileSpec.create("largeA"), in changeLayoutType_usesCorrectGridConsistencyInteractor()
88 TileSpec.create("smallA"), in changeLayoutType_usesCorrectGridConsistencyInteractor()
89 TileSpec.create("largeB"), in changeLayoutType_usesCorrectGridConsistencyInteractor()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/pipeline/data/repository/
DUserTileSpecRepository.kt10 import com.android.systemui.qs.pipeline.shared.TileSpec in <lambda>()
50 private val defaultTiles: List<TileSpec> in <lambda>()
56 private lateinit var _tiles: StateFlow<List<TileSpec>> in <lambda>()
58 suspend fun tiles(): Flow<List<TileSpec>> { in <lambda>()
86 private fun startFlowCollections(tiles: StateFlow<List<TileSpec>>) { in <lambda>()
116 private suspend fun storeTiles(@UserIdInt forUser: Int, tiles: List<TileSpec>) { in <lambda>()
119 .filter { it !is TileSpec.Invalid } in <lambda>()
120 .joinToString(DELIMITER, transform = TileSpec::spec) in <lambda>()
133 suspend fun addTile(tile: TileSpec, position: Int = TileSpecRepository.POSITION_AT_END) { in <lambda>()
134 if (tile is TileSpec.Invalid) { in <lambda>()
[all …]
DUserAutoAddRepository.kt9 import com.android.systemui.qs.pipeline.shared.TileSpec in <lambda>()
50 private lateinit var _autoAdded: StateFlow<Set<TileSpec>> in <lambda>()
52 suspend fun autoAdded(): StateFlow<Set<TileSpec>> { in <lambda>()
72 private fun startFlowCollections(autoAdded: StateFlow<Set<TileSpec>>) { in <lambda>()
102 suspend fun markTileAdded(spec: TileSpec) { in <lambda>()
103 if (spec is TileSpec.Invalid) { in <lambda>()
109 suspend fun unmarkTileAdded(spec: TileSpec) { in <lambda>()
110 if (spec is TileSpec.Invalid) { in <lambda>()
116 private suspend fun store(tiles: Set<TileSpec>) { in <lambda>()
119 .filter { it !is TileSpec.Invalid } in <lambda>()
[all …]
DTileSpecRepository.kt25 import com.android.systemui.qs.pipeline.shared.TileSpec in <lambda>()
43 suspend fun tilesSpecs(@UserIdInt userId: Int): Flow<List<TileSpec>> in <lambda>()
53 suspend fun addTile(@UserIdInt userId: Int, tile: TileSpec, position: Int = POSITION_AT_END) in <lambda>()
60 suspend fun removeTiles(@UserIdInt userId: Int, tiles: Collection<TileSpec>) in <lambda>()
67 suspend fun setTiles(@UserIdInt userId: Int, tiles: List<TileSpec>) in <lambda>()
69 suspend fun reconcileRestore(restoreData: RestoreData, currentAutoAdded: Set<TileSpec>) in <lambda>()
102 .map(TileSpec::create) in <lambda>()
103 .filter { it !is TileSpec.Invalid } in <lambda>()
108 override suspend fun tilesSpecs(userId: Int): Flow<List<TileSpec>> { in tilesSpecs()
125 override suspend fun addTile(userId: Int, tile: TileSpec, position: Int) { in addTile()
[all …]
DAutoAddRepository.kt22 import com.android.systemui.qs.pipeline.shared.TileSpec
30 suspend fun autoAddedTiles(userId: Int): Flow<Set<TileSpec>> in autoAddedTiles()
33 suspend fun markTileAdded(userId: Int, spec: TileSpec) in autoAddedTiles()
39 suspend fun unmarkTileAdded(userId: Int, spec: TileSpec) in autoAddedTiles()
57 override suspend fun autoAddedTiles(userId: Int): Flow<Set<TileSpec>> { in autoAddedTiles()
65 override suspend fun markTileAdded(userId: Int, spec: TileSpec) { in autoAddedTiles()
69 override suspend fun unmarkTileAdded(userId: Int, spec: TileSpec) { in autoAddedTiles()
DTilesSettingConverter.kt3 import com.android.systemui.qs.pipeline.shared.TileSpec
10 commaSeparatedTiles.split(DELIMITER).map(TileSpec::create).filter { it != TileSpec.Invalid } in toTilesList()
15 .map(TileSpec::create) in toTilesSet()
16 .filter { it != TileSpec.Invalid } in toTilesSet()
DDefaultTilesRepository.kt7 import com.android.systemui.qs.pipeline.shared.TileSpec
11 val defaultTiles: List<TileSpec>
20 override val defaultTiles: List<TileSpec>
22 QSHost.getDefaultSpecs(resources).map(TileSpec::create).filter { in <lambda>()
23 it != TileSpec.Invalid in <lambda>()
/frameworks/base/packages/SystemUI/multivalentTests/src/com/android/systemui/qs/pipeline/data/repository/
DTilesSettingConverterTest.kt7 import com.android.systemui.qs.pipeline.shared.TileSpec
30 TileSpec.create("c"), in toTilesList_correctContentAndOrdering()
31 TileSpec.create("b"), in toTilesList_correctContentAndOrdering()
32 TileSpec.create("custom(x/y)"), in toTilesList_correctContentAndOrdering()
33 TileSpec.create("d"), in toTilesList_correctContentAndOrdering()
48 assertThat(TileSpec.create("")).isEqualTo(TileSpec.Invalid) in toTilesList_removesInvalid()
51 TileSpec.create("a"), in toTilesList_removesInvalid()
52 TileSpec.create("b"), in toTilesList_removesInvalid()
70 TileSpec.create("c"), in toTilesSet_correctContent()
71 TileSpec.create("b"), in toTilesSet_correctContent()
[all …]
DUserTileSpecRepositoryTest.kt10 import com.android.systemui.qs.pipeline.shared.TileSpec
34 override val defaultTiles: List<TileSpec>
73 assertThat(tiles).isEqualTo(listOf(TileSpec.create("a"))) in changeInSettings_valueDoesntChange()
76 assertThat(tiles).isEqualTo(listOf(TileSpec.create("a"))) in changeInSettings_valueDoesntChange()
98 assertThat(tiles).isEqualTo(specs.toTileSpecs().filter { it != TileSpec.Invalid }) in invalidTilesAreNotPresent()
130 underTest.addTile(TileSpec.create("b")) in addTileAtEnd()
144 underTest.addTile(TileSpec.create("d"), position = 1) in addTileAtPosition()
159 underTest.addTile(TileSpec.Invalid) in addInvalidTile_noop()
173 underTest.addTile(TileSpec.create("d"), position = 100) in addTileAtPosition_tooLarge_addedAtEnd()
187 underTest.removeTiles(listOf(TileSpec.create("a"))) in removeTiles()
[all …]
/frameworks/base/packages/SystemUI/multivalentTests/src/com/android/systemui/qs/pipeline/shared/
DTileSpecTest.kt37 val tileSpec = TileSpec.create(spec) in platformTile()
39 assertThat(tileSpec is TileSpec.PlatformTileSpec).isTrue() in platformTile()
48 val tileSpec = TileSpec.create(spec) in customTile()
50 assertThat(tileSpec is TileSpec.CustomTileSpec).isTrue() in customTile()
52 assertThat((tileSpec as TileSpec.CustomTileSpec).componentName).isEqualTo(componentName) in customTile()
59 val tileSpec = TileSpec.create(spec) in emptyCustomTile_invalid()
61 assertThat(tileSpec).isEqualTo(TileSpec.Invalid) in emptyCustomTile_invalid()
68 val tileSpec = TileSpec.create(spec) in invalidCustomTileSpec_invalid()
70 assertThat(tileSpec).isEqualTo(TileSpec.Invalid) in invalidCustomTileSpec_invalid()
78 val tileSpec = TileSpec.create(spec) in customTileNotEndsWithParenthesis_invalid()
[all …]
/frameworks/base/packages/SystemUI/multivalentTests/src/com/android/systemui/qs/panels/ui/viewmodel/
DEditModeViewModelTest.kt43 import com.android.systemui.qs.pipeline.shared.TileSpec in <lambda>()
173 .filter { it.tileSpec is TileSpec.PlatformTileSpec } in <lambda>()
189 .filter { it.tileSpec is TileSpec.PlatformTileSpec } in <lambda>()
210 .filter { it.tileSpec is TileSpec.CustomTileSpec } in <lambda>()
213 .containsExactly(TileSpec.create(component1), TileSpec.create(component2)) in <lambda>()
226 val model1 = tiles!!.first { it.tileSpec == TileSpec.create(component1) } in <lambda>()
233 val model2 = tiles!!.first { it.tileSpec == TileSpec.create(component2) } in <lambda>()
248 TileSpec.create("flashlight"), in <lambda>()
249 TileSpec.create("airplane"), in <lambda>()
250 TileSpec.create(component2), in <lambda>()
[all …]
/frameworks/base/packages/SystemUI/tests/utils/src/com/android/systemui/qs/pipeline/data/repository/
DFakeTileSpecRepository.kt21 import com.android.systemui.qs.pipeline.shared.TileSpec
30 private val tilesPerUser = mutableMapOf<Int, MutableStateFlow<List<TileSpec>>>()
32 override suspend fun tilesSpecs(userId: Int): Flow<List<TileSpec>> { in tilesSpecs()
36 override suspend fun addTile(userId: Int, tile: TileSpec, position: Int) { in addTile()
37 if (tile == TileSpec.Invalid) return in addTile()
50 override suspend fun removeTiles(userId: Int, tiles: Collection<TileSpec>) { in removeTiles()
53 value.toMutableList().apply { removeAll(tiles.filter { it != TileSpec.Invalid }) } in removeTiles()
57 override suspend fun setTiles(userId: Int, tiles: List<TileSpec>) { in setTiles()
58 getFlow(userId).value = tiles.filter { it != TileSpec.Invalid } in setTiles()
61 private fun getFlow(userId: Int): MutableStateFlow<List<TileSpec>> = in getFlow()
[all …]
DFakeAutoAddRepository.kt20 import com.android.systemui.qs.pipeline.shared.TileSpec
26 private val autoAddedTilesPerUser = mutableMapOf<Int, MutableStateFlow<Set<TileSpec>>>()
28 override suspend fun autoAddedTiles(userId: Int): StateFlow<Set<TileSpec>> { in autoAddedTiles()
32 override suspend fun markTileAdded(userId: Int, spec: TileSpec) { in markTileAdded()
33 if (spec == TileSpec.Invalid) return in markTileAdded()
37 override suspend fun unmarkTileAdded(userId: Int, spec: TileSpec) { in unmarkTileAdded()
41 private fun getFlow(userId: Int): MutableStateFlow<Set<TileSpec>> = in getFlow()
/frameworks/base/packages/SystemUI/multivalentTests/src/com/android/systemui/qs/pipeline/domain/interactor/
DCurrentTilesInteractorImplTest.kt48 import com.android.systemui.qs.pipeline.shared.TileSpec
155 TileSpec.create("a"), in correctTiles()
156 TileSpec.create("e"), in correctTiles()
158 TileSpec.create("d"), in correctTiles()
159 TileSpec.create("non_existent") in correctTiles()
197 TileSpec.create("a"), in logTileCreated()
211 TileSpec.create("non_existing"), in logTileNotFoundInFactory()
225 TileSpec.create("e"), in tileNotAvailableDestroyed_logged()
245 TileSpec.create("a"), in someTilesNotValid_repositorySetToDefinitiveList()
246 TileSpec.create("e"), in someTilesNotValid_repositorySetToDefinitiveList()
[all …]
DNoLowNumberOfTilesTest.kt39 import com.android.systemui.qs.pipeline.shared.TileSpec
71 TileSpec.create("internet"),
72 TileSpec.create("bt"),
86 private val goodTile = TileSpec.create("correct")
90 TileSpec.create("OEM:internet"),
91 TileSpec.create("OEM:bt"),
92 TileSpec.create("OEM:dnd"),
94 TileSpec.create(ComponentName.unflattenFromString("oem/.tile")!!),
95 TileSpec.create("OEM:flashlight"),
135 val badTiles = listOf(TileSpec.create("OEM:unknown_tile")) in noEmptyTilesAfterSettingTilesToUnknownNames()
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/viewmodel/
DQSTileConfigProvider.kt22 import com.android.systemui.qs.pipeline.shared.TileSpec
59 when (TileSpec.create(tileSpec)) { in getConfig()
60 is TileSpec.PlatformTileSpec -> configs.containsKey(tileSpec) in getConfig()
61 is TileSpec.CustomTileSpec -> true in getConfig()
62 is TileSpec.Invalid -> false in getConfig()
66 when (val spec = TileSpec.create(tileSpec)) { in getConfig()
67 is TileSpec.PlatformTileSpec -> { in getConfig()
71 is TileSpec.CustomTileSpec -> in getConfig()
77 is TileSpec.Invalid -> in getConfig()
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/panels/data/repository/
DIconTilesRepository.kt20 import com.android.systemui.qs.pipeline.shared.TileSpec
25 fun isIconTile(spec: TileSpec): Boolean in isIconTile()
31 override fun isIconTile(spec: TileSpec): Boolean { in isIconTile()
38 TileSpec.create("internet"), in isIconTile()
39 TileSpec.create("bt"), in isIconTile()
40 TileSpec.create("dnd"), in isIconTile()
41 TileSpec.create("cast"), in isIconTile()
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/base/logging/
DQSTileLogger.kt26 import com.android.systemui.qs.pipeline.shared.TileSpec
36 @QSTilesLogBuffers logBuffers: Map<TileSpec, LogBuffer>,
48 tileSpec: TileSpec, in logUserAction()
75 tileSpec: TileSpec, in logUserActionRejectedByFalsing()
90 tileSpec: TileSpec, in logUserActionRejectedByPolicy()
107 tileSpec: TileSpec, in logUserActionPipeline()
131 fun logForceUpdate(tileSpec: TileSpec) { in logForceUpdate()
137 fun logInitialRequest(tileSpec: TileSpec) { in logInitialRequest()
145 tileSpec: TileSpec, in logStateUpdate()
163 tileSpec: TileSpec, in logError()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/pipeline/shared/logging/
DQSPipelineLogger.kt26 import com.android.systemui.qs.pipeline.shared.TileSpec
54 fun logParsedTiles(tiles: List<TileSpec>, usesDefault: Boolean, user: Int) { in logParsedTiles()
68 currentTiles: List<TileSpec>, in logTilesRestoredAndReconciled()
69 reconciledTiles: List<TileSpec>, in logTilesRestoredAndReconciled()
86 newList: List<TileSpec>, in logProcessTileChange()
102 fun logTileDestroyed(spec: TileSpec, reason: TileDestroyedReason) { in logTileDestroyed()
115 fun logTileCreated(spec: TileSpec) { in logTileCreated()
125 fun logTileNotFoundInFactory(spec: TileSpec) { in logTileNotFoundInFactory()
135 fun logTileUserChanged(spec: TileSpec, user: Int) { in logTileUserChanged()
151 fun logTilesNotInstalled(tiles: Collection<TileSpec>, user: Int) { in logTilesNotInstalled()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/impl/custom/di/
DQSTileConfigModule.kt19 import com.android.systemui.qs.pipeline.shared.TileSpec
34 @Provides fun provideTileSpec(): TileSpec = config.tileSpec
37 fun provideCustomTileSpec(): TileSpec.CustomTileSpec =
38 config.tileSpec as TileSpec.CustomTileSpec
41 fun providePlatformTileSpec(): TileSpec.PlatformTileSpec =
42 config.tileSpec as TileSpec.PlatformTileSpec
/frameworks/base/packages/SystemUI/multivalentTests/src/com/android/systemui/qs/tiles/base/logging/
DQSTileLoggerTest.kt28 import com.android.systemui.qs.pipeline.shared.TileSpec
58 val tileSpec: TileSpec = TileSpec.create("chatty_tile") in setup()
67 TileSpec.create("chatty_tile"), in testChattyLog()
71 TileSpec.create("chatty_tile"), in testChattyLog()
83 TileSpec.create("test_spec"), in testLogUserAction()
96 TileSpec.create("test_spec"), in testLogUserActionRejectedByFalsing()
106 TileSpec.create("test_spec"), in testLogUserActionRejectedByPolicy()
116 TileSpec.create("test_spec"), in testLogUserActionPipeline()
143 TileSpec.create("test_spec"), in testLogStateUpdate()
166 TileSpec.create("test_spec"), in testLogForceUpdate()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/pipeline/domain/model/
DAutoAddSignal.kt20 import com.android.systemui.qs.pipeline.shared.TileSpec
25 val spec: TileSpec
29 override val spec: TileSpec,
35 override val spec: TileSpec,
40 override val spec: TileSpec,
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/pipeline/domain/autoaddable/
DA11yShortcutAutoAddableList.kt22 import com.android.systemui.qs.pipeline.shared.TileSpec
39 TileSpec.create(ColorCorrectionTile.TILE_SPEC), in getA11yShortcutAutoAddables()
43 TileSpec.create(ColorInversionTile.TILE_SPEC), in getA11yShortcutAutoAddables()
47 TileSpec.create(OneHandedModeTile.TILE_SPEC), in getA11yShortcutAutoAddables()
51 TileSpec.create(ReduceBrightColorsTile.TILE_SPEC), in getA11yShortcutAutoAddables()
55 TileSpec.create(HearingDevicesTile.TILE_SPEC), in getA11yShortcutAutoAddables()
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/panels/domain/interactor/
DInfiniteGridConsistencyInteractor.kt23 import com.android.systemui.qs.pipeline.shared.TileSpec
38 override fun reconcileTiles(tiles: List<TileSpec>): List<TileSpec> { in reconcileTiles()
39 val newTiles: MutableList<TileSpec> = mutableListOf() in reconcileTiles()
40 val row = TileRow<TileSpec>(columns = gridSizeInteractor.columns.value) in reconcileTiles()
70 val iconTile: SizedTile<TileSpec>? = tilesQueue.firstOrNull { it.width == 1 } in reconcileTiles()
76 val tileToRemove: SizedTile<TileSpec>? = row.findLastIconTile() in reconcileTiles()

123456