@Test public void isLightTheme_shouldReturnTrue_whenThemeIsLight() { List<String> lightThemes = Arrays.asList( "holo_light", "material_light", "glif_light", "glif_v2_light", "glif_v3_light" ); ArrayList<String> unexpectedIntentThemes = new ArrayList<>(); ArrayList<String> unexpectedStringThemes = new ArrayList<>(); for (final String theme : lightThemes) { Intent intent = new Intent(); intent.putExtra(WizardManagerHelper.EXTRA_THEME, theme); if (!WizardManagerHelper.isLightTheme(intent, false)) { unexpectedIntentThemes.add(theme); } if (!WizardManagerHelper.isLightTheme(theme, false)) { unexpectedStringThemes.add(theme); } } assertTrue("Intent themes " + unexpectedIntentThemes + " should be light", unexpectedIntentThemes.isEmpty()); assertTrue("String themes " + unexpectedStringThemes + " should be light", unexpectedStringThemes.isEmpty()); }
public static boolean isLightTheme(Intent intent, boolean def) { final String theme = intent.getStringExtra(EXTRA_THEME); return isLightTheme(theme, def); }
WizardManagerHelper { public static boolean isLightTheme(Intent intent, boolean def) { final String theme = intent.getStringExtra(EXTRA_THEME); return isLightTheme(theme, def); } }
WizardManagerHelper { public static boolean isLightTheme(Intent intent, boolean def) { final String theme = intent.getStringExtra(EXTRA_THEME); return isLightTheme(theme, def); }  }
WizardManagerHelper { public static boolean isLightTheme(Intent intent, boolean def) { final String theme = intent.getStringExtra(EXTRA_THEME); return isLightTheme(theme, def); }  static Intent getNextIntent(Intent originalIntent, int resultCode); static Intent getNextIntent(Intent originalIntent, int resultCode, Intent data); static void copyWizardManagerExtras(Intent srcIntent, Intent dstIntent); static boolean isSetupWizardIntent(Intent intent); static boolean isUserSetupComplete(Context context); static boolean isDeviceProvisioned(Context context); static boolean isDeferredSetupWizard(Intent originalIntent); static boolean isPreDeferredSetupWizard(Intent originalIntent); static boolean isLightTheme(Intent intent, boolean def); static boolean isLightTheme(String theme, boolean def); static @StyleRes int getThemeRes(Intent intent, @StyleRes int defaultTheme); static @StyleRes int getThemeRes(String theme, @StyleRes int defaultTheme); }
WizardManagerHelper { public static boolean isLightTheme(Intent intent, boolean def) { final String theme = intent.getStringExtra(EXTRA_THEME); return isLightTheme(theme, def); }  static Intent getNextIntent(Intent originalIntent, int resultCode); static Intent getNextIntent(Intent originalIntent, int resultCode, Intent data); static void copyWizardManagerExtras(Intent srcIntent, Intent dstIntent); static boolean isSetupWizardIntent(Intent intent); static boolean isUserSetupComplete(Context context); static boolean isDeviceProvisioned(Context context); static boolean isDeferredSetupWizard(Intent originalIntent); static boolean isPreDeferredSetupWizard(Intent originalIntent); static boolean isLightTheme(Intent intent, boolean def); static boolean isLightTheme(String theme, boolean def); static @StyleRes int getThemeRes(Intent intent, @StyleRes int defaultTheme); static @StyleRes int getThemeRes(String theme, @StyleRes int defaultTheme); static final String EXTRA_THEME; static final String EXTRA_USE_IMMERSIVE_MODE; static final String SETTINGS_GLOBAL_DEVICE_PROVISIONED; static final String SETTINGS_SECURE_USER_SETUP_COMPLETE; static final String THEME_HOLO; static final String THEME_HOLO_LIGHT; static final String THEME_MATERIAL; static final String THEME_MATERIAL_LIGHT; static final String THEME_GLIF; static final String THEME_GLIF_LIGHT; static final String THEME_GLIF_V2; static final String THEME_GLIF_V2_LIGHT; static final String THEME_GLIF_V3; static final String THEME_GLIF_V3_LIGHT; }