Themes: Fix applying default theme

ThemeUtils has method for getting the default theme package name
which will return ThemeConfig.SYSTEM_DEFAULT if no default theme
package is defined in CMSettings.  Use this method rather than read
the setting directly.

Change-Id: I924f8ee116d97a8f3fcf4703214376608b31f297
This commit is contained in:
d34d 2016-06-20 10:33:13 -07:00
parent 46bed1698d
commit afcfb67696
1 changed files with 1 additions and 2 deletions

View File

@ -485,8 +485,7 @@ public class ThemeManagerService extends CMSystemService {
private void doApplyDefaultTheme() {
final ContentResolver resolver = mContext.getContentResolver();
final String defaultThemePkg = CMSettings.Secure.getString(resolver,
CMSettings.Secure.DEFAULT_THEME_PACKAGE);
final String defaultThemePkg = ThemeUtils.getDefaultThemePackageName(mContext);
if (!TextUtils.isEmpty(defaultThemePkg)) {
String defaultThemeComponents = CMSettings.Secure.getString(resolver,
CMSettings.Secure.DEFAULT_THEME_COMPONENTS);