Loading packages/SystemUI/src/com/android/systemui/qs/customize/TileQueryHelper.java +2 −0 Original line number Diff line number Diff line Loading @@ -87,6 +87,8 @@ public class TileQueryHelper { if (current != null) { // The setting QS_TILES is not populated immediately upon Factory Reset possibleTiles.addAll(Arrays.asList(current.split(","))); } else { current = ""; } String[] stockSplit = stock.split(","); for (String spec : stockSplit) { Loading packages/SystemUI/tests/src/com/android/systemui/qs/customize/TileQueryHelperTest.java +8 −0 Original line number Diff line number Diff line Loading @@ -218,4 +218,12 @@ public class TileQueryHelperTest extends SysuiTestCase { } assertFalse(specs.contains("other")); } @Test public void testQueryTiles_nullSetting() { Settings.Secure.putString(mContext.getContentResolver(), Settings.Secure.QS_TILES, null); mContext.getOrCreateTestableResources().addOverride(R.string.quick_settings_tiles_stock, STOCK_TILES); mTileQueryHelper.queryTiles(mQSTileHost); } } Loading
packages/SystemUI/src/com/android/systemui/qs/customize/TileQueryHelper.java +2 −0 Original line number Diff line number Diff line Loading @@ -87,6 +87,8 @@ public class TileQueryHelper { if (current != null) { // The setting QS_TILES is not populated immediately upon Factory Reset possibleTiles.addAll(Arrays.asList(current.split(","))); } else { current = ""; } String[] stockSplit = stock.split(","); for (String spec : stockSplit) { Loading
packages/SystemUI/tests/src/com/android/systemui/qs/customize/TileQueryHelperTest.java +8 −0 Original line number Diff line number Diff line Loading @@ -218,4 +218,12 @@ public class TileQueryHelperTest extends SysuiTestCase { } assertFalse(specs.contains("other")); } @Test public void testQueryTiles_nullSetting() { Settings.Secure.putString(mContext.getContentResolver(), Settings.Secure.QS_TILES, null); mContext.getOrCreateTestableResources().addOverride(R.string.quick_settings_tiles_stock, STOCK_TILES); mTileQueryHelper.queryTiles(mQSTileHost); } }